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

ClassNotFoundException JAXBContext in camel-core-impl #1161

Closed
galderz opened this issue Apr 28, 2020 · 12 comments
Closed

ClassNotFoundException JAXBContext in camel-core-impl #1161

galderz opened this issue Apr 28, 2020 · 12 comments
Assignees
Milestone

Comments

@galderz
Copy link
Contributor

galderz commented Apr 28, 2020

Seeing the following with OpenJDK 11 based GraalVM:

Fatal error:com.oracle.graal.pointsto.util.AnalysisError$ParsingError: Error encountered while parsing org.apache.camel.quarkus.core.FastCamelContext.createModelJAXBContextFactory()
Parsing context:
	parsing org.apache.camel.impl.engine.AbstractCamelContext.getModelJAXBContextFactory(AbstractCamelContext.java:3716)
	parsing com.oracle.svm.reflect.AbstractCamelContext_getModelJAXBContextFactory_477828eef27cc93cb9372a4eb40fd739c75455ee_1093.invoke(Unknown Source)
	parsing java.base@11.0.8-internal/java.lang.reflect.Method.invoke(Method.java:566)
...
Caused by: java.lang.NoClassDefFoundError: javax/xml/bind/JAXBContext
	at java.base/java.lang.Class.getDeclaredMethods0(Native Method)
	at java.base/java.lang.Class.privateGetDeclaredMethods(Class.java:3166)
	at java.base/java.lang.Class.getDeclaredMethods(Class.java:2309)
	at jdk.internal.vm.ci/jdk.vm.ci.hotspot.HotSpotResolvedObjectTypeImpl.getDeclaredMethods(HotSpotResolvedObjectTypeImpl.java:932)

Longer output

@galderz
Copy link
Contributor Author

galderz commented Apr 28, 2020

This should be solvable adding jaxb dependency.

Note what I said in a similar situation here. Adding such dependency has no influence in the final image, it's just to make the pointsto analysis JVMCI layer used in stock OpenJDK 11 work.

@lburgazzoli
Copy link
Contributor

@davsclaus
Copy link
Contributor

@galderz
Copy link
Contributor Author

galderz commented Apr 28, 2020

Oh nice, great timing @davsclaus. Would a 3.3.0-SNAPSHOT camel version work with the current camel-quarkus?

@lburgazzoli
Copy link
Contributor

We have branch but it does not target quarkus snapshots, guess we can add a workaround for now and reference this issue to remove it when migrating to camel 3.3.x

@galderz
Copy link
Contributor Author

galderz commented Apr 29, 2020

Sounds good. I'll try to fix it with a workaround and see how it goes...

galderz added a commit to galderz/camel-quarkus that referenced this issue Apr 29, 2020
@galderz
Copy link
Contributor Author

galderz commented Apr 29, 2020

The workaround (galderz@3da275e) worked. I'm letting the testsuite continue and see what else comes up.

galderz added a commit to galderz/camel-quarkus that referenced this issue Apr 30, 2020
galderz added a commit to galderz/camel-quarkus that referenced this issue May 5, 2020
galderz added a commit to galderz/camel-quarkus that referenced this issue May 5, 2020
@ppalaga
Copy link
Contributor

ppalaga commented May 12, 2020

@ppalaga ppalaga self-assigned this May 12, 2020
jamesnetherton added a commit to jamesnetherton/camel-quarkus that referenced this issue May 13, 2020
@jamesnetherton
Copy link
Contributor

@galderz FYI - this change seems to increase the time taken to complete the integration test native builds by around 50%. Our CI build takes around twice as long to complete now. I've not dug into the specifics around why there's such a dramatic change.

Since the Camel 3.3.0 release is imminent, we can probably live with it for now, or at least work around it.

@galderz
Copy link
Contributor Author

galderz commented May 18, 2020

@jamesnetherton How imminent is the Camel 3.3.0 release?

@jamesnetherton
Copy link
Contributor

@galderz It's available now and we already upgraded the master branch.

@ppalaga ppalaga added this to the 1.0.0-CR1 milestone May 27, 2020
@galderz
Copy link
Contributor Author

galderz commented May 28, 2020

I'll give master a go and see how it goes.

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

5 participants