2015-02-25 07:25:52 -05:00
|
|
|
---
|
|
|
|
"cluster health basic test":
|
|
|
|
- do:
|
|
|
|
cluster.health: {}
|
|
|
|
|
|
|
|
- is_true: cluster_name
|
|
|
|
- is_false: timed_out
|
|
|
|
- gte: { number_of_nodes: 1 }
|
|
|
|
- gte: { number_of_data_nodes: 1 }
|
|
|
|
- match: { active_primary_shards: 0 }
|
|
|
|
- match: { active_shards: 0 }
|
|
|
|
- match: { relocating_shards: 0 }
|
|
|
|
- match: { initializing_shards: 0 }
|
|
|
|
- match: { unassigned_shards: 0 }
|
|
|
|
- gte: { number_of_pending_tasks: 0 }
|
|
|
|
|
|
|
|
---
|
|
|
|
"cluster health basic test, one index":
|
|
|
|
- do:
|
|
|
|
indices.create:
|
|
|
|
index: test_index
|
2015-02-25 14:34:43 -05:00
|
|
|
body:
|
|
|
|
settings:
|
|
|
|
index:
|
|
|
|
number_of_replicas: 0
|
|
|
|
|
2015-02-25 07:25:52 -05:00
|
|
|
- do:
|
|
|
|
cluster.health:
|
|
|
|
wait_for_status: green
|
|
|
|
|
|
|
|
- is_true: cluster_name
|
|
|
|
- is_false: timed_out
|
|
|
|
- gte: { number_of_nodes: 1 }
|
|
|
|
- gte: { number_of_data_nodes: 1 }
|
|
|
|
- gt: { active_primary_shards: 0 }
|
|
|
|
- gt: { active_shards: 0 }
|
|
|
|
- gte: { relocating_shards: 0 }
|
|
|
|
- match: { initializing_shards: 0 }
|
|
|
|
- match: { unassigned_shards: 0 }
|
|
|
|
- gte: { number_of_pending_tasks: 0 }
|
|
|
|
|
|
|
|
---
|
|
|
|
"cluster health levels":
|
|
|
|
- do:
|
|
|
|
indices.create:
|
|
|
|
index: test_index
|
|
|
|
- do:
|
|
|
|
cluster.health:
|
2015-02-25 14:34:43 -05:00
|
|
|
wait_for_status: yellow
|
2015-02-25 07:25:52 -05:00
|
|
|
level: indices
|
|
|
|
|
|
|
|
- is_true: indices
|
|
|
|
- is_false: indices.test_index.shards
|
|
|
|
|
|
|
|
- do:
|
|
|
|
cluster.health:
|
|
|
|
level: shards
|
|
|
|
|
|
|
|
- is_true: indices
|
|
|
|
- is_true: indices.test_index.shards
|
|
|
|
|
|
|
|
|