[jboss-user] [JBossWS] - Newlines/spaces in SOAPMessage

alfred.rsa do-not-reply at jboss.com
Wed Jul 1 08:52:38 EDT 2009


Hi guys

I have code that works when I call it from a stand-alone application, but when I call it from within JBoss, I get a NPE from the Web service I am calling.
The problem seems to be newline or space characters between the XML tags of the SOAP message. When I use the stand-alone code I get the following output from SOAPMessage().writeTo(System.out)
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"><SOAP-ENV:Body><searchDocDataRequest><f_nr>test_fno</f_nr><userid>cnt_usr</userid><items><cheque format="tiff"><account_nr>62001869538</account_nr></cheque></items></searchDocDataRequest></SOAP-ENV:Body></SOAP-ENV:Envelope>
  | 
>From within JBoss I get:

  | 13:41:03,491 INFO  [STDOUT] <env:Envelope xmlns:env='http://schemas.xmlsoap.org/soap/envelope/'><env:Body><searchDocDataRequest><f_nr>test_fno
  | 13:41:03,491 INFO  [STDOUT] </f_nr>
  | 13:41:03,491 INFO  [STDOUT] <userid>cnt_usr
  | 13:41:03,491 INFO  [STDOUT] </userid>
  | 13:41:03,507 INFO  [STDOUT] <items><cheque format='tiff'><account_nr>62001869538
  | 13:41:03,507 INFO  [STDOUT] </account_nr>
  | 13:41:03,507 INFO  [STDOUT] </cheque>
  | 13:41:03,507 INFO  [STDOUT] </items>
  | 13:41:03,523 INFO  [STDOUT] </searchDocDataRequest>
  | 13:41:03,523 INFO  [STDOUT] </env:Body></env:Envelope>
The only difference being the prefix and the newline/space.
Does anybody have any idea on how I can remove this?

Reards
Alfred

View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4241183#4241183

Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4241183



More information about the jboss-user mailing list