Skip to content

Commit

Permalink
Fix shards_capacity indicator assertion in Health API YAML test (#109808
Browse files Browse the repository at this point in the history
)

This indicator is dependent on `HealthMetadata` being present in
the cluster state, which we can't guarantee in this test,
potentially resulting in an `unknown` status.
  • Loading branch information
nielsbauman committed Jun 18, 2024
1 parent e66cb6c commit 55431dd
Showing 1 changed file with 3 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,9 @@
- exists: indicators.shards_availability.details.started_primaries
- exists: indicators.shards_availability.details.unassigned_replicas

- match: { indicators.shards_capacity.status: "green" }
- match: { indicators.shards_capacity.symptom: "The cluster has enough room to add new shards." }
- exists: indicators.shards_capacity.details.data.max_shards_in_cluster
- exists: indicators.shards_capacity.details.frozen.max_shards_in_cluster
# The shards_availability indicator is dependent on HealthMetadata being present in the cluster state, which we can't guarantee.
- is_true: indicators.shards_capacity.status
- is_true: indicators.shards_capacity.symptom

- is_true: indicators.data_stream_lifecycle.status
- is_true: indicators.data_stream_lifecycle.symptom

0 comments on commit 55431dd

Please sign in to comment.