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 issue between vertx-hk2 and vertx-jersey #8

Closed
ericsantosn opened this issue Apr 24, 2018 · 3 comments
Closed

Split package issue between vertx-hk2 and vertx-jersey #8

ericsantosn opened this issue Apr 24, 2018 · 3 comments

Comments

@ericsantosn
Copy link

I've been trying to migrate a service to java 9 and despite the fact that I can compile and run the fat.jar, I can't run it on Intellij and reason is the split package issues with the libraries vertx-hk2 and vertx.jersey since both libraries have exactly the same package com.englishtown.vertx.hk2

I tried to workaround this issue with ideas like(patching-modules, excluding) but nothing seems to work an I cant just exclude one of those since both are essential for the service run.

when intellij tries to execute the service this happens

Error occurred during initialization of boot layer
java.lang.module.ResolutionException: Modules vertx.jersey and vertx.hk2 export package com.englishtown.vertx.hk2 to module kryo.serializers

Process finished with exit code 1

I'm sorry to use this channel for questions like that, I just didn't found a different way to reach you guys

https://stackoverflow.com/questions/50007012/vertx-hk2-and-vertx-jersey-split-package-issue-on-intellij

@adrianluisgonzalez
Copy link
Member

adrianluisgonzalez commented Apr 24, 2018

Yeah, that's a problem we have been delaying until we internally upgrade I'm afraid.

You might be able to work around by shading the packages (maven-shade-plugin) to create your own merged vertx-hk2 and vertx-jersey jar.
http://maven.apache.org/plugins/maven-shade-plugin/examples/class-relocation.html

@ericsantosn
Copy link
Author

@adrianluisgonzalez yes I went for this idea the shaded.jar worked for me with this approach I managed to bypass the split package issue, will be nice in the future if the libraries can coexist without it :)

thanks for taking time to answer my question.

@adrianluisgonzalez
Copy link
Member

Glad shading worked.

Our plan is to change the groupId and packages from com.englishtown to io.eflabs and will fix the split package issue at the same time. Afraid I don't have a time frame yet.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants