Skip to content

Fix Search API schema #860

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

karenyrx
Copy link

@karenyrx karenyrx commented Apr 2, 2025

Description

  1. Added verbose_pipeline to Search request spec.
  2. Remove ExplanationDetail . The type is just Explanation
  3. store field was added in https://github.com/opensearch-project/OpenSearch/pull/14774/files to TermsLookup.
  4. ValueType was added in 2.17 per https://opensearch.org/docs/latest/query-dsl/term/terms/#bitmap-filtering
  5. Specified the required fields in TermsLookup

Issues Resolved

General spec fixes, contributing to accuracy of the Search Protobufs:
opensearch-project/OpenSearch#16783
opensearch-project/opensearch-protobufs#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.

Signed-off-by: Karen Xu <[email protected]>
@karenyrx karenyrx marked this pull request as ready for review April 9, 2025 17:31
Signed-off-by: Karen Xu <[email protected]>
@karenyrx
Copy link
Author

hi @dblock @Xtansia this is ready for review, would you help take a look when you have time? thanks!

Copy link
Member

@dblock dblock left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Add a test please that uses verbose_pipeline.

@@ -53,7 +53,7 @@ Set up an OpenSearch cluster with Docker:
```bash
export OPENSEARCH_PASSWORD=<<your_password>>
cd tests/default
docker compose up -d
docker-compose up -d
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is incorrect, old version, https://docs.docker.com/compose/releases/migrate/.

properties:
value_type:
description: |-
Specifies the types of values used for filtering. Valid values are default and bitmap. If omitted, the value defaults to default.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we support default: default? Either way either:

Suggested change
Specifies the types of values used for filtering. Valid values are default and bitmap. If omitted, the value defaults to default.
Specifies the types of values used for filtering.

or

Suggested change
Specifies the types of values used for filtering. Valid values are default and bitmap. If omitted, the value defaults to default.
Specifies the types of values used for filtering. Valid values are `default` and `bitmap`. Default is `default`.

Copy link
Contributor

Changes Analysis

Commit SHA: 7dbb616
Comparing To SHA: 2dda6e1

API Changes

Summary

├─┬Paths
│ ├─┬/_search
│ │ ├─┬GET
│ │ │ └──[➕] parameters (26104:13)❌ 
│ │ └─┬POST
│ │   └──[➕] parameters (26104:13)❌ 
│ ├─┬/{index}/_search
│ │ ├─┬GET
│ │ │ └──[➕] parameters (26104:13)❌ 
│ │ └─┬POST
│ │   └──[➕] parameters (26104:13)❌ 
│ └─┬/{index}/_explain/{id}
│   ├─┬GET
│   │ └─┬Responses
│   │   └─┬200
│   │     └─┬application/json
│   │       └─┬Schema
│   │         └─┬explanation
│   │           └──[🔀] $ref (46424:13)❌ 
│   └─┬POST
│     └─┬Responses
│       └─┬200
│         └─┬application/json
│           └─┬Schema
│             └─┬explanation
│               └──[🔀] $ref (46424:13)❌ 
└─┬Components
  ├──[➕] parameters (26103:7)
  ├──[➖] schemas (46414:7)❌ 
  ├──[➕] schemas (46203:7)
  ├─┬_core.explain___Explanation
  │ └─┬details
  │   └─┬Schema
  │     └──[🔀] $ref (46424:13)❌ 
  ├─┬_common.query_dsl___TermsQuery
  │ ├──[➕] allOf (46150:11)
  │ └─┬ALLOF
  │   └──[🔀] $ref (46203:13)❌ 
  └─┬_common.query_dsl___TermsLookup
    ├──[➕] required (46144:11)❌ 
    ├──[➕] required (46145:11)❌ 
    ├──[➕] required (46143:11)❌ 
    └──[➕] properties (46140:9)

Document Element Total Changes Breaking Changes
paths 6 6
components 10 7
  • BREAKING Changes: 13 out of 16
  • Modifications: 4
  • Removals: 1
  • Additions: 11
  • Breaking Removals: 1
  • Breaking Modifications: 4
  • Breaking Additions: 7

Report

The full API changes report is available at: https://github.com/opensearch-project/opensearch-api-specification/actions/runs/14388002344/artifacts/2930667457

API Coverage

Before After Δ
Covered (%) 663 (64.94 %) 663 (64.94 %) 0 (0 %)
Uncovered (%) 358 (35.06 %) 358 (35.06 %) 0 (0 %)
Unknown 49 49 0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants