Clarity, Technology, and Solving Problems | PracticeThis.com
WP7 App with Key Windows Azure resources – Slides, Videos, How-To’s, and T-shooting – for quick consumption on the go.
LinkedIn
Quick Resource Box
The rest of the post is a simple walkthrough of using the API and collecting the events in Procmon.
<?xml version="1.0" encoding="utf-8" ?> <configuration> <system.diagnostics> <trace autoflush="true"> <listeners> <add name="procmon" type="Sysinternals.Debug.ProcessMonitorTraceListener, Sysinternals.Debug"></add> </listeners> </trace> </system.diagnostics> </configuration>
static void Main(string[] args){
Trace.WriteLine("Entering MAIN"); //http://msdn.microsoft.com/en-us/library/system.net.webrequest.aspx WebRequest request = WebRequest.Create(http://www.microsoft.com); HttpWebResponse response = (HttpWebResponse)request.GetResponse(); Stream dataStream = response.GetResponseStream(); StreamReader reader = new StreamReader(dataStream); string responseFromServer = reader.ReadToEnd(); Console.WriteLine(responseFromServer); reader.Close(); dataStream.Close(); response.Close(); Trace.WriteLine("Exiting MAIN");}
Following is the output of the execution of this code as it shows in new and improved Procmon – you can see that both application and system events live in harmony and you can see the latency each one of them contributes:
Heaven… :)
Thank you, Mark and John.