-
Notifications
You must be signed in to change notification settings - Fork 58
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
Enforce type safety for ExtensionNamedWriteableRegistry #203
Conversation
Signed-off-by: mloufra <mloufra@amazon.com>
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.
Looking good! One minor nit.
src/main/java/org/opensearch/sdk/ExtensionNamedWriteableRegistry.java
Outdated
Show resolved
Hide resolved
Signed-off-by: mloufra <mloufra@amazon.com>
src/main/java/org/opensearch/sdk/ExtensionNamedWriteableRegistry.java
Outdated
Show resolved
Hide resolved
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.
You only need to suppress an unchecked cast when you actually cast. After updating to the maven local you didn't need to cast any more, so you don't need to suppress any more either!
Signed-off-by: mloufra <mloufra@amazon.com>
…roject#203) * add generic type Signed-off-by: mloufra <mloufra@amazon.com> * move @SuppressWarnings at lowest scope possible Signed-off-by: mloufra <mloufra@amazon.com> * remove @SuppressWarnings Signed-off-by: mloufra <mloufra@amazon.com> Signed-off-by: mloufra <mloufra@amazon.com>
Signed-off-by: mloufra mloufra@amazon.com
Description
Add generic type for
categoryClass
inExtensionNamedWriteableRegistry
andTestNamedWriteableRegistryAPI
Equivalent PR on OpenSearch: opensearch-project/OpenSearch#4923
Issues Resolved
#130
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.