0
votes

I am trying to deploy jersey RESTFUL webservice on WAS 8.5.5 but receiving following error

com.ibm.ws.webcontainer.webapp.WebApp logServletError SRVE0293E: [Servlet Error]-[RestServlet]: org.glassfish.jersey.server.ContainerException: java.lang.LinkageError: getExchangeRate(Ljava/lang/String;)Ljavax/ws/rs/core/Response;

But the same works fine in weblogic.

Following are the jars I am using for jersey and eclipelink -

javax.persistence-2.0.0.jar
org.eclipse.persistence.antlr-2.5.0.jar
org.eclipse.persistence.asm-2.5.0.jar
org.eclipse.persistence.core-2.5.0.jar
org.eclipse.persistence.jpa-2.5.0.jar
org.eclipse.persistence.jpa.jpql-2.5.0.jar
aopalliance-repackaged-2.4.0-b25.jar
hk2-api-2.4.0-b25.jar
hk2-locator-2.4.0-b25.jar
hk2-utils-2.4.0-b25.jar
javassist-3.18.1-GA.jar
javax.annotation-api-1.2.jar
javax.inject-2.4.0-b25.jar
javax.ws.rs-api-2.0.1.jar
jersey-client-2.19.jar
jersey-common-2.19.jar
jersey-container-servlet-2.19.jar
jersey-container-servlet-core-2.19.jar
jersey-guava-2.19.jar
jersey-media-jaxb-2.19.jar
jersey-server-2.19.jar
osgi-resource-locator-1.0.1.jar
validation-api-1.1.0.Final.jar

I also updated class loading policy for both application and module to "Classes loaded with local class loader first (parent last)" , but still the issue persist. Does WAS requires any other configuration to resolve this issue?

1

1 Answers

1
votes

Try disabling the built-in jaxrs engine.

Set the com.ibm.websphere.jaxrs.server.DisableIBMJAXRSEngine custom JVM property on the application server with a value of true.

http://www.ibm.com/support/knowledgecenter/SSEQTP_8.5.5/com.ibm.websphere.base.iseries.doc/ae/twbs_jaxrs_disable_runtime.html?lang=en