Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Print out the SOAP request

 
Jeppe Sommer
Ranch Hand
Posts: 270
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How can I print out the SOAP request to see how the SOAP Envelope looks like?


[ June 06, 2006: Message edited by: Jeppe Fjord ]
 
Ulf Dittmer
Rancher
Pie
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It would be much less messy to use a tool like TCPMon to visualize the SOAP request and response. That's also part of the Axis download, and the documentation is here.
 
Jeppe Sommer
Ranch Hand
Posts: 270
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is that the only way to use a tool like "tcpmon" to see how the envelop looks like? I hope there was a certain method to print out what is sent to the webservice...
 
Masoud Kalali
Author
Ranch Hand
Posts: 531
Java Mac OS X Netbeans IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
you may use a message handler to print out the soap messages.
by using handlers you can intercept a message before going out or comming in.
for more information look at :
http://www-128.ibm.com/developerworks/webservices/library/ws-tipjax1.html
 
Ulf Dittmer
Rancher
Pie
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Here's a code snippet I used to print out a SOAP message.


[ June 07, 2006: Message edited by: Ulf Dittmer ]
 
Paul Celona
Greenhorn
Posts: 15
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
When implementing this code snippet in a web service msg handler, where does the println go to?
 
Ulf Dittmer
Rancher
Pie
Posts: 42967
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
@Paul:

It uses standard out, so whereever that goes, the output will go. On the server it usually ends up in one of the log files, but that depends on which server is used.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic