为了账号安全,请及时绑定邮箱和手机立即绑定

自己书写实例过程中出现的问题,不知如何解决


信息: Choosing bean (struts) for (com.opensymphony.xwork2.security.AcceptedPatternsChecker)

2015-10-4 10:03:42 org.apache.struts2.dispatcher.Dispatcher error

严重: Dispatcher initialization failed

Unable to load configuration. - [unknown location]

at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:70)

at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967)

at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435)

at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479)

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.<init>(ApplicationFilterConfig.java:105)

at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4828)

at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5508)

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:649)

at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247)

at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898)

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: Parent package is not defined: struts-deafult - [unknown location]

at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.buildPackageContext(XmlConfigurationProvider.java:674)

at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:523)

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)

... 22 more

2015-10-4 10:03:42 org.apache.catalina.core.StandardContext filterStart

严重: Exception starting filter struts2

Unable to load configuration. - [unknown location]

at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:493)

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.<init>(ApplicationFilterConfig.java:105)

at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4828)

at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5508)

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:649)

at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247)

at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898)

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. - [unknown location]

at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:70)

at org.apache.struts2.dispatcher.Dispatcher.getContainer(Dispatcher.java:967)

at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:435)

at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:479)

... 19 more

Caused by: Parent package is not defined: struts-deafult - [unknown location]

at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.buildPackageContext(XmlConfigurationProvider.java:674)

at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.addPackage(XmlConfigurationProvider.java:523)

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)

... 22 more

2015-10-4 10:03:42 org.apache.catalina.core.StandardContext startInternal

严重: Error filterStart

2015-10-4 10:03:42 org.apache.catalina.core.StandardContext startInternal

严重: Context [/ch2.2] startup failed due to previous errors

2015-10-4 10:03:42 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deployment of web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\ch2.2 has finished in 3,285 ms

2015-10-4 10:03:42 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deploying web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\docs

2015-10-4 10:03:42 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deployment of web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\docs has finished in 277 ms

2015-10-4 10:03:42 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deploying web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\examples

2015-10-4 10:03:43 org.apache.catalina.core.ApplicationContext log

信息: ContextListener: contextInitialized()

2015-10-4 10:03:43 org.apache.catalina.core.ApplicationContext log

信息: SessionListener: contextInitialized()

2015-10-4 10:03:43 org.apache.catalina.core.ApplicationContext log

信息: ContextListener: attributeAdded('org.apache.jasper.compiler.TldLocationsCache', 'org.apache.jasper.compiler.TldLocationsCache@5e3d5149')

2015-10-4 10:03:43 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deployment of web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\examples has finished in 531 ms

2015-10-4 10:03:43 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deploying web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\foryou

2015-10-4 10:03:43 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deployment of web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\foryou has finished in 670 ms

2015-10-4 10:03:43 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deploying web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\HelloWorld

2015-10-4 10:03:45 org.apache.catalina.startup.TaglibUriRule body

信息: TLD skipped. URI: /struts-tags is already defined

2015-10-4 10:03:46 com.sun.faces.config.ConfigureListener contextInitialized

信息: Initializing Sun's JavaServer Faces implementation (1.2_04-b07-FCS) for context '/HelloWorld'

2015-10-4 10:03:46 com.sun.faces.spi.InjectionProviderFactory createInstance

信息: JSF1048: PostConstruct/PreDestroy annotations present.  ManagedBeans methods marked with these annotations will have said annotations processed.

2015-10-4 10:03:48 com.opensymphony.xwork2.util.logging.commons.CommonsLogger info

信息: Parsing configuration file [struts-default.xml]

2015-10-4 10:03:48 com.opensymphony.xwork2.util.logging.commons.CommonsLogger error

严重: Dispatcher initialization failed

Unable to load configuration. - bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.3.24.jar!/struts-default.xml:57:72

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)

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.<init>(ApplicationFilterConfig.java:105)

at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4828)

at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5508)

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:649)

at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247)

at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898)

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 bean: type: class:com.opensymphony.xwork2.ObjectFactory - bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.3.24.jar!/struts-default.xml:57:72

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 struts has already been loaded by bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.2.1.jar!/struts-default.xml:30:124 - bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.3.24.jar!/struts-default.xml:57:72

at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:216)

... 24 more

2015-10-4 10:03:48 org.apache.catalina.core.StandardContext filterStart

严重: Exception starting filter struts2

Unable to load configuration. - bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.3.24.jar!/struts-default.xml:57:72

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.<init>(ApplicationFilterConfig.java:105)

at org.apache.catalina.core.StandardContext.filterStart(StandardContext.java:4828)

at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5508)

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:649)

at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1247)

at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1898)

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:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.3.24.jar!/struts-default.xml:57:72

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: class:com.opensymphony.xwork2.ObjectFactory - bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.3.24.jar!/struts-default.xml:57:72

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 struts has already been loaded by bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.2.1.jar!/struts-default.xml:30:124 - bean - jar:file:/D:/freelooppowter/apache-tomcat-7.0.55-windows-x64/apache-tomcat-7.0.55/webapps/HelloWorld/WEB-INF/lib/struts2-core-2.3.24.jar!/struts-default.xml:57:72

at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.register(XmlConfigurationProvider.java:216)

... 24 more

2015-10-4 10:03:48 org.apache.catalina.core.StandardContext startInternal

严重: Error filterStart

2015-10-4 10:03:48 org.apache.catalina.core.StandardContext startInternal

严重: Context [/HelloWorld] startup failed due to previous errors

2015-10-4 10:03:48 org.apache.catalina.loader.WebappClassLoader checkThreadLocalMapForLeaks

严重: The web application [/HelloWorld] created a ThreadLocal with key of type [com.sun.faces.util.Util$1] (value [com.sun.faces.util.Util$1@26d6466f]) and a value of type [java.util.HashMap] (value [{com.sun.faces.patternCache={ = }}]) 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.

2015-10-4 10:03:48 org.apache.catalina.startup.HostConfig deployDirectory

信息: Deployment of web application directory D:\freelooppowter\apache-tomcat-7.0.55-windows-x64\apache-tomcat-7.0.55\webapps\HelloWorld has finished in 4,837 ms

2015-10-4 10:03:48 org.apache.catalina.startup.HostConfig deployDirectory

正在回答

3 回答

您好,我发现错误中 Parent package is not defined: struts-deafult,这个说明package包名没有定义,最好贴出配置文件检查一下。

0 回复 有任何疑惑可以回复我~
#1

freelooppowter 提问者

请问还有spring和hiberate框架的视频吗?
2015-10-18 回复 有任何疑惑可以回复我~

在官网下载的包里面有列子的,列子里的第一个叫blank里面,struts。xml文件和web。xml都可以直接拷贝过来,修改就行了,就不会有自己写的拼写错误了

0 回复 有任何疑惑可以回复我~

谢谢,我已经找到解决办法了!!

0 回复 有任何疑惑可以回复我~
#1

离锁忧

请问你是怎么解决的啊 我也遇到这样的问题了
2015-10-19 回复 有任何疑惑可以回复我~
#2

以雾洗梦 回复 离锁忧

她的单词拼错了,,,,struts-default
2015-10-23 回复 有任何疑惑可以回复我~

举报

0/150
提交
取消

自己书写实例过程中出现的问题,不知如何解决

我要回答 关注问题
意见反馈 帮助中心 APP下载
官方微信