Skip to content
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

Fixed compilation errors after refactoring in core #249

Conversation

martin-gaievski
Copy link
Member

Description

Fixed compilation errors after refactoring in core foundation classes (opensearch-project/OpenSearch#9082)

Check List

  • All tests pass
  • Commits are signed as per the DCO using --signoff

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.

@martin-gaievski
Copy link
Member Author

martin-gaievski commented Aug 11, 2023

PR will fail for now because similar fix is missing in ml-commons and k-nn. ml-commons PR merged opensearch-project/ml-commons#1200. knn PR created: opensearch-project/k-NN#1038

@martin-gaievski martin-gaievski added Maintenance Add support for new versions of OpenSearch/Dashboards from upstream skip-changelog labels Aug 11, 2023
Signed-off-by: Martin Gaievski <gaievski@amazon.com>
@martin-gaievski martin-gaievski force-pushed the fix_compilatin_errors_after_actionlistener_refactoring_in_core branch from bb20d10 to 6386d5c Compare August 11, 2023 20:17
@martin-gaievski martin-gaievski marked this pull request as ready for review August 11, 2023 20:57
@naveentatikonda
Copy link
Member

naveentatikonda commented Aug 11, 2023

The build is still failing

java.lang.NoClassDefFoundError: org/opensearch/action/ActionListener
»  	at org.opensearch.knn.index.util.Nmslib.<clinit>(Nmslib.java:36)
»  	at org.opensearch.knn.index.util.KNNEngine.<clinit>(KNNEngine.java:28)
»  	at org.opensearch.knn.plugin.KNNPlugin.additionalSettings(KNNPlugin.java:355)
»  	at org.opensearch.plugins.PluginsService.updatedSettings(PluginsService.java:243)
»  	at org.opensearch.node.Node.<init>(Node.java:465)
»  	at org.opensearch.node.Node.<init>(Node.java:388)
»  	at org.opensearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:242)
»  	at org.opensearch.bootstrap.Bootstrap.setup(Bootstrap.java:242)
»  	at org.opensearch.bootstrap.Bootstrap.init(Bootstrap.java:404)
»  	at org.opensearch.bootstrap.OpenSearch.init(OpenSearch.java:180)
»  	at org.opensearch.bootstrap.OpenSearch.execute(OpenSearch.java:171)
»  	at org.opensearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:104)
»  	at org.opensearch.cli.Command.mainWithoutErrorHandling(Command.java:138)
»  	at org.opensearch.cli.Command.main(Command.java:101)
»  	at org.opensearch.bootstrap.OpenSearch.main(OpenSearch.java:137)
»  	at org.opensearch.bootstrap.OpenSearch.main(OpenSearch.java:103)
»  Caused by: java.lang.ClassNotFoundException: org.opensearch.action.ActionListener
»  	at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:445)
»  	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:592)
»  	at java.base/java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:872)
»  	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)

@martin-gaievski
Copy link
Member Author

The build is still failing

java.lang.NoClassDefFoundError: org/opensearch/action/ActionListener
»  	at org.opensearch.knn.index.util.Nmslib.<clinit>(Nmslib.java:36)
»  	at org.opensearch.knn.index.util.KNNEngine.<clinit>(KNNEngine.java:28)
»  	at org.opensearch.knn.plugin.KNNPlugin.additionalSettings(KNNPlugin.java:355)
»  	at org.opensearch.plugins.PluginsService.updatedSettings(PluginsService.java:243)
»  	at org.opensearch.node.Node.<init>(Node.java:465)
»  	at org.opensearch.node.Node.<init>(Node.java:388)
»  	at org.opensearch.bootstrap.Bootstrap$5.<init>(Bootstrap.java:242)
»  	at org.opensearch.bootstrap.Bootstrap.setup(Bootstrap.java:242)
»  	at org.opensearch.bootstrap.Bootstrap.init(Bootstrap.java:404)
»  	at org.opensearch.bootstrap.OpenSearch.init(OpenSearch.java:180)
»  	at org.opensearch.bootstrap.OpenSearch.execute(OpenSearch.java:171)
»  	at org.opensearch.cli.EnvironmentAwareCommand.execute(EnvironmentAwareCommand.java:104)
»  	at org.opensearch.cli.Command.mainWithoutErrorHandling(Command.java:138)
»  	at org.opensearch.cli.Command.main(Command.java:101)
»  	at org.opensearch.bootstrap.OpenSearch.main(OpenSearch.java:137)
»  	at org.opensearch.bootstrap.OpenSearch.main(OpenSearch.java:103)
»  Caused by: java.lang.ClassNotFoundException: org.opensearch.action.ActionListener
»  	at java.base/java.net.URLClassLoader.findClass(URLClassLoader.java:445)
»  	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:592)
»  	at java.base/java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:872)
»  	at java.base/java.lang.ClassLoader.loadClass(ClassLoader.java:525)

this should be fixed after knn change is merged and published to maven

@codecov
Copy link

codecov bot commented Aug 11, 2023

Codecov Report

Merging #249 (6386d5c) into main (2a9f70a) will not change coverage.
The diff coverage is n/a.

@@            Coverage Diff            @@
##               main     #249   +/-   ##
=========================================
  Coverage     86.29%   86.29%           
  Complexity      340      340           
=========================================
  Files            29       29           
  Lines           992      992           
  Branches        153      153           
=========================================
  Hits            856      856           
  Misses           70       70           
  Partials         66       66           
Files Changed Coverage Δ
...earch/neuralsearch/ml/MLCommonsClientAccessor.java 92.00% <ø> (ø)
...neuralsearch/processor/TextEmbeddingProcessor.java 92.85% <ø> (ø)
...nsearch/neuralsearch/query/NeuralQueryBuilder.java 89.01% <ø> (ø)

@martin-gaievski martin-gaievski merged commit 70675c8 into opensearch-project:main Aug 11, 2023
@navneet1v navneet1v added the backport 2.x Label will add auto workflow to backport PR to 2.x branch label Aug 16, 2023
opensearch-trigger-bot bot pushed a commit that referenced this pull request Aug 16, 2023
Signed-off-by: Martin Gaievski <gaievski@amazon.com>
(cherry picked from commit 70675c8)
@navneet1v navneet1v removed the backport 2.x Label will add auto workflow to backport PR to 2.x branch label Aug 16, 2023
navneet1v pushed a commit to navneet1v/neural-search that referenced this pull request Aug 17, 2023
…t#249)

Signed-off-by: Martin Gaievski <gaievski@amazon.com>
navneet1v added a commit that referenced this pull request Aug 17, 2023
….x branch (#253)

* Fixed compilation errors after refactoring in core (#249)

Signed-off-by: Martin Gaievski <gaievski@amazon.com>

* Fixing test classes after core refactoring (#237)

Signed-off-by: Martin Gaievski <gaievski@amazon.com>

* Fixed compilation errors after refactoring in core Strings class (#243)

Signed-off-by: Martin Gaievski <gaievski@amazon.com>

* Switch from XContentType to MediaType to fix compilation errors (#232)

Signed-off-by: Martin Gaievski <gaievski@amazon.com>

* Fixing the Media type being not able to be read from Headers.

Signed-off-by: Navneet Verma <navneev@amazon.com>

---------

Signed-off-by: Martin Gaievski <gaievski@amazon.com>
Signed-off-by: Navneet Verma <navneev@amazon.com>
Co-authored-by: Martin Gaievski <gaievski@amazon.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Maintenance Add support for new versions of OpenSearch/Dashboards from upstream skip-changelog
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants