Hi,
What is the right way to tell MyEclipse to not include specific jar files in the WEB-INF of the web application during deployment?
I am getting a deployment error for a Struts 2 application in Tomcat 5.5. I am using Java 1.6.0_26 and MyEclipse 9. Please see stack track extracts at the end of this message.
This problem seems to come because of the conflicts between different Xerces versions. The solution is to not include the xerces and xml-api jars in the application’s WEB-INF. This works fine when I deploy in Tomcat externally.
However, when I deploy to Tomcat through MyEclipse by using the “Manage Deployments” functionality, MyEclipse includes the Xerces and other jar files in the WEB-INF of the web application, causing the conflict.
So I need a mechanism to tell MyEclipse to not include these specific jars in the WEB-INF of the web application. How can I do that?
Note that these specific jars are included as “External Jars” in the build path (“Libraries” tab). They are deselected in the “Order and Export” tab.
Thanks in advance.
Unmesh
Stack trace:
SEVERE: Dispatcher initialization failed
Unable to load configuration. – [unknown location]
at com.opensymphony.xwork2.config.ConfigurationManager.getConfiguration(ConfigurationManager.java:58)
at org.apache.struts2.dispatcher.Dispatcher.init_PreloadConfiguration(Dispatcher.java:374)
This can be traced to the following exception:
… 17 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)