java - NoSuchMethodError when using jersey 2.0 -


I am using Jersey 2.0 and I am getting the following exception when requesting:

  SEVERE: Standard Defrager. Imposing java.lang.NoSuchMethodError: com.google.common.collect.Sets.newIdentityHashSet () Ljava / util / Set; . Init & gt; Org.glassfish.jersey.model.internal.CommonConfig & lt at (CommonConfig.java:215) org.glassfish.jersey.server.ResourceConfig $ in the state & lt; Init & gt; Org at (ResourceConfig.java:107) .glassfish.jersey.server.ResourceConfig & Lt; Init & gt; (ResourceConfig.java:338) on org.glassfish.jersey.servlet.WebComponent.createResourceConfig (WebComponent.java:373) on org.glassfish.jersey.servlet.WebComponent. & Lt; Init & gt; (WebComponent.java:259) javax.servlet On org.glassfish.jersey.servlet.ServletContainer.init (ServletContainer.java:167) org.glassfish.jersey.servlet.ServletContainer.init (ServletContainer.java:349). GenericServlet.init (GenericServlet.java:160) org.apache.catalina.core.StandardWrapper.initServlet (StandardWrapper.java:1280) on org.apache.catalina.core.StandardWrapper.loadServlet (on StandardWrapper.java: 11 9 3) on org.apache.catalina.core.StandardWrapper.allocate (StandardWrapper.java:865) on org.apache.catalina.authenticator.AuthenticatorBase.invoke (AuthenticatorBase.java:502) on org.apache.catalina.core.StandardWrapperValve.invoke on org.apache.catalina.core.StandardContextValve.invoke (StandardContextValve.java:123) (StandardWrapperValve.java:136) on org.apache. catalina.core.StandardHostValve.invoke (StandardHostValve.java:171) org.apache.catalina.valves.ErrorReportValve.invoke (ErrorReportValve.java:100) on org.apache.catalina.valves.AccessLogValve.invoke (on AccessLogValve.java: 953) org.apache.catalina.core.StandardEngineValve.invoke (StandardEngineValve.java:118) on org.apache.catalina.connector.CoyoteAdapter.service (CoyoteAdapter.java:408) on org.apache.coyote.http11.AbstractHttp11Processor on .process (AbstractHttp11Processor.java:1041) org.apache.coyote.AbstractProtocol $ AbstractConnectionHandler.process (AbstractProtocol.java:603) on org.apache.tomcat.util.net.JIoEndpoint $ SocketProcessor.run (JIoEndpoint.java:310 ) on Java.util.concurrent.ThreadPoolExecutor.runWorker (unknown Sourc e) java.util.concurrent.ThreadPoolExecutor $ Worker.run (unknown source JavaklangkThreadkrun) (unknown source)  

these jars I am using:

enter image details here

I think I have some problem with Jarar I am using but I do not know what is missing. If I do not use Maven then I'm going to take a jar straight.

In addition, I'm also implementing a filter (ContainerResponseFilter) in my app, maybe it's something to do with the exception, I do not know.

This is probably caused by a different, incompatible versions of the Google collection (now part of Gwawa) your dependencies In Jersey Library it was compiled against one version and now during the runtime a second version of it is full for the first time. Try leaving Google-archive or paragraph collection with your dependency.


Comments

Popular posts from this blog

java - org.apache.http.ProtocolException: Target host is not specified -

java - Gradle dependencies: compile project by relative path -

ruby on rails - Object doesn't support #inspect when used with .include -