From my research, I am considering 3 options:

1) Would a switch from from woodstox to fast infoset be recommended as a workaround ?

2) Could I implement a handler that would do string substitution? Does anyone have an example of adding a handler and springframework?

3) Modify 70+ pojo setters/getters to clean the data as it is set in the pojo so that it's clean when sent?

I would appreciate your thoughts on which of the 3 choices you would make.

Backgrounder:

Using the "echo" type of web service, I can generate the error on the client send of a string that has this whitespace character. Stacktrace is at the bottom of the email.

char c = (char)0x19;
StringBuffer sb = new StringBuffer();
sb.append(c);
System.out.println(service.echo("bad " + sb.toString()));


Personally, I think this is a bug, I should not be concerned if my pojo properties/Strings are valid xml data or not, they are just strings. I think the serializer should escape these whitespace characters just as it does other characters (i.e. &, <, >), but such is life and at the end of the day, my project has to be working.



org.codehaus.xfire.XFireRuntimeException: Could not invoke service.. Nested exception is org.codehaus.xfire.fault.XFireFault: Error writing document.. Nested exception is com.ctc.wstx.exc.WstxIOException: Invalid white space character (0x19) in text to output org.codehaus.xfire.fault.XFireFault: Error writing document.. Nested exception is com.ctc.wstx.exc.WstxIOException: Invalid white space character (0x19) in text to output
at org.codehaus.xfire.fault.XFireFault.createFault(XFireFault.java:89)
at org.codehaus.xfire.client.Invocation.invoke(Invocation.java:79)
at org.codehaus.xfire.client.Client.invoke(Client.java:335)
at org.codehaus.xfire.client.XFireProxy.handleRequest(XFireProxy.java:77)
at org.codehaus.xfire.client.XFireProxy.invoke(XFireProxy.java:57)
at $Proxy45.echo(Unknown Source)
at com.reffects.dmiserviceclient.DMIServiceClient.simpleTest(DMIServiceClient.java:96) at com.reffects.dmiserviceclient.DMIServiceClient.main(DMIServiceClient.java:67) Caused by: org.codehaus.xfire.XFireRuntimeException: Error writing document.. Nested exception is com.ctc.wstx.exc.WstxIOException: Invalid white space character (0x19) in text to output at org.codehaus.xfire.aegis.stax.ElementWriter.writeValue(ElementWriter.java:142)






---------------------------------------------------------------------
To unsubscribe from this list please visit:

   http://xircles.codehaus.org/manage_email

Reply via email to