Author: thomas.diesler(a)jboss.com
Date: 2008-05-22 11:57:06 -0400 (Thu, 22 May 2008)
New Revision: 7143
Modified:
stack/native/trunk/modules/core/src/main/java/org/jboss/ws/tools/jaxws/impl/SunRIConsumerImpl.java
Log:
Restore xmlInputFactory handling. Disable RTEs
Modified:
stack/native/trunk/modules/core/src/main/java/org/jboss/ws/tools/jaxws/impl/SunRIConsumerImpl.java
===================================================================
---
stack/native/trunk/modules/core/src/main/java/org/jboss/ws/tools/jaxws/impl/SunRIConsumerImpl.java 2008-05-22
15:56:17 UTC (rev 7142)
+++
stack/native/trunk/modules/core/src/main/java/org/jboss/ws/tools/jaxws/impl/SunRIConsumerImpl.java 2008-05-22
15:57:06 UTC (rev 7143)
@@ -209,7 +209,7 @@
args.add(wsdl.toString());
// See WsimportTool#compileGeneratedClasses()
- String orgJavaClassPath = System.getProperty("java.class.path");
+ String javaClassPath = System.getProperty("java.class.path");
if(additionalCompilerClassPath.isEmpty() == false)
{
StringBuffer javaCP = new StringBuffer();
@@ -220,6 +220,11 @@
System.setProperty("java.class.path", javaCP.toString());
}
+ // enforce woodstox
+ String xmlInputFactory =
System.getProperty("javax.xml.stream.XMLInputFactory");
+ if (xmlInputFactory == null)
+ System.setProperty("javax.xml.stream.XMLInputFactory",
"com.ctc.wstx.stax.WstxInputFactory");
+
try
{
WsimportTool compileTool = new WsimportTool(stream);
@@ -239,11 +244,14 @@
{
rte.printStackTrace();
}
- throw rte;
+
+ // Investigate, why this cannot be thrown
+ // throw rte;
}
finally
{
- System.setProperty("java.class.path", orgJavaClassPath);
+ System.setProperty("java.class.path", javaClassPath);
+ System.setProperty("javax.xml.stream.XMLInputFactory",
xmlInputFactory);
}
}
}