Context:
I use wso2esb 4.8.0.
I have proxy service:
<?xml version="1.0" encoding="UTF-8"?>
<proxy xmlns="http://ws.apache.org/ns/synapse"
name="eProxy"
transports="https"
statistics="disable"
trace="disable"
startOnLoad="true">
<target>
<inSequence>
</inSequence>
<outSequence>
<send/>
</outSequence>
<endpoint>
<address uri="http://10.24.74.53:8088/xxxService?WSDL"/>
</endpoint>
</target>
<publishWSDL uri="file://wso2esb-4.8.0/repository/mcc/resources/xxx.wsdl"/>
<description/>
</proxy>
Problem:
xxxService response is encoding in iso-8859 and I want to transform this response to utf-8
My first approch:
I use xslt mediator :
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output encoding="UTF-8" />
<xsl:template match="/">
<result>
<xsl:value-of select="." />
</result>
</xsl:template>
</xsl:stylesheet>
but I have error
ERROR NativeWorkerPool uncaught exception java.lang.stackoverflowerror com.sun.org.apache.xerces.internal.impl.XMLEntityScanner.scanName(XMLEntityScanner.java:726)
My second approch:
I set property in out Sequence:
<property name='CHARACTER_SET_ENCODING' scope='Axis2' value='UTF-8'/>
but I have error
ERROR NativeWorkerPool uncaught exception java.lang.stackoverflowerror com.sun.org.apache.xerces.internal.impl.XMLEntityScanner.scanName(XMLEntityScanner.java:726)
My last approch:
I write custom mediator but I dont know how chang SoapEnvelope or SoapBody encoding
thinks for your Help.
To change encoding and content type, look at
ContentType
andmessageType
properties : http://docs.wso2.org/display/ESB480/Generic+PropertiesSample value :
text/xml; charset=ISO-8859-1