Measuring WCF request on client and server


  • Is there a way to measure time that request spends on WCF Host in a reliable way? 
    On client I can do it by comparing two DateTime objects that are created before and after WCF service call.

    What I have already done is: I have turned on trace on WCF Host and I have investigated it with SvcTraceViewer. 

    What I did afterwards, is I had compared request time on client (time that application spends in WCF Service call) with durations from trace file. To my suprise I came accross such a results:
    - client usually spends 15 seconds in service call
    - according to trace file from server , request usually consumes about 3-4 seconds

    My question is : what is happening with 15-4=11seconds? Is it time needed to encode/decode message and transfer it (I use 100MB LAN). My point is, that durations from client and server are preety confusing - I mean, difference is huge.

    Thanks, Paweł
    Friday, November 27, 2009 3:22 PM


All replies