Notifications
Clear all

Error during server tests within Studio regarding classloader

6 Posts
3 Users
0 Reactions
1,599 Views
0
Topic starter

HEllo gettin an interesting error today that popped up out of nowhere after successful test runs.

 

javax.servlet.ServletException: Error finding class [com.onenetwork.dodc.aar.DLMS945AARTest] using both the Context classloader and the webapp classloader. Possible causes include:
- Your webapp does not include your test classes,
- The cactus.jar is not located in your WEB-INF/lib directory and your Container has not set the Context classloader to point to the webapp one
at org.apache.cactus.internal.server.AbstractWebTestCaller.getTestClassClass(AbstractWebTestCaller.java:501)
at com.transcendsys.platform.web.servlet.PlatformServletTestCaller.getTestClassClass(PlatformServletTestCaller.java:38)
at org.apache.cactus.internal.server.AbstractWebTestCaller.getTestClassInstance(AbstractWebTestCaller.java:384)
at org.apache.cactus.internal.server.AbstractWebTestCaller.doTest(AbstractWebTestCaller.java:109)
at org.apache.cactus.internal.server.AbstractWebTestController.handleRequest_aroundBody0(AbstractWebTestController.java:93)
at org.apache.cactus.internal.server.AbstractWebTestController.handleRequest_aroundBody1$advice(AbstractWebTestController.java:224)
at org.apache.cactus.internal.server.AbstractWebTestController.handleRequest(AbstractWebTestController.java)
at com.transcendsys.platform.web.servlet.CactusServletTestDirector.runTest(CactusServletTestDirector.java:91)
at com.transcendsys.platform.web.servlet.CactusServletTestDirector.doPost(CactusServletTestDirector.java:52)
at org.apache.cactus.server.ServletTestRedirector.doGet_aroundBody0(ServletTestRedirector.java:72)
at org.apache.cactus.server.ServletTestRedirector.doGet_aroundBody1$advice(ServletTestRedirector.java:224)
at org.apache.cactus.server.ServletTestRedirector.doGet(ServletTestRedirector.java)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:634)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:741)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:231)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at com.transcendsys.platform.web.filter.NoLogFilter.doFilter(NoLogFilter.java:36)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at com.transcendsys.platform.web.filter.xss.XSSPreventionFilter.doFilter(XSSPreventionFilter.java:207)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.catalina.filters.HttpHeaderSecurityFilter.doFilter(HttpHeaderSecurityFilter.java:126)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at com.transcendsys.platform.web.filter.CacheHeaderFilter.doFilter(CacheHeaderFilter.java:49)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:176)
at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:145)
at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:92)
at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:394)
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:193)
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:166)
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:199)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:96)
at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:493)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:137)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:81)
at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:660)
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:87)
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:343)
at org.apache.coyote.http11.Http11Processor.service(Http11Processor.java:798)
at org.apache.coyote.AbstractProcessorLight.process(AbstractProcessorLight.java:66)
at org.apache.coyote.AbstractProtocol$ConnectionHandler.process(AbstractProtocol.java:808)
at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1498)
at org.apache.tomcat.util.net.SocketProcessorBase.run(SocketProcessorBase.java:49)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
at java.lang.Thread.run(Thread.java:745)
Caused by: java.lang.ClassNotFoundException: Class com.onenetwork.dodc.aar.DLMS945AARTest not found
at com.transcendsys.platform.web.servlet.CactusServletTestDirector$WrapperClassLoader.findClass(CactusServletTestDirector.java:119)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:348)
at org.apache.cactus.internal.util.ClassLoaderUtils.loadClassFromContextClassLoader_aroundBody2(ClassLoaderUtils.java:78)
at org.apache.cactus.internal.util.ClassLoaderUtils.loadClassFromContextClassLoader_aroundBody3$advice(ClassLoaderUtils.java:264)
at org.apache.cactus.internal.util.ClassLoaderUtils.loadClassFromContextClassLoader(ClassLoaderUtils.java)
at org.apache.cactus.internal.util.ClassLoaderUtils.loadClass_aroundBody0(ClassLoaderUtils.java:61)
at org.apache.cactus.internal.util.ClassLoaderUtils.loadClass_aroundBody1$advice(ClassLoaderUtils.java:264)
at org.apache.cactus.internal.util.ClassLoaderUtils.loadClass(ClassLoaderUtils.java)
at org.apache.cactus.internal.server.AbstractWebTestCaller.getTestClassClass(AbstractWebTestCaller.java:485)
... 50 more

 

 

I have tried clean building outside and inside of studio but to no avail.

3 Answers
0

Does the class file DLMS945AARTest.class exist?  Can you send a screenshot of it in situ?

0
Topic starter
image
Greg Merrill 2021-03-05 19:02:21

@rfutterman I'm rather looking for the copy inside tomcat/ somewhere, can you check that

rfutterman Topic starter 2021-03-05 19:05:21

@gmerrill I dont have a .class file under tomcat matching that name, this is on AAR though so we dont use Tomcat.

Greg Merrill 2021-03-05 19:58:50

@rfutterman
Ah OK, this goes all the way back to jboss. there must be a class file under jboss then, please check.

0

Is DLMS945AARTest.class a valid class file? Could you please submit a screenshot of it in action?