Question

I've got a system where some C++ code (using xmlrpc-c) talks to a Java servlet which uses the Apache XML-RPC library.

I've got a problem that would be a whole lot easier to resolve if I could view the actual XML being sent back and forth. Is there some way to turn on logging of the wire protocol XML in either Apache XMLRPC or xmlrpc-c?

Was it helpful?

Solution 2

I've found a way to do it on the C++ side. If you define the environment variable XMLRPC_TRACE_XML before running your xmlrpc-c code, it logs all XML received and sent and sends it to stderr.

See The xmlrpc-c docs for details.

OTHER TIPS

Not sure about the logging part, but if the library you're using lets you specify a proxy, you could direct it to a web debugger like Fiddler, and see the output there.

Another possibility is to use a network sniffer tool like WireShark. It has a "follow conversation" feature that makes it easy to see the content of multiple packets.

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