Problems with Jakarta Axis 1.3 in Oracle 10g (10.1.0.2)
Since I found the solution to this problem on a japanese site (jajakarta), and no trace of it elsewhere I better blog it. I can now only hope that google and all other search engines will index this page, and display it when someone enters the keywords "oracle.xml.parser.v2.XMLDOMException Axis"
When you atempt to deploy a web service on the Oracle 10g platorm (10.1.0.2), using Axis 1.3 straight out of the box, you run into problems with the Oracle XML parser.
I'm not sure exactly what causes this, but I've tracked it down to the class
org.apache.axis.utils.XMLUtils It seems this class is not able to initialize fully with the Oracle provided XML libraries.
The result of this problem, is that if anyone try to auto generate a WSDL file by appending ?wsdl to a service
example :
http://localhost/services/sampleservice?wsdl )
Axis will provide the following output
Fault - ; nested exception is: oracle.xml.parser.v2.XMLDOMException: Implementation does not support the object requested.The soultion to this problem is to specify command line arguments to the java VM running the server during startup like this ;
-Djavax.xml.parsers.SAXParserFactory=
org.apache.crimson.jaxp.SAXParserFactoryImpl
-Djavax.xml.parsers.DocumentBuilderFactory=
org.apache.crimson.jax.DocumentBuilderFactoryImpl
As you can see, we here decide to use the crimson parser instead of the one provided in the Oracle XML library. We could also have included Xerces in our application and sepcified the parser provided there ofcourse.