1

I am getting the below error after I upgraded from axis-1.3.jar to axis-1.4-osgi.jar

[9/16/19 6:13:07:783 CDT] 00000033 ServletWrappe E com.ibm.ws.webcontainer.servlet.ServletWrapper service SRVE0068E: Uncaught exception created in one of the service methods of the servlet <Servlet_name> in application <application_name>. Exception created : java.lang.NoClassDefFoundError: org.apache.axis.encoding.Serializer
    at java.lang.J9VMInternals.verifyImpl(Native Method)
    at java.lang.J9VMInternals.verify(J9VMInternals.java:73)
    at java.lang.J9VMInternals.initialize(J9VMInternals.java:133)
    ...
    ...
    ...
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:718)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
    at com.ibm.ws.cache.servlet.ServletWrapper.serviceProxied(ServletWrapper.java:307)
    at com.ibm.ws.cache.servlet.CacheHook.handleFragment(CacheHook.java:576)
    at com.ibm.ws.cache.servlet.CacheHook.handleServlet(CacheHook.java:250)
    at com.ibm.ws.cache.servlet.ServletWrapper.service(ServletWrapper.java:259)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1694)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:970)
    at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:508)
    at com.ibm.ws.webcontainer.servlet.ServletWrapperImpl.handleRequest(ServletWrapperImpl.java:181)
    at com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServletWrapper.java:91)
    at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:879)
    at com.ibm.ws.webcontainer.WSWebContainer.handleRequest(WSWebContainer.java:1592)
    at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:191)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:454)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewRequest(HttpInboundLink.java:516)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.processRequest(HttpInboundLink.java:307)
    at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:278)
    at com.ibm.ws.ssl.channel.impl.SSLConnectionLink.determineNextChannel(SSLConnectionLink.java:1070)
    at com.ibm.ws.ssl.channel.impl.SSLConnectionLink$MyReadCompletedCallback.complete(SSLConnectionLink.java:644)
    at com.ibm.ws.ssl.channel.impl.SSLReadServiceContext$SSLReadCompletedCallback.complete(SSLReadServiceContext.java:1820)
    at com.ibm.ws.tcp.channel.impl.AioReadCompletionListener.futureCompleted(AioReadCompletionListener.java:175)
    at com.ibm.io.async.AbstractAsyncFuture.invokeCallback(AbstractAsyncFuture.java:217)
    at com.ibm.io.async.AsyncChannelFuture$1.run(AsyncChannelFuture.java:205)
    at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1662)
Caused by: java.lang.ClassNotFoundException: org.apache.axis.encoding.Serializer
    at java.net.URLClassLoader.findClass(URLClassLoader.java:457)
    at com.ibm.ws.bootstrap.ExtClassLoader.findClass(ExtClassLoader.java:201)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:676)
    at com.ibm.ws.bootstrap.ExtClassLoader.loadClass(ExtClassLoader.java:112)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:642)
    at com.ibm.ws.classloader.ProtectionClassLoader.loadClass(ProtectionClassLoader.java:62)
    at com.ibm.ws.classloader.ProtectionClassLoader.loadClass(ProtectionClassLoader.java:58)
    at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java:513)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:642)
    ... 32 more

both JARs contains the class org.apache.axis.encoding.Serializer. then, what could be the cause of this issue.

fantaghirocco
  • 4,761
  • 6
  • 38
  • 48
Bala
  • 11
  • 1
  • Possible duplicate of [What causes and what are the differences between NoClassDefFoundError and ClassNotFoundException?](https://stackoverflow.com/questions/1457863/what-causes-and-what-are-the-differences-between-noclassdeffounderror-and-classn) – mustaccio Sep 17 '19 at 15:53

1 Answers1

1

Since org.apache.axis.encoding.Serializer is indeed in axis-1.4-osgi.jar (you can check at https://www.findjar.com/jar/mule/dependencies/maven2/org/apache/axis/axis/1.4-osgi/axis-1.4-osgi.jar.html?all=true) my guess is that this class is present in your IDE at compile time, but not in the server classpath when the application is starting/running (by inspecting the stacktrace, looks like you are trying to run a web application and the exception occurs at runtime).

Repoker
  • 202
  • 3
  • 12