2

在过去的几天里,我一直坚持将标准 WAR 部署到 Virgo-tomcat 服务器(版本 3.0.2)。从 eclipse 导出的标准 WAR 文件在 tomcat 上工作得很好,但在部署到 Virgo-tomcat 时就不行了。我已经阅读了用户指南和程序员指南,据我所知 - 这应该是将 WAR 部署到 VIRGO_HOME/pickup 目录(或者使用应用程序管理器)的情况。我已经尝试了这两种方法,但没有任何效果。

以下是日志的结果。

[2012-06-22 12:00:43.545] ERROR start-signalling-1           o.a.c.c.C.[Catalina].[localhost].[/spring-social-statusnet-tssg]  Error configuring application listener of class org.springframework.web.context.ContextLoaderListener java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
at org.eclipse.gemini.web.tomcat.internal.loading.BundleWebappClassLoader.loadClass(BundleWebappClassLoader.java:306)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
at org.apache.catalina.core.DefaultInstanceManager.loadClass(DefaultInstanceManager.java:525)
at org.apache.catalina.core.DefaultInstanceManager.loadClassMaybePrivileged(DefaultInstanceManager.java:507)
at org.apache.catalina.core.DefaultInstanceManager.newInstance(DefaultInstanceManager.java:124)
at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4715)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5273)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615)
at org.eclipse.gemini.web.tomcat.internal.TomcatServletContainer.startWebApplication(TomcatServletContainer.java:122)
at org.eclipse.gemini.web.internal.StandardWebApplication.start(StandardWebApplication.java:91)
at org.eclipse.virgo.web.core.internal.WebBundleLifecycleListener.onStarted(WebBundleLifecycleListener.java:122)
at org.eclipse.virgo.kernel.install.artifact.internal.StandardArtifactStateMonitor.onStarted(StandardArtifactStateMonitor.java:247)
at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.asyncStartSucceeded(AbstractInstallArtifact.java:294)
at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.access$0(AbstractInstallArtifact.java:291)
at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact$StateMonitorSignal.signalSuccessfulCompletion(AbstractInstallArtifact.java:229)
at org.eclipse.virgo.kernel.core.internal.BundleStartTracker$1.run(BundleStartTracker.java:143)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
at java.lang.Thread.run(Thread.java:722)

[2012-06-22 12:00:43.546] ERROR start-signalling-1           o.a.c.c.C.[Catalina].[localhost].[/spring-social-statusnet-tssg]  Skipped installing application listeners due to previous error(s) 

[2012-06-22 12:00:43.547] ERROR start-signalling-1           org.apache.catalina.core.StandardContext                          Error listenerStart 
[2012-06-22 12:00:43.547] ERROR start-signalling-1           org.apache.catalina.core.StandardContext                          Context [/spring-social-statusnet-tssg] startup failed due to previous errors 
[2012-06-22 12:00:43.702] ERROR start-signalling-1           org.eclipse.gemini.web.internal.StandardWebApplication            Failed to start web application at bundleContext path '/spring-social-statusnet-tssg' org.eclipse.gemini.web.core.spi.ServletContainerException: Web application at '/spring-social-statusnet-tssg' failed to start. Check the logs for more details.
    at org.eclipse.gemini.web.tomcat.internal.TomcatServletContainer.startWebApplication(TomcatServletContainer.java:125)
    at org.eclipse.gemini.web.internal.StandardWebApplication.start(StandardWebApplication.java:91)
    at org.eclipse.virgo.web.core.internal.WebBundleLifecycleListener.onStarted(WebBundleLifecycleListener.java:122)
    at org.eclipse.virgo.kernel.install.artifact.internal.StandardArtifactStateMonitor.onStarted(StandardArtifactStateMonitor.java:247)
    at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.asyncStartSucceeded(AbstractInstallArtifact.java:294)
    at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.access$0(AbstractInstallArtifact.java:291)
    at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact$StateMonitorSignal.signalSuccessfulCompletion(AbstractInstallArtifact.java:229)
    at org.eclipse.virgo.kernel.core.internal.BundleStartTracker$1.run(BundleStartTracker.java:143)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)

