新的TomEE服务器无法运行Vaadin UI

时间:2015-03-03 18:40:06

标签: tomcat vaadin

我试图在新的TomEE服务器上运行我的Vaadin应用程序,但我无法让它运行起来。我只收到以下错误消息:

ALLVARLIG: A child container failed during start
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/serverside_imr]]
  at java.util.concurrent.FutureTask.report(Unknown Source)
  at java.util.concurrent.FutureTask.get(Unknown Source)
  at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1123)
  at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:816)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
  at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1575)
  at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1565)
  at java.util.concurrent.FutureTask.run(Unknown Source)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
  at java.lang.Thread.run(Unknown Source)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/serverside_imr]]
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
... 6 more
Caused by: java.lang.NoClassDefFoundError: com/vaadin/server/VaadinServlet
  at java.lang.ClassLoader.defineClass1(Native Method)
  at java.lang.ClassLoader.defineClass(Unknown Source)
  at java.security.SecureClassLoader.defineClass(Unknown Source)
  at java.net.URLClassLoader.defineClass(Unknown Source)
  at java.net.URLClassLoader.access$100(Unknown Source)
  at java.net.URLClassLoader$1.run(Unknown Source)
  at java.net.URLClassLoader$1.run(Unknown Source)
  at java.security.AccessController.doPrivileged(Native Method)
  at java.net.URLClassLoader.findClass(Unknown Source)
  at java.lang.ClassLoader.loadClass(Unknown Source)
  at java.lang.ClassLoader.loadClass(Unknown Source)
  at org.apache.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:205)
  at org.apache.openejb.core.TempClassLoader.loadClass(TempClassLoader.java:79)
  at org.apache.xbean.finder.archive.FileArchive.loadClass(FileArchive.java:88)
  at org.apache.xbean.finder.archive.CompositeArchive.loadClass(CompositeArchive.java:58)
  at org.apache.xbean.finder.archive.FilteredArchive.loadClass(FilteredArchive.java:45)
  at org.apache.xbean.finder.archive.CompositeArchive.loadClass(CompositeArchive.java:58)
  at org.apache.openejb.config.WebappAggregatedArchive.loadClass(WebappAggregatedArchive.java:80)
  at org.apache.xbean.finder.AnnotationFinder$ClassInfo.get(AnnotationFinder.java:1453)
  at org.apache.xbean.finder.AnnotationFinder.findMetaAnnotatedClasses(AnnotationFinder.java:563)
  at org.apache.xbean.finder.AnnotationFinder.findMetaAnnotatedClasses(AnnotationFinder.java:512)
  at org.apache.openejb.config.AnnotationDeployer$DiscoverAnnotatedBeans.deploy(AnnotationDeployer.java:1250)
  at org.apache.openejb.config.AnnotationDeployer$DiscoverAnnotatedBeans.deploy(AnnotationDeployer.java:469)
  at org.apache.openejb.config.AnnotationDeployer.deploy(AnnotationDeployer.java:356)
  at org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:401)
  at org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:962)
  at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1214)
  at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:1087)
  at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:130)
  at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:117)
  at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
  at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5378)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 6 more
Caused by: java.lang.ClassNotFoundException: com.vaadin.server.VaadinServlet
  at java.net.URLClassLoader$1.run(Unknown Source)
  at java.net.URLClassLoader$1.run(Unknown Source)
  at java.security.AccessController.doPrivileged(Native Method)
  at java.net.URLClassLoader.findClass(Unknown Source)
  at java.lang.ClassLoader.loadClass(Unknown Source)
  at java.lang.ClassLoader.loadClass(Unknown Source)
... 39 more

mar 03, 2015 8:10:20 EM org.apache.catalina.core.ContainerBase startInternal
ALLVARLIG: A child container failed during start
java.util.concurrent.ExecutionException: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]]
  at java.util.concurrent.FutureTask.report(Unknown Source)
  at java.util.concurrent.FutureTask.get(Unknown Source)
  at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1123)
  at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:300)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
  at org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
  at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:739)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
  at org.apache.catalina.startup.Catalina.start(Catalina.java:689)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  at java.lang.reflect.Method.invoke(Unknown Source)
  at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:321)
  at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:455)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost]]
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
  at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1575)
  at org.apache.catalina.core.ContainerBase$StartChild.call(ContainerBase.java:1565)
  at java.util.concurrent.FutureTask.run(Unknown Source)
  at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
  at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
  at java.lang.Thread.run(Unknown Source)
Caused by: org.apache.catalina.LifecycleException: A child container failed during start
  at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1131)
  at org.apache.catalina.core.StandardHost.startInternal(StandardHost.java:816)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 6 more

mar 03, 2015 8:10:20 EM org.apache.catalina.startup.Catalina start
ALLVARLIG: The required Server component failed to start so Tomc  at is unable to start.
org.apache.catalina.LifecycleException: Failed to start component [StandardServer[8005]]
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
  at org.apache.catalina.startup.Catalina.start(Catalina.java:689)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  at java.lang.reflect.Method.invoke(Unknown Source)
  at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:321)
  at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:455)
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardService[Catalina]]
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
  at org.apache.catalina.core.StandardServer.startInternal(StandardServer.java:739)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 7 more
Caused by: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina]]
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:154)
  at org.apache.catalina.core.StandardService.startInternal(StandardService.java:443)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 9 more
Caused by: org.apache.catalina.LifecycleException: A child container failed during start
  at org.apache.catalina.core.ContainerBase.startInternal(ContainerBase.java:1131)
  at org.apache.catalina.core.StandardEngine.startInternal(StandardEngine.java:300)
  at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
... 11 more

我注意到Eclipse无法找到" com.vaadin.server.VaadinServlet",这可能是用户界面无法运行的主要原因。如何在不必从头开始创建新项目的情况下解决这个问题?

1 个答案:

答案 0 :(得分:0)

首先确保你没有提到两次VaadinServlet的servlet映射。在由项目默认创建的默认Java文件中的web.xml文件(由您创建)和WebServet注释中。

从web.xml文件或默认Java文件(注释)中删除servlet映射。

希望这能解决问题。