Usefulness of WCF Tracing

Today I got some “unhelpful” exception while upgrading one of the project from CRM 4 to 2011. And the structure of the project is changed from using direct communication from website to CRM, now it utilize WCF in between.

I’ve been doing WCF for about 2 year, but now I just found out that WCF tracing can be this useful. So, this is what happened:

Image

No clear explanation right?

Then I decided to trace and add this in web.config of WCF:

<system.diagnostics>
    <sources>
      <source name="System.ServiceModel" switchValue="Information, ActivityTracing" propagateActivity="true">
        <listeners>
          <add name="traceListener" type="System.Diagnostics.XmlWriterTraceListener" initializeData= "c:\traces.svclog" />
        </listeners>
      </source>
    </sources>
  </system.diagnostics>

Do the problematic process again, and it generates:

Image

I opened it, skim through the log and found this:

Image

Double click that one, something goes wrong..

Image

Select that error:

ImageGotcha! Now I have better clue on what I should fix..

Advertisements

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s