File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Tomcat and the fly likes Axis with JAXP 1.3 Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Products » Tomcat
Bookmark "Axis with JAXP 1.3" Watch "Axis with JAXP 1.3" New topic

Axis with JAXP 1.3

Joe Busch

Joined: Jan 07, 2005
Posts: 12
I need to use JAXP 1.3 for my web service under Axis on Tomcat. The problem is that JAXP 1.2 is the default, and when I add the external jars for JAXP 1.3 support to lib/endorsed Axis, which uses 1.2 throws the following fault:

***Axis Error: AxisFault
faultCode: {}Server.userException
faultString: java.lang.IllegalArgumentException:

There must be some way to allow the web service to use JAXP 1.3 while Axis uses JAXP 1.2. Got a solution for me?

Joe Busch

Joined: Jan 07, 2005
Posts: 12
I have found the solution, and am replying to my own topic here in case someone else is interested. The Tomcat server invokes Axis, so it's the Tomcat environment that must support the JAXP 1.3 environment. In catalina.bat I placed the following endorsed directory information:

set JAVA_ENDORSED_DIRS=%CATALINA_HOME%\webapps\axis\WEB-INF\lib\endorsed

In this directory place all five JAXP 1.3 files: dom.jar jaxp-api.jar sax.jar xalan.jar and xercesImpl.jar

Add these jars to your project's build path and that's all that needs to be done. Since its an "endorsed" diretory path, the jars in this path will override any jdk classes that come with the sdk, like JAXP 1.2, at least that is my understanding. Axis now works properly, both from a web service client call and when testing within eclipse as a standalone object via main().
I agree. Here's the link:
subject: Axis with JAXP 1.3
It's not a secret anymore!