Support Topics Documentation Slack YouTube Blog

jersey-core library

(Samuel Castro) #1

Hi to all,
I wish you could help me with this issue:
When I try to deploy my custom server code through the coderunner Im getting a long error, in short it says:

Caused by: java.lang.NullPointerException: null
at com.sun.jersey.core.provider.jaxb.AbstractJAXBProvider.setConfiguration(


Caused by: org.glassfish.hk2.api.MultiException: A MultiException has 3 exceptions. They are:
1. java.lang.NullPointerException
2. java.lang.IllegalStateException: Unable to perform operation: method inject on com.sun.jersey.core.impl.provider.entity.XMLRootElementProvider$App
3. java.lang.IllegalStateException: Unable to perform operation: create on org.glassfish.jersey.message.internal.MessageBodyFactory

Google says this error happens when you try to compile jersey-core library with two versions referenced(I only have the jersey-core-1-8-1.jar), in fact I can compile the proyect but the error appears when I try to deploy to the coderunner, so I guess maybe I am causing a conflict with a internal library used by the coderunner, could you help me to discard the coderunner as cause of the issue please?
Thanks for your support.

error.rtf (6.79kB)

(Sergey Chupov) #2

Hi Samuel,

Look like you’re right, CodeRunner dependencies contain a few mentions of jersey-core:

CodeRunner $ mvn dependency:tree | grep "jersey"
[INFO] +- org.glassfish.jersey.core:jersey-client:jar:2.7:compile
[INFO] | +- org.glassfish.jersey.core:jersey-common:jar:2.7:compile
[INFO] | | +- org.glassfish.jersey.bundles.repackaged:jersey-guava:jar:2.7:compile
[INFO] +-
[INFO] | +- org.glassfish.jersey.core:jersey-server:jar:2.7:compile

Could you please elaborate on what do you need this library for? Probably we could suggest you another approach or if not you might be able to reuse the one from CodeRunner.

(Samuel Castro) #3

Hi Sergey,

I tried to add the same version of the libraries(2.7) but it didn’t work, fortunately I could change the library that needed of the jersey library, now it works.

Thank you.

(Abel Matos) #4

I have the same problem.
Do you found some solution?

(Samuel Castro) #5

No, the only “solution” was to uninstall the Jersey library in my project, I had to change the approach.