一个菜鸟正在用SSH写一个论坛(2)

额 一不小心又一个多月没有写过随笔了。

这次是在某次启动服务器的时候报错了:

 1 严重: Exception starting filter struts2
 2 Unable to load configuration. - action - file:/D:/JAVAEE/apache-tomcat-7.0.57/webapps/bbs/WEB-INF/classes/struts.xml:15:72
 3     at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:428)
 4     at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:69)
 5     at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:51)
 6     at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
 7     at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
 8     at org.apache.catalina.core.ApplicationFilterConfig.<init>(ApplicationFilterConfig.java:105)
 9     at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4830)
10     at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5510)
11     at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
12     at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
13     at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
14     at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:649)
15     at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1245)
16     at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1895)
17     at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
18     at java.util.concurrent.FutureTask.run(FutureTask.java:262)
19     at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
20     at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
21     at java.lang.Thread.run(Thread.java:744)
22 Caused by: Unable to load configuration. - action - file:/D:/JAVAEE/apache-tomcat-7.0.57/webapps/bbs/WEB-INF/classes/struts.xml:15:72
23     at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:69)
24     at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:371)
25     at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:415)
26     ... 18 more
27 Caused by: Action class [UserAction] not found - action - file:/D:/JAVAEE/apache-tomcat-7.0.57/webapps/bbs/WEB-INF/classes/struts.xml:15:72
28     at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.verifyAction(XmlConfigurationProvider.java:420)
29     at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addAction(XmlConfigurationProvider.java:365)
30     at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:479)
31     at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadPackages(XmlConfigurationProvider.java:275)
32     at org.apache.struts2.config.StrutsXmlConfigurationProvider.loadPackages(StrutsXmlConfigurationProvider.java:111)
33     at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:204)
34     at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:66)
35     ... 20 more

但是我并没有动过配置文件的这个部分啊,怎么会报错呢。

检查了之后发现配置文件配置无误,那就只能是缺少什么jar了。

确实在之前把手动整合的框架换成了用MyEclipse添加三种框架,然后用反向工程生成了entity和dao,少写了好多代码。

但是为了在jsp中使用struts的标签,我就把MyEclipse引用的jar删除了自己考了jar到lib里。

果然是少考了一个struts2-spring-plugin-2.3.20。

好吧缺jar还会这样报错。

posted @ 2015-10-23 23:18  -.-|  阅读(207)  评论(0编辑  收藏  举报