mirror of
https://github.com/xcat2/confluent.git
synced 2026-04-11 03:11:32 +00:00
Update quorum on deletion
If deletion of a node brings quorum, notify followers of the good news
This commit is contained in:
@@ -1013,6 +1013,14 @@ def del_collective_member(name):
|
||||
if cfgstreams:
|
||||
exec_on_followers_unconditional('_true_del_collective_member', name)
|
||||
_true_del_collective_member(name)
|
||||
if cfgstreams:
|
||||
_hasquorum = has_quorum()
|
||||
pushes = eventlet.GreenPool()
|
||||
payload = msgpack.packb({'quorum': _hasquorum}, use_bin_type=False)
|
||||
for _ in pushes.starmap(
|
||||
_push_rpc,
|
||||
[(cfgstreams[s]['stream'], payload) for s in cfgstreams]):
|
||||
pass
|
||||
|
||||
def _true_del_collective_member(name, sync=True):
|
||||
global cfgleader
|
||||
|
||||
Reference in New Issue
Block a user