mirror of
https://github.com/scylladb/scylladb.git
synced 2026-04-22 01:20:39 +00:00
We introduce a new operation to the framework: `reconfiguration`. The operation sends a reconfiguration request to a Raft cluster. It bounces a few times in case of `not_a_leader` results. A side effect of the operation is modifying a `known` set of nodes which the operation's state has a reference to. This `known` set can then be used by other operations (such as `raft_call`s) to find the current leader. For now we assume that reconfigurations are performed sequentially. If a reconfiguration succeeds, we change `known` to the new configuration. If it fails, we change `known` to be the set sum of the previous configuration and the current configuration (because we don't know what the configuration will eventually be - the old or the attempted one - so any member of the set sum may eventually become a leader). We use a dedicated thread (similarly to the network partitioning thread) to periodically perform random reconfigurations. * kbr/reconfig-v2: test: raft: randomized_nemesis_test: perform reconfigurations in basic_generator_test test: raft: randomized_nemesis_test: improve the bouncing algorithm test: raft: randomized_nemesis_test: handle more error types test: raft: randomized_nemesis_test put `variant` and `monostate` `ostream` `operator<<`s into `std` namespace test: raft: randomized_nemesis_test: `reconfiguration` operation