tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Elbek Kamoliddinov <elbek.kamoliddi...@oracle.com>
Subject java.lang.ClassNotFoundException exception, while class is in WEB-INF/classes folder
Date Thu, 15 Dec 2016 16:53:54 GMT
Hi everyone, I am trying to deploy simple war file to apache-tomee-webprofile-7.0.2 and getting
classnotfound error, while class is in WEB-INF/classes folder

Just FYI, this gets deployed perfectly fine onto weblogic server

 

Here is the log I get during startup:

 

15-Dec-2016 11:47:25.071 SEVERE [localhost-startStop-1] org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal
Unable to deploy collapsed ear in war StandardEngine[Catalina].StandardHost[localhost].StandardContext[/CallCenter]

org.apache.openejb.OpenEJBException: Unable to load servlet class: com.oracle.oroms.servlet.MainServlet:
com.oracle.oroms.servlet.MainServlet

        at org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:2303)

        at org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:2022)

        at org.apache.openejb.config.AnnotationDeployer.deploy(AnnotationDeployer.java:383)

        at org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:420)

        at org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:1037)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1276)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1124)

        at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:133)

        at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)

        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)

        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)

        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:724)

        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700)

        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)

        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:952)

        at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1823)

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

        at java.util.concurrent.FutureTask.run(FutureTask.java:266)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

        at java.lang.Thread.run(Thread.java:745)

Caused by: java.lang.ClassNotFoundException: com.oracle.oroms.servlet.MainServlet

        at java.net.URLClassLoader.findClass(URLClassLoader.java:381)

        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.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:152)

        at org.apache.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:83)

        at org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:2296)

        ... 20 more

 

15-Dec-2016 11:47:25.072 SEVERE [localhost-startStop-1] sun.reflect.NativeMethodAccessorImpl.invoke
ContainerBase.removeChild: destroy:

org.apache.catalina.LifecycleException: An invalid Lifecycle transition was attempted ([before_destroy])
for component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/CallCenter]]
in state [STARTING_PREP]

        at org.apache.catalina.util.LifecycleBase.invalidTransition(LifecycleBase.java:402)

        at org.apache.catalina.util.LifecycleBase.destroy(LifecycleBase.java:292)

        at org.apache.catalina.core.ContainerBase.removeChild(ContainerBase.java:826)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.undeploy(TomcatWebAppBuilder.java:1627)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.undeploy(TomcatWebAppBuilder.java:1607)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1307)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1124)

        at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:133)

        at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)

        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)

        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)

        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:724)

        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700)

        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)

        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:952)

        at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1823)

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

        at java.util.concurrent.FutureTask.run(FutureTask.java:266)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

        at java.lang.Thread.run(Thread.java:745)

 

15-Dec-2016 11:47:25.073 SEVERE [localhost-startStop-1] sun.reflect.NativeMethodAccessorImpl.invoke
ContainerBase.addChild: start:

org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/CallCenter]]

        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:167)

        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:724)

        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700)

        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)

        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:952)

        at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1823)

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

        at java.util.concurrent.FutureTask.run(FutureTask.java:266)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

        at java.lang.Thread.run(Thread.java:745)

Caused by: org.apache.tomee.catalina.TomEERuntimeException: org.apache.openejb.OpenEJBException:
Unable to load servlet class: com.oracle.oroms.servlet.MainServlet: com.oracle.oroms.servlet.MainServlet

        at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1310)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1124)

        at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:133)

        at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:94)

        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5087)

        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)

        ... 10 more

Caused by: org.apache.openejb.OpenEJBException: Unable to load servlet class: com.oracle.oroms.servlet.MainServlet:
com.oracle.oroms.servlet.MainServlet

        at org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:2303)

        at org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:2022)

        at org.apache.openejb.config.AnnotationDeployer.deploy(AnnotationDeployer.java:383)

        at org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:420)

        at org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:1037)

        at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1276)

        ... 15 more

Caused by: java.lang.ClassNotFoundException: com.oracle.oroms.servlet.MainServlet

        at java.net.URLClassLoader.findClass(URLClassLoader.java:381)

        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.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:152)

        at org.apache.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:83)

        at org.apache.openejb.config.AnnotationDeployer$ProcessAnnotatedBeans.deploy(AnnotationDeployer.java:2296)

        ... 20 more

 

15-Dec-2016 11:47:25.074 SEVERE [localhost-startStop-1] sun.reflect.NativeMethodAccessorImpl.invoke
Error deploying web application archive C:\work\apache-tomee-webprofile-7.0.2\webapps\CallCenter.war

java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException:
Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/CallCenter]]

        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:728)

        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:700)

        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:734)

        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:952)

        at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1823)

        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)

        at java.util.concurrent.FutureTask.run(FutureTask.java:266)

        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)

        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)

        at java.lang.Thread.run(Thread.java:745)

 

 

Here is the class in war file from 7zip:

 



 

I have attached the web.xml file. 

 

Any idea why tomee is not seeing the class? 

-- 

Thanks. 

Mime
  • Unnamed multipart/mixed (inline, None, 0 bytes)
View raw message