Question

How can I view the XML being sent to a Java Web Service from a C#-based ASP.NET page?

I've created a disco object web ref in .NET from my Java WSDL, but when I use the likes of Fiddler to view the XML attached to the HTTP request, instead I see the form parameters being passed. Is there a way I can view the serialized XML?

Was it helpful?

Solution

Use tcpmon, from Apache, which can intercept traffic and redirect it to another host/port.

You set up a listener on port A, and all traffic is forwarded to host/port B.

OTHER TIPS

At a minimum, you can view at the HTTP request and response with a packet sniffer like Ethereal/Wireshark.

Or you can use the XmlSerializer and serialize the object instance you are about to pass, to the disk, for instance.

Just a thought. I am certain this is not the best way to do it, but i guess it will work. The idea is to inject a respone filter and overide the write method to log all the output generated from the ASP.NET page. To see how to program an ASP.NET filter check this article :

http://www.highoncoding.com/Articles/468_Protecting_Email_Addresses_Using_Response_Filters.aspx

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top