严重: Exception starting filter struts2 怎么解决? 5C

启动Struts2项目时,报的这个错误。不过效果能够正常显示。可是,控制台为什么报了这个错误呢??不明白,看了好几个博主的解决方法也都不行,所以,有没有经历过这个问题的大神们,求解~

严重: Exception starting filter struts2
Unable to load configuration. - action - file:/C:/Development/Tomcat-7.0/apache-tomcat-7.0.65/webapps/test-struts2-login/WEB-INF/classes/struts.xml:14:71
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:504)
at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:74)
at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:57)
at org.apache.catalina.core.ApplicationFilterConfig.initFilter(ApplicationFilterConfig.java:279)
at org.apache.catalina.core.ApplicationFilterConfig.getFilter(ApplicationFilterConfig.java:260)
at org.apache.catalina.core.ApplicationFilterConfig.(ApplicationFilterConfig.java:105)
at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4841)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5535)
at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:652)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1263)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1978)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
at java.util.concurrent.FutureTask.run(FutureTask.java:262)
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
at java.lang.Thread.run(Thread.java:745)
Caused by: Unable to load configuration. - action - file:/C:/Development/Tomcat-7.0/apache-tomcat-7.0.65/webapps/test-struts2-login/WEB-INF/classes/struts.xml:14:71
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:70)
at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:978)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:446)
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:490)
... 18 more
Caused by: Action class [com.aaa.action.ShowAction] not found - action - file:/C:/Development/Tomcat-7.0/apache-tomcat-7.0.65/webapps/test-struts2-login/WEB-INF/classes/struts.xml:14:71
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.verifyAction(XmlConfigurationProvider.java:486)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addAction(XmlConfigurationProvider.java:429)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:556)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadPackages(XmlConfigurationProvider.java:295)
at org.apache.struts2.config.StrutsXmlConfigurationProvider.loadPackages(StrutsXmlConfigurationProvider.java:112)
at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:264)
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:67)
... 21 more

5个回答

struts2的配置文件加载失败!/struts.xml,问题应该在这里边

首先你得找到报错位置,然后你看它的报错类型是报的是filter说明是你的strus拦截器的配置出了问题

struts2的配置文件加载失败!/struts.xml,说明是你的strus拦截器的配置出了问题

首先你得找到报错位置,然后你看它的报错类型是报的是filter说明是你的strus拦截器的配置出了问题

struts.xml,应该有问题,看看有没有报错的地方

qq_40087415
KK·Liu先生 启动Tomcat时MyEclipse控制台出现的这个错误,但是前台功能正常。
大约 2 年之前 回复
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问