-
Notifications
You must be signed in to change notification settings - Fork 55
Open
Labels
featureA new functionalityA new functionality
Description
Consider following case:
Few (let's say 3) nodes in a cluster, with master-master replication.
Each node has it's own queue with name, unique in cluster.
As each tube need to have its own space, these spaces will be created.
But ID of each space may be not unique, as they created on each node separately at virtually the same time.
As a result, there will be errors like
E> ER_TUPLE_FOUND: Duplicate key exists in unique index 'primary' in space '_space'
E> ER_TUPLE_FOUND: Duplicate key exists in unique index 'primary' in space '_index'
in logs.
These errors are fatal for replication. And therefore replication stops.
Following solutions could be proposed:
- Change in application: change cluster startup logic, so it'll create all necessary tubes in box.once(). Later each node can pick appropriate queue somehow, and use it.
- Change in tarantool-queue: Ensure space ID is globally-unique in cluster. (But how to ensure it?)
- Mixed change: tarantool-queue to provide interface to specify ID of a new tube space, so application can assign cluster-unique values for them.
Metadata
Metadata
Assignees
Labels
featureA new functionalityA new functionality