-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Fix multi-search with template doesn't return status code #16265
Conversation
Signed-off-by: Gao Binlong <[email protected]>
Signed-off-by: Gao Binlong <[email protected]>
❌ Gradle check result for 8ecb0c9: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
modules/lang-mustache/src/main/java/org/opensearch/script/mustache/SearchTemplateResponse.java
Show resolved
Hide resolved
Thanks @gaobinlong , we would need API changes [1] (and may be documentation updates if we have any) [2]. [1] https://github.com/opensearch-project/opensearch-api-specification |
Thanks, I've created a document PR:opensearch-project/documentation-website#8522, and for the api-spec repo, I see now the msearch api and msearch template api uses same response schema: MultiSearchResult, so may no need to change it? |
Thanks @gaobinlong. I just briefly looked at it, seems like |
❌ Gradle check result for 9778ed5: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
|
Perfrect, thank you! |
❌ Gradle check result for 9778ed5: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
❌ Gradle check result for 9778ed5: FAILURE Please examine the workflow log, locate, and copy-paste the failure(s) below, then iterate to green. Is the failure a flaky test unrelated to your change? |
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #16265 +/- ##
============================================
+ Coverage 72.00% 72.07% +0.06%
- Complexity 64796 64828 +32
============================================
Files 5307 5307
Lines 302540 302544 +4
Branches 43708 43708
============================================
+ Hits 217853 218052 +199
+ Misses 66801 66646 -155
+ Partials 17886 17846 -40 ☔ View full report in Codecov by Sentry. |
The backport to
To backport manually, run these commands in your terminal: # Navigate to the root of your repository
cd $(git rev-parse --show-toplevel)
# Fetch latest updates from GitHub
git fetch
# Create a new working tree
git worktree add ../.worktrees/OpenSearch/backport-2.x 2.x
# Navigate to the new working tree
pushd ../.worktrees/OpenSearch/backport-2.x
# Create a new branch
git switch --create backport/backport-16265-to-2.x
# Cherry-pick the merged commit of this pull request and resolve the conflicts
git cherry-pick -x --mainline 1 55e98ed2735d898d884295c00f869f5f3278c222
# Push it to GitHub
git push --set-upstream origin backport/backport-16265-to-2.x
# Go back to the original working tree
popd
# Delete the working tree
git worktree remove ../.worktrees/OpenSearch/backport-2.x Then, create a pull request where the |
@gaobinlong could you please backport to |
…-project#16265) * Fix multi-search with template doesn't return status code Signed-off-by: Gao Binlong <[email protected]> * Modify changelog Signed-off-by: Gao Binlong <[email protected]> --------- Signed-off-by: Gao Binlong <[email protected]>
…ode (#16265) (#16312) * Fix multi-search with template doesn't return status code (#16265) * Fix multi-search with template doesn't return status code Signed-off-by: Gao Binlong <[email protected]> * Modify changelog Signed-off-by: Gao Binlong <[email protected]> --------- Signed-off-by: Gao Binlong <[email protected]> * Format the code Signed-off-by: Gao Binlong <[email protected]> --------- Signed-off-by: Gao Binlong <[email protected]>
…-project#16265) * Fix multi-search with template doesn't return status code Signed-off-by: Gao Binlong <[email protected]> * Modify changelog Signed-off-by: Gao Binlong <[email protected]> --------- Signed-off-by: Gao Binlong <[email protected]>
…-project#16265) * Fix multi-search with template doesn't return status code Signed-off-by: Gao Binlong <[email protected]> * Modify changelog Signed-off-by: Gao Binlong <[email protected]> --------- Signed-off-by: Gao Binlong <[email protected]>
…-project#16265) * Fix multi-search with template doesn't return status code Signed-off-by: Gao Binlong <[email protected]> * Modify changelog Signed-off-by: Gao Binlong <[email protected]> --------- Signed-off-by: Gao Binlong <[email protected]>
Description
Currently the multi-search API does return the status code in each search response, but multi-search template API does not, these two APIs are very similar, we should make the response consistent, so this PR adds a status code field in each search response for the multi-search template API.
Related Issues
#11133
Check List
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.