-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Add optional section of node analyzers into NodeInfo #10296
base: main
Are you sure you want to change the base?
Conversation
Gradle Check (Jenkins) Run Completed with:
|
Compatibility status:Checks if related components are compatible with change a9f4e77 Incompatible componentsSkipped componentsCompatible componentsCompatible components: [https://github.com/opensearch-project/custom-codecs.git, https://github.com/opensearch-project/geospatial.git, https://github.com/opensearch-project/flow-framework.git, https://github.com/opensearch-project/observability.git, https://github.com/opensearch-project/cross-cluster-replication.git, https://github.com/opensearch-project/job-scheduler.git, https://github.com/opensearch-project/opensearch-oci-object-storage.git, https://github.com/opensearch-project/k-nn.git, https://github.com/opensearch-project/ml-commons.git, https://github.com/opensearch-project/neural-search.git, https://github.com/opensearch-project/asynchronous-search.git, https://github.com/opensearch-project/security-analytics.git, https://github.com/opensearch-project/sql.git, https://github.com/opensearch-project/reporting.git, https://github.com/opensearch-project/notifications.git, https://github.com/opensearch-project/common-utils.git, https://github.com/opensearch-project/anomaly-detection.git, https://github.com/opensearch-project/index-management.git, https://github.com/opensearch-project/alerting.git, https://github.com/opensearch-project/security.git, https://github.com/opensearch-project/performance-analyzer-rca.git, https://github.com/opensearch-project/performance-analyzer.git] |
Gradle Check (Jenkins) Run Completed with:
|
Hello @lukas-vlcek @reta @andrross This PR needs to be merged by today to get in to 2.12.0 release. Can you please take necessary action (i.e. comment, merge or label it to future version etc..) as soon as possible? |
Thanks @bbarani I sadly failed to convey my concerns to @lukas-vlcek related to public API changes here, leaving it up to other maintainers to look at it. |
We can't take a breaking change into 2.x, is there a non-breaking change version of this? |
+1. If this new API implementation is introducing breaking changes, we should push it out. |
@dblock @Pallavi-AWS Sorry if I managed to confuse your, I don't think the changes in public API are breaking, the concerns I see are part of this discussion #10296 (comment), TLDR; I think the |
@@ -59,6 +60,7 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/), | |||
- Add task completion count in search backpressure stats API ([#10028](https://github.com/opensearch-project/OpenSearch/pull/10028/)) | |||
- Deprecate CamelCase `PathHierarchy` tokenizer name in favor to lowercase `path_hierarchy` ([#10894](https://github.com/opensearch-project/OpenSearch/pull/10894)) | |||
- Switched to more reliable OpenSearch Lucene snapshot location([#11728](https://github.com/opensearch-project/OpenSearch/pull/11728)) | |||
- Breaking change: "search_pipelines" metric is not included in NodesInfoRequest by default ([#10296](https://github.com/opensearch-project/OpenSearch/pull/10296)) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar to @dblock's comment. We don't want to bring breaking changes into 2.x. Can you separate out this change from this PR?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sigh... I feel really badly about this one, since I never should have included the search_pipelines
section in the default NodesInfoRequest
. @lukas-vlcek was just cleaning up my mess.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we could we address that separately?
/** | ||
* Returns registered keys of {@link Analyzer}s on this node. | ||
*/ | ||
public Set<String> getNodeAnalyzersKeys() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think I agree with @reta regarding the Java API concerns. This is basically an example of a "stringly typed" pattern and as Andriy mentioned it really restricts maintainability as the code evolves.
@reta The breaking change is:
and it's not obvious to me why it is required for this change. |
Hm .. I think it should be not part of this pull request, great catch @andrross ! |
Thanks for review all. Let's discuss individual concerns/issues here. Assuming we want to move forward with this PR and target next possible release (if you feel otherwise, please let me know). Breaking changeWhy this PR contains a breaking change in Nodes Info REST API (see @msfroh comment for context) and should that be handled as a separate PR? In short: yes it should. But the point here is that nodes analysis components (subject of this PR) should not be included in the list of Nodes Info metrics by default. It should be excluded the same way Michael wanted to exclude the search pipelines. Java API concernsRegarding the Java API concerns (mentioned here). I will be completely honest here: If what you are recommending is to turn returning The documentation partThere is also a documentation PR which includes a lot of improvements and some fixes that are independent on the Nodes Analyzers feature. I can go and rework the documentation PR so that Nodes Analyzers content is extracted and the rest can be pushed with the next 2.x release. |
I would make a breaking change in main, but backport it as a non-breaking change to 2.x. |
I'm definitely in favor of moving forward with the feature and I think other folks are as well.
I think that is the crux of @reta's feedback. The string-based approach is likely to be insufficient for some future use case and will require additional APIs alongside the string-based APIs and that will be clumsy and/or redundant. I think a small POJO-like object is pretty simple and will be more extensible and will alleviate the concerns here.
Please feel free to include the improvements separate from the new analyzers feature. Also, I believe documentation improvements for existing features are not tied to releases and can be made at any time. |
This functionality was introduced in PR opensearch-project/OpenSearch#10296 Signed-off-by: Lukáš Vlček <lukas.vlcek@aiven.io>
This functionality was introduced in PR opensearch-project/OpenSearch#10296 Signed-off-by: Lukáš Vlček <lukas.vlcek@aiven.io>
@lukas-vlcek @andrross Is this getting merged and backported to 2.13 (we have 1-2 weeks max)? @andrross all yours to CR/merge. I imagine we want this in first and then merge #12497 only to main? |
Signed-off-by: Daniel (dB.) Doubrovkine <dblock@amazon.com>
The only thing that is "blocking" #12497 from merging to Then I need to update this PR to contain only the relevant parts that need to go to |
@lukas-vlcek I merged #12497, set documentation aside. Want to rebase/update this? |
@getsaurabh02 - Is this being delivered with 2.14? I have an accompanying doc PR that I need to know what to do with. Thanks! |
We briefly touched upon this in today's community meeting. Moving this to 2.15 since we yet to close the PR |
Thanks. I'll update the label. |
@getsaurabh02 - Is this confirmed for 2.15? |
Description
A first implementation proposal of a new REST API called "Nodes Analyzers".
There are some changes/extensions to original "core" API to avoid use of Java reflections.
I still need to add a few more tests. Especially tests that will set up a few artificial cluster nodes with controlled set of plugins and then verifying that the response contains all that is required (including Hunspell dictionaries).
Original proposal that was implemented as a plugin included some interesting REST API tests (see https://github.com/lukas-vlcek/OpenSearch-list-built-in-analyzers/). I think we will need to reimplement these differently.
Related Issues
Resolves #5481
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.