views:

91

answers:

2

Is there a way to display or log verbose communication DURING a remote service call with flex? In particular is there a way to get very detailed information about the service call while it is happening. Kind of like tracing HTTP headers from a command line. Basically, getting insight into the server transaction before the result or fault events occur?

I am assuming there must be a convenient way to expose stuff like IP addresses, DNS lookups, number of hops, latency, HTTP headers, AMF data as it is coming over the wire, etc.

+2  A: 

Use http://www.getcharles.com it's very very awesome mac and pc proxy tool that will show you all the data going between flex and the server.

Its made be a good friend of mine but not only does it allow you to see all the HTTP details, headers etc. It will also show the details of AMF data and even allow you to edit these requests (including the AMF data) and send it to the server again. This is great if you want to just get the server code working.
It even has the ability to capture a response and allow you to edit this (slightly more tricky) but very powerful.

It is shareware so you can try it but it *will save you hours. I use it probably daily and it is well worth it's price in saved development time easily.

Cheers, John.

John Ballinger
Charles is the second tool I install on a machine when I'm ready to write Flex code. Flex Builder is the first. That's how awesome Charles is. :)
cliff.meyers
Awesome dude. I talk to the developer all the time and still remind him that I really do love "charles". I think it has saved me so much money and time. Cool to hear other people really like this too.
John Ballinger
Fair enough, I have heard of charles before. I will give it another look. But I was curious if there was a way to expose this information in a production based app. Think visual traceroute type app, or perhaps just a cool way to display low level network activity to an application's users.
Gordon Potter
Are you thinking of http://www.ethereal.com/ that might be what you are looking for?
John Ballinger
I found Charles really useful when debugging ssl connections. By default Charles shows encrypted data decrypted, but that can be configured.
Rydell
+1  A: 

Charles is a must have.

You can put TraceTarget in you main mx:Application and get a lot of data back from most of the remoting classes in Flex:

<mx:TraceTarget/>

It sets your app as the logging target and traces to the console.

Read your comment, if you want an interesting non-debug way to display data, Arthropod is a cool AIR 'console' that you can trace out to.

Joel Hooks