An exception is thrown while getting WSDL for a deployed service
----------------------------------------------------------------
Key: AXIS2-676
URL: http://issues.apache.org/jira/browse/AXIS2-676
Project: Apache Axis 2.0 (Axis2)
Type: Bug
Versions: 1.0
Environment: Widows XP
JDK 1.5.0_06
apache-tomcat-5.5.12
Axis2 1.0 webapp
Reporter: Sébastien Arod
Priority: Critical
I deployed a service in the Axis2 webapp.
The WSDL (UTF-8 encoded) in the aar contains accents (e.g. word "prénom") in
the XSD element annotations.
When I try to get WSDL from deployed service (MyService?wsdl) an Exception is
thrown :
javax.servlet.ServletException: com.ctc.wstx.exc.WstxIOException: Invalid UTF-8
middle byte 0x6e (at char #1999, byte #-1); nested exception is:
org.apache.axiom.om.OMException: com.ctc.wstx.exc.WstxIOException:
Invalid UTF-8 middle byte 0x6e (at char #1999, byte #-1)
org.apache.axis2.transport.http.AxisServlet.doGet(AxisServlet.java:111)
javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
cause mère
org.apache.axis2.AxisFault: com.ctc.wstx.exc.WstxIOException: Invalid UTF-8
middle byte 0x6e (at char #1999, byte #-1); nested exception is:
org.apache.axiom.om.OMException: com.ctc.wstx.exc.WstxIOException:
Invalid UTF-8 middle byte 0x6e (at char #1999, byte #-1)
org.apache.axis2.description.AxisService.getWSDL(AxisService.java:558)
org.apache.axis2.description.AxisService.printWSDL(AxisService.java:533)
org.apache.axis2.transport.http.ListingAgent.processListService(ListingAgent.java:144)
org.apache.axis2.transport.http.ListingAgent.handle(ListingAgent.java:89)
org.apache.axis2.transport.http.AxisServlet.doGet(AxisServlet.java:109)
javax.servlet.http.HttpServlet.service(HttpServlet.java:689)
javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
The WSDL was created with JAXP/DOM : Here is the java code to write DOM
document to file
Transformer xformer = TransformerFactory.newInstance().newTransformer();
xformer.setOutputProperty(OutputKeys.ENCODING, "UTF-8"); //$NON-NLS-1$
OutputStream os = new FileOutputStream(getWSDLFile());
Writer writer = new OutputStreamWriter(os, "UTF8"); //$NON-NLS-1$
xformer.transform(new DOMSource(mDocument), new StreamResult(writer));
os.close();
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira