Skip to content

Commit

Permalink
Always wait for no delayed unassigned shards
Browse files Browse the repository at this point in the history
  • Loading branch information
fciocchetti committed Jan 13, 2020
1 parent 67b7f6b commit 00a766d
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions scripts/manage-es.py
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,9 @@ def post_start_data_node(client, mode, node):
pprint('UnDrain Local Node %s' % node)
unset_setting(client, "transient",
"cluster.routing.allocation.exclude._name")
pprint('Wait for No DELAYED_UNASSIGNED shards')
wait_for_no_delayed_unassigned_shards(
client, WAIT_FOR_NO_SHARDS_DELAYED_UNASSIGNED)
pprint('Wait for RELOCATING and INITIALIZING Shards to drop to 0')
wait_for_no_relocating_or_initializing_shards(
client, WAIT_FOR_NO_SHARDS_RELOCATING)
Expand Down Expand Up @@ -404,6 +407,9 @@ def pre_stop_data_node(client, mode, node):
pprint('Drain Local Node %s' % node)
set_setting(client, "transient",
"cluster.routing.allocation.exclude._name", node)
pprint('Wait for No DELAYED_UNASSIGNED shards')
wait_for_no_delayed_unassigned_shards(
client, WAIT_FOR_NO_SHARDS_DELAYED_UNASSIGNED)
pprint('Wait for RELOCATING and INITIALIZING Shards to drop to 0')
wait_for_no_relocating_or_initializing_shards(
client, WAIT_FOR_NO_SHARDS_RELOCATING)
Expand Down

0 comments on commit 00a766d

Please sign in to comment.