Update `TermsAggregation`, `CardinalityExecutionMode` fields
Description
1. TermsAggregation: Removed unsupported fields
Removed missing_order and missing_bucket fields from TermsAggregation as they are not supported by TermsAggregationBuilder.
- Evidence:
TermsAggregationBuilder.PARSER(lines 119-159) does not parsemissing_orderormissing_bucketfields - Evidence:
TermsAggregationBuilder.doXContentBody()(lines 353-404) does not serialize these fields - These fields belong to
CompositeAggregationand were incorrectly included in theTermsAggregationspec
Source references:
- TermsAggregationBuilder.java#L119-L159 - Parser definition
- TermsAggregationBuilder.java#L353-L404 - Serialization
2. TermsAggregation: Added missing shard_min_doc_count field
Added the shard_min_doc_count field which is supported by TermsAggregationBuilder.PARSER but was missing from the spec
3. CardinalityExecutionMode: Added segment_ordinals enum value
Added segment_ordinals execution hint option introduced in OpenSearch 2.19.1 via PR #17312.
- Evidence: CardinalityAggregationBuilder#executionHint() method added in 2.19.1
Source references:
- PR #17312 - Introduce
execution_hintfor Cardinality aggregation - Commit 968eafb - Add execution_hint support
Issues Resolved
Part of https://github.com/opensearch-project/opensearch-protobufs/issues/30
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license. For more information on following Developer Certificate of Origin and signing off your commits, please check here.
Changes Analysis
Commit SHA: 1e400eaa5292eef563c8d0aa9d933a7d2db5c8fb Comparing To SHA: 8978c523e39389afa894ea3cc6fe7a19c624985e
API Changes
Summary
└─┬Components
├─┬_common.aggregations___TermsAggregation
│ └─┬ALLOF
│ ├──[➖] properties (43893:13)❌
│ ├──[➖] properties (43891:13)❌
│ └──[➕] properties (43905:13)
└─┬_common.aggregations___CardinalityExecutionMode
└──[➕] enum (41648:11)
| Document Element | Total Changes | Breaking Changes |
|---|---|---|
| components | 4 | 4 |
- ❌ BREAKING Changes: 4 out of 4
- Removals: 2
- Additions: 2
- Breaking Removals: 2
Report
The full API changes report is available at: https://github.com/opensearch-project/opensearch-api-specification/actions/runs/19878183105/artifacts/4745024278
API Coverage
| Before | After | Δ | |
|---|---|---|---|
| Covered (%) | 666 (65.23 %) | 666 (65.23 %) | 0 (0 %) |
| Uncovered (%) | 355 (34.77 %) | 355 (34.77 %) | 0 (0 %) |
| Unknown | 129 | 129 | 0 |
Spec Test Coverage Analysis
| Total | Tested |
|---|---|
| 682 | 680 (99.71 %) |