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

Split package between rest-client and rest-high-level-client makes it impossible to use elasticsearch clients in java 11 module path applications #37901

Closed
tomdw opened this issue Jan 27, 2019 · 17 comments
Assignees
Labels
Team:Data Management Meta label for data/management team

Comments

@tomdw
Copy link

tomdw commented Jan 27, 2019

Elasticsearch version 6.4.3

Plugins installed: []

JVM version adoptopenjdk 11

Description of the problem including expected versus actual behavior:

When you want to use the java high level rest client as automatic module on the module path of jdk 11 this is made impossible. Reason is a split package between org.elasticsearch.client:elasticsearch-rest-client:6.4.3 and org.elasticsearch.client:elasticsearch-rest-high-level-client:6.4.3 with the following error as result:

reads package org.elasticsearch.client from both elasticsearch.rest.high.level.client and elasticsearch.rest.client

Expected design: no split packages between jars, e.g. use org.elasticsearch.client.rest and org.elasticsearch.client.high.level.rest as packages

Steps to reproduce:

  1. create a java application on running on the module path
  2. require elasticsearch.rest.high.level.client in the module-info.java
  3. require elasticsearch.rest.client in the module-info.java
  4. use the client
  5. try to compile it with jdk 11 (using e.g. maven-compiler-plugin version 3.8.0)
@iverase
Copy link
Contributor

iverase commented Jan 28, 2019

Hi @tomdw,

Please refer to the support matrix located here:

https://www.elastic.co/support/matrix#matrix_jvm

As you can see, jdk 11 is only supported in Elasticsearch version 6.5.x. Therefore this is a non-issue and as such, I hope you don't mind that I close this.

@iverase
Copy link
Contributor

iverase commented Jan 28, 2019

I misunderstood the issue, this is related with the client and I am not sure if this is a set up that we support. I assign the issue to the corresponding group.

@elasticmachine
Copy link
Collaborator

Pinging @elastic/es-core-features

@swidom-exparency
Copy link

Has there been any progress on this? It is a problem for me too. I have a REST API client for my app that sits on top of the Elasticsearch REST API's (both High Level and non-High Level.) I am trying to use --patch-module without much success and am wondering if anyone has a pom.xml that they can share that resolves the JDK 11 compile issue. There are numerous split package problems besides the REST API's too, just as an FYI.

@r862
Copy link

r862 commented Feb 4, 2020

Is there any update on this?

@rjernst rjernst added the Team:Data Management Meta label for data/management team label May 4, 2020
@xingkuan
Copy link

i run into this issue as well. Any update? -Thanks.

@swidom-exparency
Copy link

swidom-exparency commented Jun 26, 2020 via email

@jbaker-dstl
Copy link

Is there an update on this issue?

@UkonnRa
Copy link

UkonnRa commented Nov 4, 2020

+1 Any update?

@andreibaptista
Copy link

Any update?

@pugnascotia
Copy link
Contributor

Hi folks. We are in the process of writing a new Java Elasticsearch client that will be separate from the Elasticsearch server codebase, which should solve these problems.

@philkra
Copy link
Contributor

philkra commented Aug 12, 2021

This is the new Java client: https://github.com/elastic/elasticsearch-java

@andreibaptista
Copy link

Hi folks. We are in the process of writing a new Java Elasticsearch client that will be separate from the Elasticsearch server codebase, which should solve these problems.

Perfect @pugnascotia, please give us updates

@ChrisHegarty
Copy link
Contributor

Hi, seems we have a new Java Client, as above, so what is the status of this issue? ( FYI - I am in the process of preparing the Elasticsearch code base for modularization and am running straight into this split package issue, see #78166 ). What can be done in the Elasticsearch main feature branch to resolve the split package issue?

@ChrisHegarty
Copy link
Contributor

The server package has been renamed to avoid collision with any rest client, see #81984

@swallez
Copy link
Member

swallez commented Dec 23, 2021

@ChrisHegarty so I guess we can now close this issue?

@ChrisHegarty
Copy link
Contributor

No objection from me.

@swallez swallez closed this as completed Jan 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Team:Data Management Meta label for data/management team
Projects
None yet
Development

No branches or pull requests