当前位置: 代码迷 >> J2SE >> java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener
  详细解决方案

java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener

热度:371   发布时间:2016-04-24 18:07:00.0
急!!tomcat启动报错:Error configuring application listener of class org.springframework.web.context.ContextLoaderListener
严重:   Error   configuring   application   listener   of   class   org.springframework.web.context.ContextLoaderListener
java.lang.ClassNotFoundException:   org.springframework.web.context.ContextLoaderListener
at   org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1352)
at   org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1198)
at   org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:3677)
at   org.apache.catalina.core.StandardContext.start(StandardContext.java:4187)
at   org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:759)
at   org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:739)
at   org.apache.catalina.core.StandardHost.addChild(StandardHost.java:524)
at   org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:809)
at   org.apache.catalina.startup.HostConfig.deployWARs(HostConfig.java:698)
at   org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:472)
at   org.apache.catalina.startup.HostConfig.start(HostConfig.java:1122)
at   org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:310)
at   org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at   org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1021)
at   org.apache.catalina.core.StandardHost.start(StandardHost.java:718)
at   org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1013)
at   org.apache.catalina.core.StandardEngine.start(StandardEngine.java:442)
at   org.apache.catalina.core.StandardService.start(StandardService.java:450)
at   org.apache.catalina.core.StandardServer.start(StandardServer.java:709)
at   org.apache.catalina.startup.Catalina.start(Catalina.java:551)
at   sun.reflect.NativeMethodAccessorImpl.invoke0(Native   Method)
at   sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at   sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at   java.lang.reflect.Method.invoke(Method.java:585)
at   org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:294)
at   org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:432)

------解决方案--------------------
错误说明很清楚呀
------解决方案--------------------
java.lang.ClassNotFoundException: org.springframework.web.context.ContextLoaderListener

//检查spring相关的jar在不在tomcat的发布工程的lib下
------解决方案--------------------
遇到相同问题,LZ是否已解决?
------解决方案--------------------
treeroot(旗鲁特) ( )
光说明很清楚到底错误是啥你倒是说出来啊。小心装B遭雷劈
------解决方案--------------------
xml设置里面用到的bean不对,可能名字写错了。
------解决方案--------------------
web.xml 文件的
<listener>
标签必须在
<servlet>
之前

<listener>
 <listener-class>
org.springframework.web.context.ContextLoaderListener
</listener-class>
</listener>
<servlet>
<description>
</description>
<display-name>
TimeServlet</display-name>
<servlet-name>TimeServlet</servlet-name>
<servlet-class>
  相关解决方案