SOAP Message Logging in Metro and WCF

Guest Author
Metro provides Secure, Reliable,
Transactional and .NET 3.0 interoperable Web services stack in
GlassFish. This entry explains how to
enable SOAP message logging in Metro and .NET 3.0.

The SOAP message logging in Metro is explained


In WCF (the Web services stack in .NET), the
Editor Tool
is the

preferred way
to enable SOAP message logging. But sometimes you may want to
directly edit your configuration file, for example, if you do not want to
re-generate the file again. In such cases you can include the XML fragments from
the template configuration file given below into your application specific
configuration and this will enable only SOAP message logging:

<?xml version="1.0" encoding="utf-8"?>
<source name="System.ServiceModel.MessageLogging" switchValue="Warning, ActivityTracing">
<add type="System.Diagnostics.DefaultTraceListener" name="Default">
<filter type="" />
<add name="ServiceModelMessageLoggingListener">
<filter type="" />
<add initializeData="LOG_DIRECTORY\\messages.svclog"
type="System.Diagnostics.XmlWriterTraceListener, System, Version=, Culture=neutral, PublicKeyToken=b77a5c561934e089"
name="ServiceModelMessageLoggingListener" traceOutputOptions="Timestamp">
<filter type="" />
<messageLogging logEntireMessage="true" logMalformedMessages="true" logMessagesAtTransportLevel="true" />

After the client application is invoked, all SOAP messages will be logged to
LOG_DIRECTORY\\messages.svclog file. The message log can be viewed

Technorati: wcf

Be the first to comment

Comments ( 0 )
Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.