Discussion:
Filter error: NoClassDefFoundError for a class which is in the classpath
(too old to reply)
v***@yahoo.com
2006-11-21 06:42:24 UTC
Permalink
We are on WC 5.6.1. Our Stores web app has a validation filter, the filter works fine everywhere, but on one development machine(in WCToolkit test environment), it fails with the below missing class error. The below missing class is in the classpath.


[11/20/06 22:19:12:675 PST] 55355535 WebGroup E SRVE0026E: [Servlet Error]-[Filter [ValidationFilter]: com.test.validation.ValidationFilter was found, but is missing another required class.
]: java.lang.NoClassDefFoundError: org.apache.commons.validator.ValidatorException
at java.lang.Class.verifyImpl(Native Method)
at java.lang.Class.verify(Class.java:253)
at java.lang.Class.initialize(Class.java:315)
at java.lang.Class.newInstanceImpl(Native Method)
at java.lang.Class.newInstance(Class.java:1481)
at java.beans.Beans.instantiate(Beans.java:219)
at java.beans.Beans.instantiate(Beans.java:63)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.loadFilter(WebAppFilterManager.java:292)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterInstanceWrapper(WebAppFilterManager.java:161)
at com.ibm.ws.webcontainer.filter.WebAppFilterManager.getFilterChain(WebAppFilterManager.java:208)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.handleWebAppDispatch(WebAppRequestDispatcher.java:1034)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.dispatch(WebAppRequestDispatcher.java:600)
at com.ibm.ws.webcontainer.webapp.WebAppRequestDispatcher.forward(WebAppRequestDispatcher.java:201)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.doForward(WebAppInvoker.java:125)
at com.ibm.ws.webcontainer.srt.WebAppInvoker.handleInvocationHook(WebAppInvoker.java:286)
at com.ibm.ws.webcontainer.cache.invocation.CachedInvocation.handleInvocation(CachedInvocation.java:71)
at com.ibm.ws.webcontainer.srp.ServletRequestProcessor.dispatchByURI(ServletRequestProcessor.java:182)
at com.ibm.ws.webcontainer.oselistener.OSEListenerDispatcher.service(OSEListener.java:334)
at com.ibm.ws.webcontainer.http.HttpConnection.handleRequest(HttpConnection.java:56)
at com.ibm.ws.http.HttpConnection.readAndHandleRequest(HttpConnection.java:624)
at com.ibm.ws.http.HttpConnection.run(HttpConnection.java:448)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:912)
---------------------------------------------------------------------------


Our Environment:
OS:Windows XP
WAS Version: 5.1.1.4
JDK Version : 1.4.2
WC Version : 5.6.1

It it matthers, we are using commons logging, the log gets instantiated in a static initializer in the filter class.

I tried everyting, not sure why it is not able to find the class(which is in the classpath). Am i missing something here?
Brian Lima
2006-11-21 16:35:59 UTC
Permalink
Post by v***@yahoo.com
We are on WC 5.6.1. Our Stores web app has a validation filter, the filter works fine everywhere, but on one development machine(in WCToolkit test environment), it fails with the below missing class error. The below missing class is in the classpath.
[11/20/06 22:19:12:675 PST] 55355535 WebGroup E SRVE0026E: [Servlet Error]-[Filter [ValidationFilter]: com.test.validation.ValidationFilter was found, but is missing another required class.
]: java.lang.NoClassDefFoundError: org.apache.commons.validator.ValidatorException
Where have you placed the commons-validator.jar file (I'm assuming
that's where the missing class is located)? Also are you trying to use
the full or light server because the location of the JAR file will differ.

More information can be found at:
http://publib.boulder.ibm.com/infocenter/wchelp/v5r6m1/index.jsp?topic=/com.ibm.commerce.developer.doc/tasks/tdeexternaljars.htm
Loading...