2 yu zongyao yu_zongyao 于 2014.05.03 12:49 提问

SSH配置,出现了unable to load /struts2-spring-plugin-2.2.1.jar

java myeclipse SSH配置,出现了unable to load /struts2-spring-plugin-2.2.1.jar!/struts-plugin.xml:。可是我在WEB-INF/lib里面有这个jar包。

log4j:WARN No appenders could be found for logger (com.opensymphony.xwork2.config.providers.XmlConfigurationProvider).
log4j:WARN Please initialize the log4j system properly.
2014-5-3 12:40:59 org.apache.catalina.core.StandardContext filterStart
严重: Exception starting filter struts2
Unable to load configuration. - bean - jar:file:/E:/Java%E5%AD%A6%E4%B9%A0%E8%BD%AF%E4%BB%B6/tomcat/apache-tomcat-7.0.52/webapps/TestHibernate/WEB-INF/lib/struts2-spring-plugin-2.2.1.jar!/struts-plugin.xml:29:132
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:428)
at org.apache.struts2.dispatcher.ng.InitOperations.initDispatcher(InitOperations.java:69)
at org.apache.struts2.dispatcher.ng.filter.StrutsPrepareAndExecuteFilter.init(StrutsPrepareAndExecuteFilter.java:51)
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:4809)
at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5485)
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:632)
at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1229)
at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1875)
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
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)
Caused by: Unable to load configuration. - bean - jar:file:/E:/Java%E5%AD%A6%E4%B9%A0%E8%BD%AF%E4%BB%B6/tomcat/apache-tomcat-7.0.52/webapps/TestHibernate/WEB-INF/lib/struts2-spring-plugin-2.2.1.jar!/struts-plugin.xml:29:132
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:69)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:371)
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:415)
... 19 more
Caused by: Unable to load bean: type:com.opensymphony.xwork2.ObjectFactory class:org.apache.struts2.spring.StrutsSpringObjectFactory - bean - jar:file:/E:/Java%E5%AD%A6%E4%B9%A0%E8%BD%AF%E4%BB%B6/tomcat/apache-tomcat-7.0.52/webapps/TestHibernate/WEB-INF/lib/struts2-spring-plugin-2.2.1.jar!/struts-plugin.xml:29:132
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:232)
at org.apache.struts2.config.StrutsXmlConfigurationProvider.register(StrutsXmlConfigurationProvider.java:101)
at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reloadContainer(DefaultConfiguration.java:180)
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:66)
... 21 more
Caused by: Bean type class com.opensymphony.xwork2.ObjectFactory with the name spring has already been loaded by bean - jar:file:/E:/Java%E5%AD%A6%E4%B9%A0%E8%BD%AF%E4%BB%B6/tomcat/apache-tomcat-7.0.52/webapps/TestHibernate/WEB-INF/lib/struts2-spring-plugin-2.0.11.2.jar!/struts-plugin.xml:30:132 - bean - jar:file:/E:/Java%E5%AD%A6%E4%B9%A0%E8%BD%AF%E4%BB%B6/tomcat/apache-tomcat-7.0.52/webapps/TestHibernate/WEB-INF/lib/struts2-spring-plugin-2.2.1.jar!/struts-plugin.xml:29:132
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:216)
... 24 more
2014-5-3 12:40:59 org.apache.catalina.core.StandardContext startInternal
严重: Error filterStart
2014-5-3 12:40:59 org.apache.catalina.core.StandardContext startInternal
严重: Context [/TestHibernate] startup failed due to previous errors
2014-5-3 12:40:59 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks
严重: The web application [/TestHibernate] created a ThreadLocal with key of type com.sun.faces.util.Util$1 and a value of type java.util.HashMap but failed to remove it when the web application was stopped. Threads are going to be renewed over time to try and avoid a probable memory leak.
2014-5-3 12:40:59 org.apache.catalina.startup.HostConfig deployDirectory

2个回答

yf924092
yf924092   2014.05.31 02:50

换个服务器试试了,别用myeclipse自带的

ThePromonkeyOf_HeLuo
ThePromonkeyOf_HeLuo   2016.06.07 14:44

不用myeclipse自带的,自己集成的Tomcat也不行。

Csdn user default icon
上传中...
上传图片
插入图片