currently I am working on integration some WebServices with a Mule ESB. Its working pretty nicely, but also is not as straightforward as it could be. Especially troubling is a WebService I try to consume which claims to be SOAP, receives and returns plenty of elements on toplevel (which make invoking it via CXF a pain) and: Its returning a corrupted character stream. I contacted the provider and they answered:

The data we are providing is collected from multiple sources, this makes it impossible for us to serve UTF-8 data. We have attached the WSDL for ISO-8859-1

The attached WSDL just changed the XML prolog – fail – this is only the encoding of the wsdl not the service.

Still Mule/CXF complains about invalid UTF-8. But wat bugs me is that it seems to be impossible to correct that bug. I dug 2 days into the deeps of Mule and CXF and found multiple places where I potentially could hook in, but there is an internal Mule Interceptor that reads the XML, fails at the invalid UTF-8 data and dies with throwing an Exception.

Too bad :-(

Does anybody know of a workaround for such? I thought I could use Transformer, but it seems i will not get access to the raw input stream.