[2012-06-22 12:00:43.708] ERROR start-signalling-1           org.eclipse.virgo.medic.eventlog.default                         WE0005E Failed to start web bundle 'spring-social-statusnet-tssg' version '0.0.0': consult serviceability/logs/log.log for further details. 
[2012-06-22 12:00:43.709] INFO  start-signalling-1           o.e.v.k.i.artifact.internal.bundle.BundleThreadContextManager     Thread context class loader 'KernelBundleClassLoader: [bundle=spring-social-statusnet-tssg_0.0.0]' popped and set to 'BundleDelegatingClassLoader for [spring-osgi-extender (org.springframework.osgi.extender)]' 
[2012-06-22 12:00:43.709] INFO  start-signalling-1           o.e.v.k.i.artifact.internal.bundle.BundleThreadContextManager     Thread context class loader 'BundleDelegatingClassLoader for [spring-osgi-extender (org.springframework.osgi.extender)]' pushed and set to 'KernelBundleClassLoader: [bundle=spring-social-statusnet-tssg_0.0.0]' 
[2012-06-22 12:00:43.709] INFO  start-signalling-1           o.e.v.k.i.a.internal.AtomicInstallArtifactLifecycleListener       No atomic parent of bundle 'spring-social-statusnet-tssg' version '0.0.0' in scope 'null' to propagate start failed (stop) event to 
[2012-06-22 12:00:43.715] ERROR start-signalling-1           org.eclipse.virgo.medic.eventlog.default                         DE0006E Start failed for bundle 'spring-social-statusnet-tssg' version '0.0.0'. org.eclipse.virgo.kernel.deployer.core.DeploymentException: Web application failed to start
    at org.eclipse.virgo.web.core.internal.WebBundleLifecycleListener.onStarted(WebBundleLifecycleListener.java:132)
    at org.eclipse.virgo.kernel.install.artifact.internal.StandardArtifactStateMonitor.onStarted(StandardArtifactStateMonitor.java:247)
    at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.asyncStartSucceeded(AbstractInstallArtifact.java:294)
    at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact.access$0(AbstractInstallArtifact.java:291)
    at org.eclipse.virgo.kernel.install.artifact.internal.AbstractInstallArtifact$StateMonitorSignal.signalSuccessfulCompletion(AbstractInstallArtifact.java:229)
    at org.eclipse.virgo.kernel.core.internal.BundleStartTracker$1.run(BundleStartTracker.java:143)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1110)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:603)
    at java.lang.Thread.run(Thread.java:722)
Caused by: org.eclipse.gemini.web.core.WebApplicationStartFailedException: org.eclipse.gemini.web.core.spi.ServletContainerException: Web application at '/spring-social-statusnet-tssg' failed to start. Check the logs for more details.
    at org.eclipse.gemini.web.internal.StandardWebApplication.start(StandardWebApplication.java:108)
    at org.eclipse.virgo.web.core.internal.WebBundleLifecycleListener.onStarted(WebBundleLifecycleListener.java:122)
    ... 8 common frames omitted
Caused by: org.eclipse.gemini.web.core.spi.ServletContainerException: Web application at '/spring-social-statusnet-tssg' failed to start. Check the logs for more details.
    at org.eclipse.gemini.web.tomcat.internal.TomcatServletContainer.startWebApplication(TomcatServletContainer.java:125)
    at org.eclipse.gemini.web.internal.StandardWebApplication.start(StandardWebApplication.java:91)
    ... 9 common frames omitted
4

1 回答 1

2

好的,所以在测试了几个测试应用程序之后,我设法让一些示例 WAR 无需任何修改即可在 Virgo 上运行。

为了解决手头的问题,我将以下行添加到我的 Web 应用程序的 MANIFEST.MF 文件中。

Import-Package: org.springframework.web.context
于 2012-06-25T10:48:08.747 回答