Fix bad split on list
This commit is contained in:
parent
df394c5c39
commit
6eab87a2a8
|
@ -60,7 +60,7 @@ def fenceNode(node_name, zk_conn, config, logger):
|
||||||
time.sleep(3)
|
time.sleep(3)
|
||||||
|
|
||||||
# Force into secondary network state if needed
|
# Force into secondary network state if needed
|
||||||
if node_name in config['coordinators'].split(','):
|
if node_name in config['coordinators']:
|
||||||
zkhandler.writedata(zk_conn, { '/nodes/{}/routerstate'.format(node_name): 'secondary' })
|
zkhandler.writedata(zk_conn, { '/nodes/{}/routerstate'.format(node_name): 'secondary' })
|
||||||
if zkhandler.readdata(zk_conn, '/primary_node') == node_name:
|
if zkhandler.readdata(zk_conn, '/primary_node') == node_name:
|
||||||
zkhandler.writedata(zk_conn, { '/primary_node': 'none' })
|
zkhandler.writedata(zk_conn, { '/primary_node': 'none' })
|
||||||
|
|
Loading…
Reference in New Issue