Fix translog stats on closed indices yaml test (#52800)

We need to wait for no initializing shards before closing; otherwise, 
we might fail to close some recovering replicas.

Closes #52701
This commit is contained in:
Nhat Nguyen 2020-02-26 08:13:31 -05:00
parent 9e38125464
commit f0bc8abcd0
1 changed files with 4 additions and 0 deletions

View File

@ -256,6 +256,10 @@
metric: [ translog ]
- match: { indices.test.primaries.translog.operations: 1 }
- match: { indices.test.primaries.translog.uncommitted_operations: 1 }
- do:
cluster.health:
wait_for_no_initializing_shards: true
wait_for_events: languid
- do:
indices.close:
index: test