在金蝶Apusic 5.1下部署门户和oa系统,发现同时部署始终有一个会出现500错误,无法访问,而另外一个则正常。个深层错误原因如下:
2009-06-13 10:38:33 警告 [apusic.web.qjoa./qjoa] 无法转载过滤器 'Struts2'。
javax.servlet.ServletException: Caught exception while loading file struts-default.xml - [unknown location]
at com.apusic.web.container.WebComponent.create(Unknown Source)
at com.apusic.web.container.WebComponent.getComponent(Unknown Source)
at com.apusic.web.container.WebComponent.init(Unknown Source)
at com.apusic.web.container.WebContainer.loadFilter(Unknown Source)
at com.apusic.web.container.WebContainer.loadFilters(Unknown Source)
at com.apusic.web.container.WebContainer.start(Unknown Source)
at com.apusic.web.http.VirtualHost.addContext(Unknown Source)
at com.apusic.web.http.HttpServer.loadWebModule(Unknown Source)
at com.apusic.web.WebService.loadWebModule(Unknown Source)
at com.apusic.deploy.runtime.WebModule.load(Unknown Source)
at com.apusic.deploy.runtime.J2EEApplication.loadModules(Unknown Source)
at com.apusic.deploy.runtime.J2EEApplication.startApplication(Unknown Source)
at com.apusic.deploy.runtime.J2EEApplication.startService(Unknown Source)
at com.apusic.service.Service.start(Unknown Source)
at com.apusic.deploy.runtime.J2EEDeployer.startUserApplications(Unknown Source)
at com.apusic.deploy.runtime.J2EEDeployer.startService(Unknown Source)
at com.apusic.service.Service.start(Unknown Source)
at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at com.apusic.jmx.MBeanDescriptor.invoke(Unknown Source)
at com.apusic.jmx.DynamicMBeanSupport.invoke(Unknown Source)
at com.sun.jmx.interceptor.DefaultMBeanServerInterceptor.invoke(DefaultMBeanServerInterceptor.java:836)
at com.sun.jmx.mbeanserver.JmxMBeanServer.invoke(JmxMBeanServer.java:761)
at com.apusic.server.J2EEServer.start(Unknown Source)
at com.apusic.server.J2EEServer.startup(Unknown Source)
at com.apusic.server.Main.main(Unknown Source)
Caused by: Caught exception while loading file struts-default.xml - [unknown location]
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadConfigurationFiles(XmlConfigurationProvider.java:839)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadDocuments(XmlConfigurationProvider.java:131)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.init(XmlConfigurationProvider.java:100)
at com.opensymphony.xwork2.config.impl.DefaultConfiguration.reload(DefaultConfiguration.java:130)
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:52)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:395)
at org.apache.struts2.dispatcher.Dispatcher.init(Dispatcher.java:452)
at org.apache.struts2.dispatcher.FilterDispatcher.init(FilterDispatcher.java:201)
at com.apusic.web.container.FilterComponent.initializeComponent(Unknown Source)
at com.apusic.web.container.FilterComponent.initializeComponent(Unknown Source)
... 27 more
Caused by: java.lang.ClassCastException: org.apache.xerces.parsers.XML11Configuration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.DOMParser.<init>(Unknown Source)
at org.apache.xerces.parsers.DOMParser.<init>(Unknown Source)
at org.apache.xerces.jaxp.DocumentBuilderImpl.<init>(Unknown Source)
at org.apache.xerces.jaxp.DocumentBuilderFactoryImpl.newDocumentBuilder(Unknown Source)
at com.sun.org.apache.xalan.internal.xsltc.trax.SAX2DOM.<init>(SAX2DOM.java:69)
at com.sun.org.apache.xalan.internal.xsltc.runtime.output.TransletOutputHandlerFactory.getSerializationHandler(TransletOutputHandlerFactory.java:187)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerImpl.getOutputHandler(TransformerImpl.java:392)
at com.sun.org.apache.xalan.internal.xsltc.trax.TransformerHandlerImpl.setResult(TransformerHandlerImpl.java:137)
at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.setup(DomHelper.java:213)
at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.<init>(DomHelper.java:198)
at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.<init>(DomHelper.java:189)
at com.opensymphony.xwork2.util.DomHelper$DOMBuilder.<init>(DomHelper.java:175)
at com.opensymphony.xwork2.util.DomHelper.parse(DomHelper.java:115)
at com.opensymphony.xwork2.config.providers.XmlConfigurationProvider.loadConfigurationFiles(XmlConfigurationProvider.java:830)
... 36 more
2009-06-13 10:38:33 信息 [apusic.web.qjoa./qjoa] Context Root [/qjoa]
初一看,还让人以为是无法加载stuts2的默认配置文件struts-default.xml的问题。但是单独均部署成功的测试让我打消了这方面的疑虑。看来应该是个conflict了。
问题的真正原因在这里:
Caused by: java.lang.ClassCastException: org.apache.xerces.parsers.XML11Configuration cannot be cast to org.apache.xerces.xni.parser.XMLParserConfiguration
at org.apache.xerces.parsers.DOMParser
正是由于这里的冲突,导致无法加载解析struts2的xml文件。最终定为在xerces.jar 冲突的原因。查看了两个project,确实均有xerces.jar 包,任意删除一个项目中的一个,只要两个project不同时存在xerces.jar ,发布成功。
联想到不久前在tomcat下同时部署碰到的同样问题。原因肯定也在这里了。只是当时并没有深究。
参考自国外的同样问题讨论,详见:
http://www.nabble.com/org.apache.xerces.parsers.XML11Configuration-cannot-be-cast-to-org.apache.xerces.xni.parser.XMLParserConfiguration-td14108368.html
分享到:
相关推荐
金蝶 Apusic 应用服务器为复杂应用提供了一个简便、快速的开发和运行平台,对于分 布式的企业级应用,提供了易扩展、可伸缩和高安全性等特性。下面将介绍 Apusic 应用服 务器的体系结构及其提供的服务和功能,从而...
linux环境下使用apache和apusic实现负载均衡
金蝶Apusic应用服务器的详细文档,包括安装、管理、开发等内容。
Windows2003+Apusic6.0安装部署手册
金蝶Apusic应用服务器6.0是一款标准、安全、高效、集成并且具有丰富功能的企业级应用服务器(Enterprise Application Server),它用于实现基于SOA的企业应用和服务,为企业应用和服务提供坚不可摧的基础架构支撑。...
使用Jprofiler监控Apusic应用服务器
金蝶Apusic应用服务器 V10企业版 用户手册+技术白皮书+调优手册 AASV10
全面介绍Apusic 应用服务器6.0 体系结构、新特性等
金蝶Apusic企业服务总线V7.0用户手册
金蝶Apusic应用服务器V6产品简介特性版.pptx
管理Apusic Web服务器,管理Apusic Web服务器
金蝶容器Apusic中重新部署war包
2021年通用apusic license,适用于apusic9.0以上EAS(EAS8.0以上版本一般都可用),有效期到2021年12月31日。此apusic为5个连接数
金蝶中间件(Apusic)--license
Apusic密码修改指引
金蝶Apusic应用服务器V6参考b手册b.doc
NULL 博文链接:https://yizhenn.iteye.com/blog/2091020
Apusic 7.0,2014,license,
Apusic5.1域配置,希望对正在使用Apusic5.1服务器的工作团队有所帮助。
金蝶中间件Apusic Eclipse/MyEclipse all-plugins,用于集成在eclipse做调试开发