日期:2014-05-17  浏览次数:20962 次

Exception starting filter struts2 java.lang.ClassNotFoundException: org.apache.
org.apache.catalina.core.StandardContext filterStart
严重: Exception starting filter struts2
java.lang.ClassNotFoundException: org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter
	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1678)
	at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1523)
	at org.apache.catalina.core.DefaultInstanceManager.loadClass(DefaultInstanceManager.java:415)
	at org.apache.catalina.core.DefaultInstanceManager.loadClassMaybePrivileged(DefaultInstanceManager.java:397)
	at org.apache.catalina.core.DefaultInstanceManager.newInstance(DefaultInstanceManager.java:118)
	at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:252)
	at org.apache.catalina.core.ApplicationFilterConfig.setFilterDef(ApplicationFilterConfig.java:372)
	at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:98)
	at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4584)
	at org.apache.catalina.core.StandardContext$2.call(StandardContext.java:5262)
	at org.apache.catalina.core.StandardContext$2.call(StandardContext.java:5257)
	at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
	at java.util.concurrent.FutureTask.run(FutureTask.java:138)
	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)
2012-5-29 14:13:56 org.apache.catalina.core.StandardContext startInternal



这个是用tomcat部署 就会出现这个错误 是用myeclipse部署 不会出现



解决方案:


1、是用myeclipse部署。。。

2、将struts包导入到lib下面,就没问题了

我的异常网推荐解决方案:org.apache.catalina.loader.WebappClassLoader.loadClass,http://www.aiyiweb.com/java-web/org.apache.catalina.loader.WebappClassLoader.loadClass.html