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

Runtime error with Java 9 #7177

Closed
benoitf opened this issue Nov 3, 2017 · 3 comments
Closed

Runtime error with Java 9 #7177

benoitf opened this issue Nov 3, 2017 · 3 comments
Assignees
Labels
kind/bug Outline of a bug - must adhere to the bug report template.
Milestone

Comments

@benoitf
Copy link
Contributor

benoitf commented Nov 3, 2017

Description

When using Java 9 to launch Eclipse Che, there are errors
NoClassDefFoundError for javax.activation package and also for javax.xml.bind

it's because Java runtime disable by default access to javax.* API

Fix can either be:

  • add the -add-modules java.activation --add-modules java.xml.bind option at runtime
  • package activation.jar / jaxb implementation in the war file so there is no need to expose API from the JVM

Reproduction Steps

Run Che with Java9 runtime

OS and version:
macOS High Sierra

Related to epic #5326

@benoitf benoitf added kind/bug Outline of a bug - must adhere to the bug report template. status/in-progress This issue has been taken by an engineer and is under active development. labels Nov 3, 2017
@benoitf benoitf self-assigned this Nov 3, 2017
@tsmaeder
Copy link
Contributor

tsmaeder commented Nov 3, 2017

I would prefer the first option, if the jar is already there, why duplicate it? Are there any downsides to this?

@benoitf
Copy link
Contributor Author

benoitf commented Nov 3, 2017

Option 1 allow to not increase size of war files as dependencies are provided by the JVM. The only downside of this approach is that each JVM may provide its own implementation of javax.activation and jaxb so it may not work for Che. (But in reality most of the JVMs are providing the same implementations and for Che stack we're always using the same vendor so downside is pretty null)

@benoitf benoitf added status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. and removed status/in-progress This issue has been taken by an engineer and is under active development. labels Nov 7, 2017
@benoitf
Copy link
Contributor Author

benoitf commented Nov 9, 2017

Fixed

@benoitf benoitf closed this as completed Nov 9, 2017
@benoitf benoitf removed the status/code-review This issue has a pull request posted for it and is awaiting code review completion by the community. label Nov 9, 2017
@benoitf benoitf added this to the 6.0.0-M2 milestone Nov 9, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Outline of a bug - must adhere to the bug report template.
Projects
None yet
Development

No branches or pull requests

2 participants