blazingmq icon indicating copy to clipboard operation
blazingmq copied to clipboard

Feat[MQB]: Thread safe Cluster Quorum Manager and ITs

Open bbpetukhov opened this issue 4 months ago • 2 comments

Describe your changes Initial intention was to add a new switch to ITs which restarts cluster (having multiple nodes) in FSM mode running only single node, then set quorum to 1 to get cluster into heathy state having only one node up.

After code inspection it was found out that there are 4 quorums in the code which are not in sync. Thus this PR proposes a new class Cluster Quorum Manager which stores and provides thread safe Quorum variable for other components.

There is a small change in behavior how quorum from config file is treated. Previously even if in config a big value is set for quorum, it is reset to number of nodes. However quorum can be set to any value via admin commands. I refactored the behavior to be universal in both cases -- there is no more restriction on max quorum values.

Testing performed

  • UTs passed
  • ITs passed

bbpetukhov avatar Oct 24 '25 16:10 bbpetukhov

@bbpetukhov ITs failing. Please fix.

kaikulimu avatar Nov 07 '25 18:11 kaikulimu

@bbpetukhov ITs failing. Please fix.

Fixed

bbpetukhov avatar Nov 13 '25 11:11 bbpetukhov