https://slatedb.io logo
If anyone wants to do this, I would
# general
c
If anyone wants to do this, I would totally accept it. https://discord.com/channels/1232385660460204122/1445985760833568830/1446230352371781743 I think it's simply @Rohan's transactional object store impl + a heartbeat.
p
I wanted to do it in ZeroFS
The thing I missed to do it cleanly is methods such as
Db::take()
,
Db::is_leader/master()
Instead of fencing automatically when starting a new writer
But perhaps I could do that in slatedb instead, so it could benefit everyone
I'm not very sure how to do that well though, I didn't dig much
c
Yea, plz take a look in SlateDB. I think it'd be a great standalone component
A slatedb-leadership package would be nice
p
I still think that we need some plumbing directly in slatedb
To be able to open a writer, without fencing the previous writer(s)
And be able to know the current state of the writer
THEN we can do clean coordination
c
I don't want to add leadership to the Db/DbReader. I just want it to be standalone
Users can register a callback. They can use a DbReader and when the receive "oh I'm leader now" they can swap to Db
p
Hmm I feel that's going to be pretty flimsy then
c
Why? IMO leadeship election is useful outside of SlateDB, too
I don't think it's a big ask for infra like S2 or ZeroFS to manage their clients
p
Ah, that's not that
What I mean is not to add leadership things inside Db
But to be able to choose to fence manually other writers
Not have it done automatically on db open
So that I can have my standbys have a Db, and when they want to become leader they can just fence other writers through Db
c
Ah that's more complex to do
Not un-doable, but requires more thought.
Since Db autofences on startup now
p
Yes that's what I mean 🙂
Perhaps this could be a setting
c
Yea.. I suppose it could.. but would require some changes. We'd need to detect on first write that we aren't initialized as a writer and do the manifest fence operation then (and then the wal fence after).
v
Is it like a hot standby? Is the motivation to reduce startup time of new writer? I believe Diptanu wants multiple writers to be active at the same time.
c
> Is it like a hot standby? Is the motivation to reduce startup time of new writer? yes