Tomcat无法访问Spring3 WAR文件中的JAR

时间:2011-03-09 14:49:35

标签: spring tomcat6 spring-ws

我正在使用运行tc server v6的Spring 3.0,Spring-WS,SpringSource工具套件开发SOAP Web服务。当我在服务器上运行应用程序时,我在SpringSource工具套件中得到以下异常。

type Exception report message description The server encountered an internal error () that prevented it from fulfilling this request. exception javax.servlet.ServletException: 
        Wrapper cannot find servlet class org.springframework.ws.transport.http.MessageDispatcherServlet or a class it depends on 
    at com.springsource.insight.collection.tcserver.request.HttpRequestOperationCollectionValve.invoke(HttpRequestOperationCollectionValve.java:60)      
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)      
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:293)      
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:849)      
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)     
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:379)      
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)      
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)      
    at java.lang.Thread.run(Thread.java:619)"

org.springframework.ws.transport.http.MessageDispatcherServlet类包含在我的类路径中的spring-ws-core-2.0.0.RELEASE.jar中。我已经验证.JAR包含在WAR文件中但仍然得到上述异常。

在Tomcat的独立安装和随STS一起分发的嵌入式TC Lite服务器中都会发生此错误。

1 个答案:

答案 0 :(得分:1)

你可能错过了其他一些依赖的jar。

Wrapper cannot find servlet class org.springframework.ws.transport.http.MessageDispatcherServlet or a "class it depends on"

依赖于,检查ws-core的pom依赖项。尝试修改ws-core的pom范围以进行编译(如果是的话,从提供的那个开始)