Add verbose pipeline parameter to output each processor's execution details#16843
Merged
owaiskazi19 merged 23 commits intoopensearch-project:mainfrom Jan 23, 2025
Merged
Conversation
d5a2c4c to
d931750
Compare
owaiskazi19
reviewed
Jan 22, 2025
server/src/main/java/org/opensearch/search/pipeline/ProcessorExecutionDetail.java
Show resolved
Hide resolved
Signed-off-by: Junwei Dai <junweid@amazon.com>
Contributor
msfroh
reviewed
Jan 22, 2025
Contributor
msfroh
left a comment
There was a problem hiding this comment.
Thanks, @junweid62! It's looking pretty good.
I just had a few comments, mostly around code that I think you can safely remove.
server/src/main/java/org/opensearch/search/pipeline/Pipeline.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/opensearch/search/pipeline/Pipeline.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/opensearch/search/pipeline/PipelinedRequest.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/opensearch/search/pipeline/SearchPipelineService.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/opensearch/search/pipeline/TrackingSearchRequestProcessorWrapper.java
Outdated
Show resolved
Hide resolved
server/src/main/java/org/opensearch/search/pipeline/TrackingSearchResponseProcessorWrapper.java
Show resolved
Hide resolved
Signed-off-by: Junwei Dai <junweid@amazon.com>
owaiskazi19
approved these changes
Jan 22, 2025
Member
There was a problem hiding this comment.
LGTM! Thanks for patiently addressing all the comments. Can merge after @msfroh review. Please make sure to perform the BWC process on the PR
Contributor
|
❌ Gradle check result for 386d1f9: 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? |
Signed-off-by: Junwei Dai <junweid@amazon.com>
msfroh
reviewed
Jan 22, 2025
server/src/main/java/org/opensearch/search/pipeline/TrackingSearchRequestProcessorWrapper.java
Show resolved
Hide resolved
server/src/main/java/org/opensearch/search/pipeline/TrackingSearchResponseProcessorWrapper.java
Show resolved
Hide resolved
Contributor
|
❌ Gradle check result for 1ccc9c6: 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? |
added 2 commits
January 22, 2025 16:27
Signed-off-by: Junwei Dai <junweid@amazon.com>
Signed-off-by: Junwei Dai <junweid@amazon.com>
msfroh
approved these changes
Jan 23, 2025
Contributor
opensearch-trigger-bot bot
pushed a commit
that referenced
this pull request
Jan 23, 2025
…etails (#16843) * Add verbose pipeline parameter to output each processor's execution details Signed-off-by: Junwei Dai <junweid@amazon.com> * add change log Signed-off-by: Junwei Dai <junweid@amazon.com> # Conflicts: # CHANGELOG.md * Refactor ProcessorExecutionDetail to improve field handling Signed-off-by: Junwei Dai <junweid@amazon.com> * Fix ITtest Fail Signed-off-by: Junwei Dai <junweid@amazon.com> * Add more unit test Signed-off-by: Junwei Dai <junweid@amazon.com> * resolve comments Signed-off-by: Junwei Dai <junweid@amazon.com> * 1.add todo to change version.current 2.use exist xcontentUtil to read 3.move processor excution key to ProcessorExecutionDetail Signed-off-by: Junwei Dai <junweid@amazon.com> * refactor code Signed-off-by: Junwei Dai <junweid@amazon.com> * refactor code based on the comment Signed-off-by: Junwei Dai <junweid@amazon.com> * refactor code based on the comment Signed-off-by: Junwei Dai <junweid@amazon.com> * 1.add javadoc 2.refactor error message Signed-off-by: Junwei Dai <junweid@amazon.com> * change error message Signed-off-by: Junwei Dai <junweid@amazon.com> * 1.Added wrappers for tracking execution details of search processors. 2.Removed redundant logic for cleaner and simpler implementation. Signed-off-by: Junwei Dai <junweid@amazon.com> * change version to 3.0.0 Signed-off-by: Junwei Dai <junweid@amazon.com> * fix unit test Signed-off-by: Junwei Dai <junweid@amazon.com> * fix unit test Signed-off-by: Junwei Dai <junweid@amazon.com> * addressed comments 1. removed unnecessary log Signed-off-by: Junwei Dai <junweid@amazon.com> * addressed comments Signed-off-by: Junwei Dai <junweid@amazon.com> * revise comment to opensearch.api Signed-off-by: Junwei Dai <junweid@amazon.com> * removed unused logger and comment Signed-off-by: Junwei Dai <junweid@amazon.com> * removed unnecessary try catch block. add more comment Signed-off-by: Junwei Dai <junweid@amazon.com> * addressed comments Signed-off-by: Junwei Dai <junweid@amazon.com> * remove wrong unit test Signed-off-by: Junwei Dai <junweid@amazon.com> --------- Signed-off-by: Junwei Dai <junweid@amazon.com> Co-authored-by: Junwei Dai <junweid@amazon.com> (cherry picked from commit e15f712) Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
3 tasks
3 tasks
owaiskazi19
pushed a commit
that referenced
this pull request
Jan 23, 2025
…r's execution (#17097) * Add verbose pipeline parameter to output each processor's execution details (#16843) * Add verbose pipeline parameter to output each processor's execution details Signed-off-by: Junwei Dai <junweid@amazon.com> * add change log Signed-off-by: Junwei Dai <junweid@amazon.com> # Conflicts: # CHANGELOG.md * Refactor ProcessorExecutionDetail to improve field handling Signed-off-by: Junwei Dai <junweid@amazon.com> * Fix ITtest Fail Signed-off-by: Junwei Dai <junweid@amazon.com> * Add more unit test Signed-off-by: Junwei Dai <junweid@amazon.com> * resolve comments Signed-off-by: Junwei Dai <junweid@amazon.com> * 1.add todo to change version.current 2.use exist xcontentUtil to read 3.move processor excution key to ProcessorExecutionDetail Signed-off-by: Junwei Dai <junweid@amazon.com> * refactor code Signed-off-by: Junwei Dai <junweid@amazon.com> * refactor code based on the comment Signed-off-by: Junwei Dai <junweid@amazon.com> * refactor code based on the comment Signed-off-by: Junwei Dai <junweid@amazon.com> * 1.add javadoc 2.refactor error message Signed-off-by: Junwei Dai <junweid@amazon.com> * change error message Signed-off-by: Junwei Dai <junweid@amazon.com> * 1.Added wrappers for tracking execution details of search processors. 2.Removed redundant logic for cleaner and simpler implementation. Signed-off-by: Junwei Dai <junweid@amazon.com> * change version to 3.0.0 Signed-off-by: Junwei Dai <junweid@amazon.com> * fix unit test Signed-off-by: Junwei Dai <junweid@amazon.com> * fix unit test Signed-off-by: Junwei Dai <junweid@amazon.com> * addressed comments 1. removed unnecessary log Signed-off-by: Junwei Dai <junweid@amazon.com> * addressed comments Signed-off-by: Junwei Dai <junweid@amazon.com> * revise comment to opensearch.api Signed-off-by: Junwei Dai <junweid@amazon.com> * removed unused logger and comment Signed-off-by: Junwei Dai <junweid@amazon.com> * removed unnecessary try catch block. add more comment Signed-off-by: Junwei Dai <junweid@amazon.com> * addressed comments Signed-off-by: Junwei Dai <junweid@amazon.com> * remove wrong unit test Signed-off-by: Junwei Dai <junweid@amazon.com> --------- Signed-off-by: Junwei Dai <junweid@amazon.com> Co-authored-by: Junwei Dai <junweid@amazon.com> (cherry picked from commit e15f712) Signed-off-by: Junwei Dai <junweid@amazon.com> * bring back the constructor SearchResponseSections Signed-off-by: Junwei Dai <junweid@amazon.com> * bring back the constructor InternalSearchResponse Signed-off-by: Junwei Dai <junweid@amazon.com> --------- Signed-off-by: Junwei Dai <junweid@amazon.com> Co-authored-by: Junwei Dai <junweid@amazon.com>
Merged
1 task
This was referenced Jan 13, 2026
This was referenced Feb 18, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Jan 16 revision:
When the verbose pipeline mode is enabled, if a processor encounters an error during execution, the search process will not be interrupted. Instead, the error will be documented in the processor's execution details (e.g., in ProcessorExecutionDetail) and the remaining search process will proceed as normal.
Description
Related RFC : #16705
This PR introduces enhancements to OpenSearch's search pipeline functionality, focusing on improving the traceability and debugging of search request and response transformations. It addresses the increasing complexity of search pipeline processors by implementing verbose mode support, which provides detailed insights into processor execution.
Adds Verbose Mode for Search Pipelines:
verbose_pipelineparameter to search requests, default to false.Improves Pipeline Debugging:
Supports All Pipeline Configurations:
Test Framework Enhancements:
Example output with request processor:
filter_queryresponse processor:rename_fieldandsortRelated Issues
Resolves #14745
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.