oxia icon indicating copy to clipboard operation
oxia copied to clipboard

Bug: Panic when metadata version conflict

Open lsytj0413 opened this issue 10 months ago • 2 comments

Ref: https://github.com/streamnative/oxia/pull/622

lsytj0413 avatar Feb 26 '25 01:02 lsytj0413

It seems that coordinator maybe multi instance running, describe as:

The coordinator updates the shard metadata in the metadata store at key moments so that if the coordinator fails, 
the next one can continue where the failed one left off. The protocol also supports multiple coordinators battling for
control without the loss of acknowledged writes (only the loss of availability — i.e. they cannot be read by the
client). While it should not be possible for more than one coordinator to run at a time, it is best to design the
protocol defensively especially given the importance of the data.

But there is nothing election in coordinator implement,and if multi coordinator update shared metadata concurrently,they maybe panic again and again. Should we fix this? cc @merlimat

lsytj0413 avatar Feb 27 '25 07:02 lsytj0413

But there is nothing election in coordinator implement,and if multi coordinator update shared metadata concurrently,they maybe panic again and again. Should we fix this?

We only support single coordinators right now. in the future, we can support multiple and also implement leader election or shards range base on etcd. :)

mattisonchao avatar Mar 20 '25 13:03 mattisonchao