<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://weblogs.asp.net/utility/FeedStylesheets/atom.xsl" media="screen"?><feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en"><title type="html">Hernan de Lahitte&amp;#39;s blog</title><subtitle type="html">.NET Development from the trenches</subtitle><id>http://weblogs.asp.net/hernandl/atom.aspx</id><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/default.aspx" /><link rel="self" type="application/atom+xml" href="http://weblogs.asp.net/hernandl/atom.aspx" /><generator uri="http://communityserver.org" version="3.0.20510.895">Community Server</generator><updated>2011-03-09T09:20:00Z</updated><entry><title>Your best friend for authoring ETW strongly typed events</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2013/05/02/your-best-friend-for-authoring-etw-strongly-typed-events.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2013/05/02/your-best-friend-for-authoring-etw-strongly-typed-events.aspx</id><published>2013-05-02T17:34:00Z</published><updated>2013-05-02T17:34:00Z</updated><content type="html">&lt;p mce_keep="true"&gt;So you were reading some &lt;a href="http://blogs.msdn.com/b/vancem/archive/2012/07/09/logging-your-own-etw-events-in-c-system-diagnostics-tracing-eventsource.aspx" mce_href="http://blogs.msdn.com/b/vancem/archive/2012/07/09/logging-your-own-etw-events-in-c-system-diagnostics-tracing-eventsource.aspx"&gt;good tutorials&lt;/a&gt; on how&amp;nbsp;to write your first typed event class but for some reason it may &lt;a href="http://blogs.msdn.com/b/vancem/archive/2012/12/21/why-my-doesn-t-my-eventsource-produce-any-events.aspx" mce_href="http://blogs.msdn.com/b/vancem/archive/2012/12/21/why-my-doesn-t-my-eventsource-produce-any-events.aspx"&gt;not work as expected&lt;/a&gt;?&amp;nbsp;(Or many other issues as well)&lt;/p&gt;&lt;p mce_keep="true"&gt;As I wrote in my &lt;a href="http://weblogs.asp.net/hernandl/archive/2013/04/26/enterprise-library-6-0-rtm-is-live.aspx" mce_href="http://weblogs.asp.net/hernandl/archive/2013/04/26/enterprise-library-6-0-rtm-is-live.aspx"&gt;last post&lt;/a&gt; about the new Entlib 6.0, there is helping class in the &lt;a href="http://nuget.org/packages/EnterpriseLibrary.SemanticLogging/" mce_href="http://nuget.org/packages/EnterpriseLibrary.SemanticLogging/"&gt;Semantic Logging Application Block&lt;/a&gt;&amp;nbsp;named &lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.practices.enterpriselibrary.semanticlogging.utility.eventsourceanalyzer(v=pandp.60).aspx" mce_href="http://msdn.microsoft.com/en-us/library/microsoft.practices.enterpriselibrary.semanticlogging.utility.eventsourceanalyzer(v=pandp.60).aspx"&gt;EventSourceAnalyzer&lt;/a&gt; that will help you&amp;nbsp;check your class for multiple potential issues that may be hard to diagnose.&lt;/p&gt;&lt;p mce_keep="true"&gt;Let's see how to write a very simple unit test that will do a full check of your class:&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;[&lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;TestMethod&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;]&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;public&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; &lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;void&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; when_inspecting_myCompanyEventSource()&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;{&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;EventSourceAnalyzer&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;.InspectAll(&lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;MyCompanyEventSource&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;.Log);&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;}&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;p mce_keep="true"&gt;As you can see, your custom class will implement a singleton (Log static method) so this instance will be used by the analyzer to perform many checks and throw an error if it finds something wrong or may not be well implemented according to the &lt;a href="http://blogs.msdn.com/b/vancem/archive/2012/07/09/more-details-on-eventsource-the-class-specification.aspx" mce_href="http://blogs.msdn.com/b/vancem/archive/2012/07/09/more-details-on-eventsource-the-class-specification.aspx"&gt;EventSource guideline&lt;/a&gt;.&lt;/p&gt;&lt;p mce_keep="true"&gt;This class also have an instance usage where you can turn on/off some &lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.practices.enterpriselibrary.semanticlogging.utility.eventsourceanalyzer_properties(v=pandp.60).aspx" mce_href="http://msdn.microsoft.com/en-us/library/microsoft.practices.enterpriselibrary.semanticlogging.utility.eventsourceanalyzer_properties(v=pandp.60).aspx"&gt;knobs&lt;/a&gt; for adjust the check behavior to some custom scenarios. On of the performed checks is the type mapping between the event argument types and the &lt;a href="http://msdn.microsoft.com/en-us/library/hh393412.aspx" mce_href="http://msdn.microsoft.com/en-us/library/hh393412.aspx"&gt;WriteEvent&lt;/a&gt; call inside your event implementation.&lt;/p&gt;&lt;p mce_keep="true"&gt;A standard event may be defined as follow:&lt;/p&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;[&lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;Event&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;]&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;public&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; &lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;void&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; GuidNotMapped(&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;Guid&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; id)&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;{&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;WriteEvent(1, id);&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;}&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;&lt;/span&gt;&lt;/font&gt;&lt;p mce_keep="true"&gt;&lt;font face="arial,helvetica,sans-serif" size="2"&gt;Now in case you want to use on of the defined overloads of WriteEvent and avoid the casting to the params object[] overload&amp;nbsp;described in section 5.6.2 in &lt;/font&gt;&lt;a href="http://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-10-32-81-89/StronglyTypedEvents.docx" mce_href="http://blogs.msdn.com/cfs-file.ashx/__key/communityserver-components-postattachments/00-10-32-81-89/StronglyTypedEvents.docx"&gt;&lt;font face="arial,helvetica,sans-serif" size="2"&gt;StronglyTypedEvents doc&lt;/font&gt;&lt;/a&gt;&lt;font face="arial,helvetica,sans-serif" size="2"&gt;&amp;nbsp;then you may have something like this:&lt;/font&gt;&lt;/p&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;/span&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;[&lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;Event&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;]&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;/span&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;public&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; &lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;void&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; GuidMappedToString(&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;Guid&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; id)&lt;/span&gt;&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;font size="2"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;WriteEvent(1, id.ToString());&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;font size="2"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;&lt;/span&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font face="arial,helvetica,sans-serif" size="2"&gt;&amp;nbsp;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font face="arial,helvetica,sans-serif" size="2"&gt;So in this case, you may use on of the provided knobs described above and bypass the type mapping check:&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font face="Arial" size="2"&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;[&lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;TestMethod&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;]&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;public&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; &lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;void&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;
when_inspecting_myCompanyEventSource_with_typeMapping_off()&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;font size="2"&gt;{&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;var&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; analyzer = &lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;new&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; &lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;EventSourceAnalyzer&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;() { ExcludeWriteEventTypeMapping = &lt;/span&gt;&lt;span style="background: white; color: blue; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;true&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt; };&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;font size="2"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;analyzer.Inspect(&lt;/span&gt;&lt;span style="background: white; color: rgb(43, 145, 175); font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;MyCompanyEventSource&lt;/span&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;.Log);&lt;/span&gt;&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0in 0in 0pt; line-height: normal; mso-layout-grid-align: none;"&gt;&lt;span style="background: white; color: black; font-family: Consolas; font-size: 9.5pt; mso-highlight: white;"&gt;&lt;/span&gt;&lt;span style="background: white; color: black; line-height: 107%; font-family: Consolas; font-size: 9.5pt; mso-highlight: white; mso-fareast-font-family: Calibri; mso-fareast-theme-font: minor-latin; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA;"&gt;&lt;font size="2"&gt;}&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;&lt;p mce_keep="true"&gt;&lt;font face="arial,helvetica,sans-serif"&gt;&lt;font size="2"&gt;&lt;font color="#000000"&gt;I hope you can find the EventSourceAnalizer a good companion for your custom typed events.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;/span&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;/span&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;font face="Times New Roman" size="3"&gt;&lt;p mce_keep="true"&gt;&lt;font face="Times New Roman" size="3"&gt;&lt;/font&gt;&amp;nbsp;&lt;/p&gt;&lt;/font&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=10240936" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term=".NET General" scheme="http://weblogs.asp.net/hernandl/archive/tags/.NET+General/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Enterprise Library 6.0 is RTW (and Unity 3.0)</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2013/04/26/enterprise-library-6-0-rtm-is-live.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2013/04/26/enterprise-library-6-0-rtm-is-live.aspx</id><published>2013-04-26T15:35:00Z</published><updated>2013-04-26T15:35:00Z</updated><content type="html">&lt;p mce_keep="true"&gt;Finally the latest version of &lt;a href="http://msdn.microsoft.com/en-US/library/dn169621.aspx" mce_href="http://msdn.microsoft.com/en-US/library/dn169621.aspx"&gt;Enterprise Library 6.0&lt;/a&gt; (and almost a &lt;a href="http://en.wikipedia.org/wiki/Microsoft_Enterprise_Library" mce_href="http://en.wikipedia.org/wiki/Microsoft_Enterprise_Library"&gt;decade&lt;/a&gt; of evolution&amp;nbsp;from the &lt;a href="http://www.microsoft.com/en-us/download/details.aspx?id=4053" mce_href="http://www.microsoft.com/en-us/download/details.aspx?id=4053"&gt;first block&lt;/a&gt;).&lt;/p&gt;&lt;p mce_keep="true"&gt;A great summary of all the new features along with some insights can be found in this &lt;a href="http://blogs.msdn.com/b/agile/archive/2013/04/25/just-released-microsoft-enterprise-library-6.aspx" mce_href="http://blogs.msdn.com/b/agile/archive/2013/04/25/just-released-microsoft-enterprise-library-6.aspx"&gt;post&lt;/a&gt; from Grigori.&lt;/p&gt;&lt;p mce_keep="true"&gt;My plan is to write a&amp;nbsp;series of post with some additional information and samples of the brand new &lt;a href="http://blogs.msdn.com/b/agile/archive/2013/02/07/embracing-semantic-logging.aspx" mce_href="http://blogs.msdn.com/b/agile/archive/2013/02/07/embracing-semantic-logging.aspx"&gt;Semantic Logging Application Block&lt;/a&gt; which leverage the new &lt;a href="http://blogs.msdn.com/b/vancem/archive/2012/08/13/windows-high-speed-logging-etw-in-c-net-using-system-diagnostics-tracing-eventsource.aspx" mce_href="http://blogs.msdn.com/b/vancem/archive/2012/08/13/windows-high-speed-logging-etw-in-c-net-using-system-diagnostics-tracing-eventsource.aspx"&gt;typed events in NET 4.5&lt;/a&gt;&amp;nbsp;and the high performance &lt;a href="http://msdn.microsoft.com/en-us/magazine/cc163437.aspx" mce_href="http://msdn.microsoft.com/en-us/magazine/cc163437.aspx"&gt;ETW tracing&lt;/a&gt;&amp;nbsp;infrastructure.&lt;/p&gt;&lt;p mce_keep="true"&gt;So I guess that if you are new to typed events in v4.5 and want to start authoring them, you may probably stop by &lt;a href="http://blogs.msdn.com/b/vancem/archive/2012/07/09/logging-your-own-etw-events-in-c-system-diagnostics-tracing-eventsource.aspx" mce_href="http://blogs.msdn.com/b/vancem/archive/2012/07/09/logging-your-own-etw-events-in-c-system-diagnostics-tracing-eventsource.aspx"&gt;Vance blog&lt;/a&gt;, an authority in this matter. &lt;/p&gt;&lt;p mce_keep="true"&gt;You will soon realize that creating a typed event class and start producing events is very easy. However is also easy to introduce hard to diagnose &lt;a href="http://blogs.msdn.com/b/vancem/archive/2012/12/21/why-my-doesn-t-my-eventsource-produce-any-events.aspx" mce_href="http://blogs.msdn.com/b/vancem/archive/2012/12/21/why-my-doesn-t-my-eventsource-produce-any-events.aspx"&gt;errors&lt;/a&gt;. So my first post about the "hidden" goodies in this new block (SLAB for friends) will let you know how you can get a good helping hand for authoring your custom EventSource classes.&lt;/p&gt;&lt;p mce_keep="true"&gt;One more link in &lt;a href="https://entlib.codeplex.com/wikipage?title=EntLib6&amp;amp;referringTitle=Home" mce_href="https://entlib.codeplex.com/wikipage?title=EntLib6&amp;amp;referringTitle=Home"&gt;codeplex&lt;/a&gt;&amp;nbsp;with some discussion forums&amp;nbsp;and additional links as well. Also Unity 3.0 has it's own &lt;a href="http://msdn.microsoft.com/en-us/library/dn170416.aspx" mce_href="http://msdn.microsoft.com/en-us/library/dn170416.aspx"&gt;MSDN page&lt;/a&gt;.&lt;/p&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;p mce_keep="true"&gt;Stay tuned!&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=10215194" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Architecture" scheme="http://weblogs.asp.net/hernandl/archive/tags/Architecture/default.aspx" /><category term=".NET General" scheme="http://weblogs.asp.net/hernandl/archive/tags/.NET+General/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Enterprise Library 6.0 and Semantic Logging </title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2013/02/17/enterprise-library-6-0-and-semantic-logging.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2013/02/17/enterprise-library-6-0-and-semantic-logging.aspx</id><published>2013-02-17T22:01:00Z</published><updated>2013-02-17T22:01:00Z</updated><content type="html">&lt;p mce_keep="true"&gt;&amp;nbsp;Finally the &lt;a href="http://entlib.codeplex.com/releases/view/101823" mce_href="http://entlib.codeplex.com/releases/view/101823"&gt;Semantic Logging CTP&lt;/a&gt; from &lt;a href="http://entlib.codeplex.com/wikipage?title=EntLib6&amp;amp;referringTitle=Home" mce_href="http://entlib.codeplex.com/wikipage?title=EntLib6&amp;amp;referringTitle=Home"&gt;Enterprise Library 6.0&lt;/a&gt; is out.&lt;/p&gt;&lt;p mce_keep="true"&gt;In &lt;a href="http://blogs.msdn.com/b/agile/archive/2013/02/07/embracing-semantic-logging.aspx" mce_href="http://blogs.msdn.com/b/agile/archive/2013/02/07/embracing-semantic-logging.aspx"&gt;this blog post&lt;/a&gt;&amp;nbsp;&lt;a href="http://social.msdn.microsoft.com/profile/grigori%20melnik%20msft/" mce_href="http://social.msdn.microsoft.com/profile/grigori%20melnik%20msft/"&gt;Grigori&lt;/a&gt; presents an insight overview of this new block along with some comments regarding how this blocks leverage the new features in NET 4.5 and ETW.&lt;/p&gt;&lt;p mce_keep="true"&gt;Here is the &lt;a href="http://entlib.codeplex.com/wikipage?title=Entlib6CTPReleaseNotes" mce_href="http://entlib.codeplex.com/wikipage?title=Entlib6CTPReleaseNotes"&gt;Release Notes&lt;/a&gt; that summarizes the goal of this block along with a great &lt;a href="http://channel9.msdn.com/posts/Introducing-Semantic-Logging" mce_href="http://channel9.msdn.com/posts/Introducing-Semantic-Logging"&gt;video&lt;/a&gt; that shows hot to use it.&lt;/p&gt;&lt;p mce_keep="true"&gt;In future post I will try to add some insight on the out-of-process mode that you can use SLAB (Semantic Logging Application Block). &lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=9884315" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Tracing to ETW with Enterprise Library v5</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2012/11/13/tracing-to-etw-with-enterprise-library-v5.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2012/11/13/tracing-to-etw-with-enterprise-library-v5.aspx</id><published>2012-11-13T17:40:00Z</published><updated>2012-11-13T17:40:00Z</updated><content type="html">&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;p mce_keep="true"&gt;&lt;font color="#000000"&gt;&lt;font size="3"&gt;&lt;font face="Calibri"&gt;While I was looking for a way to use &lt;a href="http://msdn.microsoft.com/en-us/library/ms751538.aspx" mce_href="http://msdn.microsoft.com/en-us/library/ms751538.aspx"&gt;ETW Tracing&lt;/a&gt; using the &lt;a href="http://msdn.microsoft.com/en-us/library/ff664569(v=pandp.50).aspx" mce_href="http://msdn.microsoft.com/en-us/library/ff664569(v=pandp.50).aspx"&gt;logging EntLib infrastructure&lt;/a&gt;, I found out that using a handy trace listener&amp;nbsp;like&amp;nbsp;&lt;/font&gt;&lt;/font&gt;&lt;font size="3"&gt;&lt;font face="Calibri"&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/microsoft.practices.enterpriselibrary.logging.configuration.systemdiagnosticstracelistenerdata(v=pandp.50).aspx" mce_href="http://msdn.microsoft.com/en-us/library/microsoft.practices.enterpriselibrary.logging.configuration.systemdiagnosticstracelistenerdata(v=pandp.50).aspx"&gt;SystemDiagnosticsTraceListenerData&lt;/a&gt;&amp;nbsp;configured to use the built-in &lt;a href="http://msdn.microsoft.com/en-us/library/system.diagnostics.eventing.eventprovidertracelistener.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.diagnostics.eventing.eventprovidertracelistener.aspx"&gt;EventProviderTraceListener&lt;/a&gt;&amp;nbsp;was all that I needed. With just&amp;nbsp;setting&amp;nbsp;the event provider&amp;nbsp;ID which is simply a GUID added to the initializeData attribute and I'm good to go.&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p mce_keep="true"&gt;&lt;font color="#000000" face="Calibri" size="3"&gt;This is an example of the config section configured with&amp;nbsp;the above settings:&lt;/font&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;p&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&amp;lt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;listeners&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&amp;gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&amp;lt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;add&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt; &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;listenerDataType&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;=&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;Microsoft.Practices.EnterpriseLibrary.Logging.Configuration.&lt;strong&gt;SystemDiagnosticsTraceListenerData&lt;/strong&gt;, Microsoft.Practices.EnterpriseLibrary.Logging, Version=5.0.505.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;" &lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;type&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;=&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;System.Diagnostics.Eventing.&lt;strong&gt;EventProviderTraceListener&lt;/strong&gt;, System.Core, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;" &lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;traceOutputOptions&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;=&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;ThreadId&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt; &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;name&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;=&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;ETW Trace Listener&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt; &lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;&lt;font color="#ff0000" face="Consolas" size="2"&gt;initializeData&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;=&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"{&lt;strong&gt;D2FAAB3F-5D61-42B5-A014-D1A658BEE0B7&lt;/strong&gt;}&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;"&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt; /&amp;gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&amp;lt;/&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;&lt;font color="#a31515" face="Consolas" size="2"&gt;listeners&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&lt;font color="#0000ff" face="Consolas" size="2"&gt;&amp;gt;&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;p mce_keep="true"&gt;&lt;font face="Calibri" size="3"&gt;&amp;nbsp;&lt;/font&gt;&lt;/p&gt;&lt;font face="Calibri" size="3"&gt;&lt;p mce_keep="true"&gt;Now you can simply use it by calling &lt;font color="#2b91af" face="Consolas" size="2"&gt;&lt;font color="#2b91af" face="Consolas" size="2"&gt;&lt;font color="#2b91af" face="Consolas" size="2"&gt;Logger&lt;/font&gt;&lt;/font&gt;&lt;/font&gt;&lt;font face="Consolas" size="2"&gt;&lt;font face="Consolas" size="2"&gt;.Write(message) &lt;/font&gt;&lt;/font&gt;o or any other logging call. You can also add this listener to any category you want and&amp;nbsp;optionally use formatters as well.&lt;/p&gt;&lt;p mce_keep="true"&gt;Remember that you can activate your event provider by opening and "Admin" command prompt and running:&lt;/p&gt;&lt;p mce_keep="true"&gt;&lt;font color="#006666"&gt;logman create trace myApplication -p {D2FAAB3F-5D61-42B5-A014-D1A658BEE0B7} -o .\etwtrace.etl -ow&lt;br&gt;logman start myApplication&lt;/font&gt; &lt;/p&gt;&lt;p mce_keep="true"&gt;You can check that your data collector set is up and running by inspecting with Performance Monitor (perfmon.msc) and look into "Data Collector Sets\User Defined). There you may&amp;nbsp;check for many properties of your process and also verify the etl file location which by default is in Windows\System32 folder with a file name like "etwtrace_000001.etl".&lt;/p&gt;&lt;p mce_keep="true"&gt;After you are done with the tracing, simply end by typing:&lt;/p&gt;&lt;p mce_keep="true"&gt;&lt;font color="#006699"&gt;logman stop aExpense &lt;br&gt;logman delete aExpense&lt;/font&gt;&lt;/p&gt;&lt;p class="MsoNormal" style="margin: 0cm 0cm 0pt;"&gt;&lt;span lang="EN-US" style="color: rgb(31, 73, 125); mso-ansi-language: EN-US;"&gt;&lt;font color="#000000"&gt;The information saved to the .etl file may be consumed by different
tools described below and we can also use the &lt;/font&gt;&lt;a href="http://technet.microsoft.com/en-us/library/bb490959.aspx" mce_href="http://technet.microsoft.com/en-us/library/bb490959.aspx"&gt;&lt;font color="#000000"&gt;tracerpt&lt;/font&gt;&lt;/a&gt;&lt;font color="#000000"&gt; 
to generate an xml file and inspect the traced data or analyzing with&amp;nbsp;&lt;span lang="EN-US" style='font-family: "Calibri","sans-serif"; font-size: 11pt; mso-ansi-language: EN-US; mso-fareast-font-family: Calibri; mso-fareast-theme-font: minor-latin; mso-bidi-font-family: "Times New Roman"; mso-fareast-language: ES-AR; mso-bidi-language: AR-SA;'&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/ff191077(v=VS.85).aspx" mce_href="http://msdn.microsoft.com/en-us/library/ff191077(v=VS.85).aspx"&gt;WPA
(Windows Performance Analyzer)&lt;/a&gt;.&lt;/span&gt;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;&lt;p mce_keep="true"&gt;&lt;font face="Times New Roman"&gt;

&lt;/font&gt;&lt;/p&gt;&lt;/font&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;p mce_keep="true"&gt;&amp;nbsp;&lt;/p&gt;&lt;p mce_keep="true"&gt;&lt;font face="Times New Roman" size="3"&gt;

&lt;/font&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=9382548" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>WSSF 2010 Open Source for Visual Studio 2012</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2012/09/19/wssf-2010-open-source-for-visual-studio-2012.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2012/09/19/wssf-2010-open-source-for-visual-studio-2012.aspx</id><published>2012-09-19T14:18:00Z</published><updated>2012-09-19T14:18:00Z</updated><content type="html">&lt;p&gt;I just ported the&amp;nbsp;&lt;a href="http://msdn.microsoft.com/en-us/library/bb931187.aspx" mce_href="http://msdn.microsoft.com/en-us/library/bb931187.aspx"&gt;&lt;font color="#3399ff"&gt;Web Service Software Factory Modeling Edition&lt;/font&gt;&lt;/a&gt; (&lt;a href="http://servicefactory.codeplex.com/" mce_href="http://servicefactory.codeplex.com/"&gt;2010 Open Source&lt;/a&gt;) version to VS2012 RTM.&lt;/p&gt;&lt;p&gt;Notice that this is only the source code that builds and run from VS2012 (Windows 7 and Windows 8) but there's not refactoring or leverage of the new features in NET v4.5.&amp;nbsp;&amp;nbsp;&lt;/p&gt;&lt;p&gt;You can download it&amp;nbsp;from &lt;a href="http://servicefactory.codeplex.com/releases/view/94819" mce_href="http://servicefactory.codeplex.com/releases/view/94819"&gt;&lt;font color="#3399ff"&gt;here&lt;/font&gt;&lt;/a&gt;. Don't forget to read the Know issues in the download page.&amp;nbsp;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8947441" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="WSSF" scheme="http://weblogs.asp.net/hernandl/archive/tags/WSSF/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>CQRS Final version shipped</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2012/07/27/cqrs-final-version-shipped.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2012/07/27/cqrs-final-version-shipped.aspx</id><published>2012-07-27T16:39:00Z</published><updated>2012-07-27T16:39:00Z</updated><content type="html">&lt;p&gt;The final version of the &lt;a href="http://msdn.microsoft.com/en-us/library/jj554200.aspx" mce_href="http://msdn.microsoft.com/en-us/library/jj554200.aspx"&gt;CQRS project&lt;/a&gt; is finally out!&amp;nbsp;&lt;/p&gt;&lt;p&gt;After many &lt;a href="http://cqrsjourney.github.com/blog/" mce_href="http://cqrsjourney.github.com/blog/"&gt;optimizations added to the RI&lt;/a&gt;&amp;nbsp;the final code and book is finally public &lt;a href="http://msdn.microsoft.com/en-us/library/jj554200.aspx" mce_href="http://msdn.microsoft.com/en-us/library/jj554200.aspx"&gt;here&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;Some further&amp;nbsp;rich insight details can also be found at&amp;nbsp;&lt;a href="http://blogs.msdn.com/b/agile/" mce_href="http://blogs.msdn.com/b/agile/"&gt;Grigori&lt;/a&gt;'s blog.&lt;/p&gt;&lt;p&gt;Enjoy it!&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8789756" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Architecture" scheme="http://weblogs.asp.net/hernandl/archive/tags/Architecture/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Acceptance Tests &amp; Specflow</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2012/05/15/acceptance-tests-amp-specflow.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2012/05/15/acceptance-tests-amp-specflow.aspx</id><published>2012-05-15T02:32:00Z</published><updated>2012-05-15T02:32:00Z</updated><content type="html">&lt;p&gt;An interesting post from the &lt;a href="http://weblogs.asp.net/hernandl/archive/2012/05/09/cqrs-journey-v1-is-live.aspx" mce_href="http://weblogs.asp.net/hernandl/archive/2012/05/09/cqrs-journey-v1-is-live.aspx"&gt;CQRS project&lt;/a&gt; was posted about the use of &lt;a href="http://cqrsjourney.github.com/blog/2012/05/14/Specing-Out-End-To-End-Scenarios/" mce_href="http://cqrsjourney.github.com/blog/2012/05/14/Specing-Out-End-To-End-Scenarios/"&gt;Specflow and the project Acceptance tests&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;Here you will find the captured experience for creating the tests scenarios and the two approaches used for implementing the specs written with Specflow.&lt;/p&gt;&lt;p&gt;I will add further details on this experience in a future post while we get closer to the final version of the project.&lt;/p&gt;&lt;p&gt;Stay tunned!&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8478720" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Architecture" scheme="http://weblogs.asp.net/hernandl/archive/tags/Architecture/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>CQRS Journey V1 is live</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2012/05/09/cqrs-journey-v1-is-live.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2012/05/09/cqrs-journey-v1-is-live.aspx</id><published>2012-05-09T17:25:00Z</published><updated>2012-05-09T17:25:00Z</updated><content type="html">&lt;p&gt;For the last&amp;nbsp;two month I've been&amp;nbsp;working with the &lt;a href="http://cqrsjourney.github.com/" mce_href="http://cqrsjourney.github.com/"&gt;CQRS Journey&lt;/a&gt; team&amp;nbsp;helping with the spec definitions and acceptance tests using &lt;a href="http://www.specflow.org/" mce_href="http://www.specflow.org/"&gt;Specflow&lt;/a&gt; which was a very interesting experience.&amp;nbsp;&amp;nbsp;&lt;/p&gt;&lt;p&gt;As you can see, this is basically a project from the &lt;a href="http://msdn.microsoft.com/en-us/practices/bb190332" mce_href="http://msdn.microsoft.com/en-us/practices/bb190332"&gt;Patterns &amp;amp; Practices&lt;/a&gt; group that shows an experience about an implementation&amp;nbsp;of &lt;a href="http://martinfowler.com/bliki/CQRS.html" mce_href="http://martinfowler.com/bliki/CQRS.html"&gt;CQRS&lt;/a&gt; pattern into a &lt;a href="http://cqrsjourney.github.com/blog/2012/03/30/Sample-Application-Overview/" mce_href="http://cqrsjourney.github.com/blog/2012/03/30/Sample-Application-Overview/"&gt;reference implementation&lt;/a&gt; application.&lt;/p&gt;&lt;p&gt;You can find more fresh news and further details about this project in its &lt;a href="http://cqrsjourney.github.com/blog/" mce_href="http://cqrsjourney.github.com/blog/"&gt;blog&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;In a future
post I will highlight some of the experience and details of how we implemented
the Acceptance Tests using Specflow within this project.&lt;/span&gt;&lt;/p&gt;&lt;p&gt;Stay tuned!&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8457453" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Architecture" scheme="http://weblogs.asp.net/hernandl/archive/tags/Architecture/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Web Service Software Factory 2010 Open Source CTP</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2011/10/26/web-service-software-factory-2010-open-source-ctp.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2011/10/26/web-service-software-factory-2010-open-source-ctp.aspx</id><published>2011-10-26T11:01:00Z</published><updated>2011-10-26T11:01:00Z</updated><content type="html">&lt;p&gt;As a follow up of the &lt;a href="http://msdn.microsoft.com/en-us/library/bb931187.aspx" mce_href="http://msdn.microsoft.com/en-us/library/bb931187.aspx"&gt;WSSF Modeling Edition&lt;/a&gt;&amp;nbsp;there is a new "flavor" of this tool where the main news is the versioning plan. The basic idea is to release the source code to the comunity in an "open source" model so any user may be free to update and add new features.&lt;/p&gt;&lt;p&gt;As part of this move, there are some additions and fixes that you will get in this open source release (CTP as the time of this post).&lt;/p&gt;&lt;ul&gt;
&lt;li&gt;GAX free (no more dependency with GAX) 
&lt;li&gt;WCF Security Code Analysis added from WSSF v2 and updated to FxCop version 
from VS2010 
&lt;li&gt;Bug fixes 
&lt;li&gt;No more WSSF solution template (the WSSF menu options will show up on any 
compliant project and will let add models and WCF/ASMX templates) 
&lt;li&gt;Translator recipe removed. Writing translators is up to the user or it might 
be added using MEF extensibility. &lt;/li&gt;&lt;/ul&gt;&lt;p&gt;You can download it and get some other build steps from &lt;a href="http://servicefactory.codeplex.com/releases/view/68831" mce_href="http://servicefactory.codeplex.com/releases/view/68831"&gt;here&lt;/a&gt;. &lt;/p&gt;&lt;p&gt;Stay tuned for the "official announcement" in &lt;a href="http://blogs.msdn.com/b/donsmith/" mce_href="http://blogs.msdn.com/b/donsmith/"&gt;Don's blog&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&amp;nbsp;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=8012430" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="WSSF" scheme="http://weblogs.asp.net/hernandl/archive/tags/WSSF/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>WCF Data Services and Custom Authorization</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2011/06/16/wcf-data-services-and-custom-authorization.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2011/06/16/wcf-data-services-and-custom-authorization.aspx</id><published>2011-06-16T10:33:00Z</published><updated>2011-06-16T10:33:00Z</updated><content type="html">&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;In the last post about &lt;a href="http://weblogs.asp.net/hernandl/archive/2011/06/15/decoding-messages-in-wcf-data-services.aspx" mce_href="http://weblogs.asp.net/hernandl/archive/2011/06/15/decoding-messages-in-wcf-data-services.aspx"&gt;&lt;font color="#0000ff"&gt;Decoding
Messages in WCF Data Services&lt;/font&gt;&lt;/a&gt; I showed a code sample about how to decode an
incoming WCF Message in a Data Service. In this case I will show how we can use
this decoded message inside a &lt;/span&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.servicemodel.serviceauthorizationmanager.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.servicemodel.serviceauthorizationmanager.aspx"&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;&lt;font color="#0000ff"&gt;ServiceAuthorizationManager&lt;/font&gt;&lt;/span&gt;&lt;/a&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt; derived class to perform
some &lt;a href="http://blogs.msdn.com/b/drnick/archive/2008/01/08/basing-authorization-on-the-message-body.aspx" mce_href="http://blogs.msdn.com/b/drnick/archive/2008/01/08/basing-authorization-on-the-message-body.aspx"&gt;&lt;font color="#0000ff"&gt;authorization
depending on the content&lt;/font&gt;&lt;/a&gt; (i.e. grant access to some entities according to
the logged on user).&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;The following configuration set an
authorization manager using Windows Authentication.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 5pt 0cm 0pt;" class="Para"&gt;&lt;span style='font-family: "Verdana","sans-serif"; mso-bidi-font-size: 10.0pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;table style="border: currentColor; width: 495pt; border-collapse: collapse; mso-border-alt: solid silver .5pt; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt;" class="MsoNormalTable" border="1" cellSpacing="0" cellPadding="0" width="660"&gt;&lt;font face="Times New Roman"&gt;
 &lt;/font&gt;&lt;tbody&gt;&lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes;"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;td style="background: rgb(243, 243, 243); padding: 0cm 5.4pt; border: 1pt solid silver; width: 495pt; mso-border-alt: solid silver .5pt;" vAlign="top" width="660"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;configuration&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;system.serviceModel&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt; &lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;services&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;service&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;name&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;MyDataService&lt;/span&gt;"
  &lt;span style="color: red;"&gt;behaviorConfiguration&lt;/span&gt;&lt;span style="color: blue;"&gt;=&lt;/span&gt;"&lt;span style="color: blue;"&gt;securityBehavior&lt;/span&gt;"&lt;span style="color: blue;"&gt;&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;endpoint&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;contract&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;System.Data.Services.IRequestHandler&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;binding&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;webHttpBinding&lt;/span&gt;"&lt;span style="color: blue;"&gt; &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;bindingConfiguration&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;WebHttpWindowsAuth&lt;/span&gt;"&lt;span style="color: blue;"&gt;&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;service&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;services&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;behaviors&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;serviceBehaviors&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;behavior&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;name&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;catalogServiceBehavior&lt;/span&gt;"&lt;span style="color: blue;"&gt;&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;serviceMetadata&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;httpGetEnabled&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;true&lt;/span&gt;"&lt;span style="color: blue;"&gt;/&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;serviceDebug&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;includeExceptionDetailInFaults&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;true&lt;/span&gt;"&lt;span style="color: blue;"&gt;/&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;serviceAuthorization&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;serviceAuthorizationManagerType&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;MyServiceAuthorization&lt;/span&gt;"&lt;span style="color: blue;"&gt;/&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;serviceSecurityAudit&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;serviceAuthorizationAuditLevel&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;Failure&lt;/span&gt;"&lt;span style="color: blue;"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;auditLogLocation&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;Application&lt;/span&gt;"&lt;span style="color: blue;"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;messageAuthenticationAuditLevel&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;Failure&lt;/span&gt;"&lt;span style="color: blue;"&gt;/&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;behavior&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;span style="mso-tab-count: 1;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;serviceBehaviors&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;behaviors&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;bindings&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;webHttpBinding&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;binding&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;name&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;WebHttpWindowsAuth&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxBufferSize&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;65536&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxBufferPoolSize&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;2147483647&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxReceivedMessageSize&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;2147483647&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;transferMode&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;StreamedResponse&lt;/span&gt;"&lt;span style="color: blue;"&gt;&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;readerQuotas&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxDepth&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;2147483647&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxStringContentLength&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;2147483647&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxArrayLength&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;2147483647&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxBytesPerRead&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;2147483647&lt;/span&gt;"&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;maxNameTableCharCount&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;2147483647&lt;/span&gt;"&lt;span style="color: blue;"&gt; /&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;security&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;mode&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;TransportCredentialOnly&lt;/span&gt;"&lt;span style="color: blue;"&gt;&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;transport&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt; &lt;/span&gt;&lt;span style="color: red; font-family: Consolas; font-size: 9.5pt;"&gt;clientCredentialType&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;=&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;"&lt;span style="color: blue;"&gt;Windows&lt;/span&gt;"&lt;span style="color: blue;"&gt; /&amp;gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;security&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;binding&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;webHttpBinding&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;bindings&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;/&lt;/span&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;system.serviceModel&lt;/span&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&amp;gt; &lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: rgb(163, 21, 21); font-family: Consolas; font-size: 9.5pt;"&gt;&amp;lt;/configuration&amp;gt;&lt;/span&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;font size="3"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='color: black; line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt; mso-fareast-font-family: "Times New Roman"; mso-bidi-font-family: "Times New Roman"; mso-bidi-font-size: 12.0pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;As you can see, we can also set the audit feature to let
WCF log any security issue on the message. Regarding the binding, we set the
required webHttpBinding to use the max settings for message size assuming that
we may need to send large messages (beware of DOS attacks). We also set the
security setting for using Windows authentication.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;Now we can implement the “&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;CheckAccess(&lt;span style="color: rgb(43, 145, 175);"&gt;OperationContext&lt;/span&gt; operationContext, &lt;span style="color: blue;"&gt;ref&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;Message&lt;/span&gt;
message)&lt;/span&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;”
overload of our &lt;/span&gt;&lt;a href="http://msdn.microsoft.com/en-us/library/system.servicemodel.serviceauthorizationmanager.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.servicemodel.serviceauthorizationmanager.aspx"&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;&lt;font color="#0000ff"&gt;ServiceAuthorizationManager&lt;/font&gt;&lt;/span&gt;&lt;/a&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt; dervived class
(MyServiceAuthorization in config above) and decode the message so we can so
something usefull with its content.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 5pt 0cm 0pt;" class="Para"&gt;&lt;span style='font-family: "Verdana","sans-serif"; mso-bidi-font-size: 10.0pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;table style="border: currentColor; width: 495pt; border-collapse: collapse; mso-border-alt: solid silver .5pt; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt;" class="MsoNormalTable" border="1" cellSpacing="0" cellPadding="0" width="660"&gt;&lt;font face="Times New Roman"&gt;
 &lt;/font&gt;&lt;tbody&gt;&lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes;"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;td style="background: rgb(243, 243, 243); padding: 0cm 5.4pt; border: 1pt solid silver; width: 495pt; mso-border-alt: solid silver .5pt;" vAlign="top" width="660"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;public&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;override&lt;/span&gt;
  &lt;span style="color: blue;"&gt;bool&lt;/span&gt; CheckAccess(&lt;span style="color: rgb(43, 145, 175);"&gt;OperationContext&lt;/span&gt;
  operationContext, &lt;span style="color: blue;"&gt;ref&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;Message&lt;/span&gt; message)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;if&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; (IsGet())&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  &lt;span style="color: blue;"&gt;true&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt; (!CanDecodeMessage(&lt;span style="color: blue;"&gt;ref&lt;/span&gt; message))&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  &lt;span style="color: blue;"&gt;false&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt; (IsUserAllowed())&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  &lt;span style="color: blue;"&gt;true&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt; &lt;span style="color: blue;"&gt;false&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;/span&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;font size="3"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;As you can see, we want to allow read access so we bail
out for GET verbs using the IsGet() function&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;
&lt;/span&gt;described below. After that, if we cannot decode the message we simply
deny access. Otherwise we perform our custom authorization and we are done.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 5pt 0cm 0pt;" class="Para"&gt;&lt;span style='font-family: "Verdana","sans-serif"; mso-bidi-font-size: 10.0pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;table style="border: currentColor; width: 495pt; border-collapse: collapse; mso-border-alt: solid silver .5pt; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt;" class="MsoNormalTable" border="1" cellSpacing="0" cellPadding="0" width="660"&gt;&lt;font face="Times New Roman"&gt;
 &lt;/font&gt;&lt;tbody&gt;&lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes;"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;td style="background: rgb(243, 243, 243); padding: 0cm 5.4pt; border: 1pt solid silver; width: 495pt; mso-border-alt: solid silver .5pt;" vAlign="top" width="660"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;bool&lt;/span&gt; IsGet()&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  RequestMethod().Equals(&lt;span style="color: rgb(163, 21, 21);"&gt;"GET"&lt;/span&gt;, &lt;span style="color: rgb(43, 145, 175);"&gt;StringComparison&lt;/span&gt;.OrdinalIgnoreCase);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;bool&lt;/span&gt; IsDelete()&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  RequestMethod().Equals(&lt;span style="color: rgb(163, 21, 21);"&gt;"DELETE"&lt;/span&gt;,
  &lt;span style="color: rgb(43, 145, 175);"&gt;StringComparison&lt;/span&gt;.OrdinalIgnoreCase);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;string&lt;/span&gt; RequestMethod()&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;object&lt;/span&gt;
  propertyValue;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt; (&lt;span style="color: rgb(43, 145, 175);"&gt;OperationContext&lt;/span&gt;.Current.IncomingMessageProperties.TryGetValue(&lt;span style="color: rgb(43, 145, 175);"&gt;HttpRequestMessageProperty&lt;/span&gt;.Name, &lt;span style="color: blue;"&gt;out&lt;/span&gt; propertyValue))&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span style="color: rgb(43, 145, 175);"&gt;HttpRequestMessageProperty&lt;/span&gt;
  rqMessageProperty = &lt;span style="color: rgb(43, 145, 175);"&gt;HttpRequestMessageProperty&lt;/span&gt;)propertyValue;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  rqMessageProperty.Method;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt; &lt;span style="color: blue;"&gt;string&lt;/span&gt;.Empty;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;bool&lt;/span&gt; CanDecodeMessage(&lt;span style="color: blue;"&gt;ref&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;Message&lt;/span&gt; message)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: blue;"&gt;string&lt;/span&gt; decodedMsg = DecodeMessage(&lt;span style="color: blue;"&gt;ref&lt;/span&gt; message);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt;
  (decodedMsg == &lt;span style="color: blue;"&gt;null&lt;/span&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt; IsDelete();&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  IsMultipart(decodedMsg);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;/span&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;font size="3"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;Notice that “&lt;/span&gt;&lt;span style="line-height: 115%; font-family: Consolas; font-size: 9.5pt;"&gt;DecodeMessage(&lt;span style="color: blue;"&gt;ref&lt;/span&gt;
message)&lt;/span&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;”
is described in a &lt;a href="http://weblogs.asp.net/hernandl/archive/2011/06/15/decoding-messages-in-wcf-data-services.aspx" mce_href="http://weblogs.asp.net/hernandl/archive/2011/06/15/decoding-messages-in-wcf-data-services.aspx"&gt;&lt;font color="#0000ff"&gt;previous
post&lt;/font&gt;&lt;/a&gt;. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;Now an interesting section is how we detect is the
incoming message is actually a &lt;a href="http://www.w3.org/Protocols/rfc1341/7_2_Multipart.html" mce_href="http://www.w3.org/Protocols/rfc1341/7_2_Multipart.html"&gt;&lt;font color="#0000ff"&gt;multipart&lt;/font&gt;&lt;/a&gt; message
which is typically used in &lt;a href="http://msdn.microsoft.com/en-us/library/system.data.services.client.savechangesoptions.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.data.services.client.savechangesoptions.aspx"&gt;&lt;font color="#0000ff"&gt;SaveBatch&lt;/font&gt;&lt;/a&gt;
operations.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;Here we have the inspection of the multipart message and
we can also extract a specific entity and check for access. Notice that we use
the &lt;a href="http://msdn.microsoft.com/en-us/library/system.servicemodel.syndication.atom10itemformatter.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.servicemodel.syndication.atom10itemformatter.aspx"&gt;&lt;font color="#0000ff"&gt;Atom10ItemFormatter&lt;/font&gt;&lt;/a&gt;
class along with some other syndication classes to make it easier the parsing
operation which is a simplification of the &lt;a href="http://msdn.microsoft.com/en-us/library/ee473428.aspx" mce_href="http://msdn.microsoft.com/en-us/library/ee473428.aspx"&gt;&lt;font color="#0000ff"&gt;object
materialization&lt;/font&gt;&lt;/a&gt; mechanism used by Data Services.&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;table style="border: currentColor; width: 495pt; border-collapse: collapse; mso-border-alt: solid silver .5pt; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt;" class="MsoNormalTable" border="1" cellSpacing="0" cellPadding="0" width="660"&gt;&lt;font face="Times New Roman"&gt;
 &lt;/font&gt;&lt;tbody&gt;&lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes;"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;td style="background: rgb(243, 243, 243); padding: 0cm 5.4pt; border: 1pt solid silver; width: 495pt; mso-border-alt: solid silver .5pt;" vAlign="top" width="660"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;bool&lt;/span&gt; IsMultipart(&lt;span style="color: blue;"&gt;string&lt;/span&gt;
  decodedMsg)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;bool&lt;/span&gt;
  isMultipart = &lt;span style="color: blue;"&gt;false&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;foreach&lt;/span&gt; (&lt;span style="color: rgb(43, 145, 175);"&gt;Match&lt;/span&gt; m &lt;span style="color: blue;"&gt;in&lt;/span&gt;
  xmlContentFromMime.Matches(decodedMsg))&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;isMultipart |= HaveEntity(m.Value);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt; (&lt;span style="color: blue;"&gt;false&lt;/span&gt; == isMultipart)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;isMultipart |=
  deleteContentFromMime.Matches(decodedMsg).OfType&amp;lt;&lt;span style="color: rgb(43, 145, 175);"&gt;Match&lt;/span&gt;&amp;gt;().&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;Where(m =&amp;gt; m.Value !=
  DataServicesMetadataNamespace).Count() &amp;gt; 0;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  isMultipart;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;bool&lt;/span&gt; HaveEntity(&lt;span style="color: blue;"&gt;string&lt;/span&gt;
  rawData)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: rgb(43, 145, 175);"&gt;Atom10ItemFormatter&lt;/span&gt;
  atomFormatter;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt;(&lt;span style="color: rgb(43, 145, 175);"&gt;XmlUtility&lt;/span&gt;.TryParse&amp;lt;&lt;span style="color: rgb(43, 145, 175);"&gt;Atom10ItemFormatter&lt;/span&gt;&amp;gt;(rawData,
  &lt;span style="color: blue;"&gt;out&lt;/span&gt; atomFormatter))&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;ThrowOnSensitiveEntity(atomFormatter);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: rgb(43, 145, 175);"&gt;XmlSyndicationContent&lt;/span&gt;
  content = atomFormatter.Item.Content &lt;span style="color: blue;"&gt;as&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;XmlSyndicationContent&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  (content != &lt;span style="color: blue;"&gt;null&lt;/span&gt;);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt; &lt;span style="color: blue;"&gt;false&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;void&lt;/span&gt; ThrowOnSensitiveEntity (&lt;span style="color: rgb(43, 145, 175);"&gt;Atom10ItemFormatter&lt;/span&gt; atomFormatter)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt;
  (atomFormatter.Item.Categories.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;FirstOrDefault(c =&amp;gt;
  c.Name.Equals(&lt;span style="color: blue;"&gt;typeof&lt;/span&gt;(&lt;span style="color: rgb(43, 145, 175);"&gt;MySensitiveEntity&lt;/span&gt;).FullName,
  &lt;span style="color: rgb(43, 145, 175);"&gt;StringComparison&lt;/span&gt;.OrdinalIgnoreCase)) != &lt;span style="color: blue;"&gt;null&lt;/span&gt;)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;throw&lt;/span&gt; &lt;span style="color: blue;"&gt;new&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;SecurityException&lt;/span&gt;(Properties.&lt;span style="color: rgb(43, 145, 175);"&gt;Resources&lt;/span&gt;.AccessDenied);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;/span&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;font size="3"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font face="Calibri"&gt;We use a couple of regular expressions to parse the xml
sections in the multipart and also to detect when we have a DELETE section.&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;table style="border: currentColor; width: 495pt; border-collapse: collapse; mso-border-alt: solid silver .5pt; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt;" class="MsoNormalTable" border="1" cellSpacing="0" cellPadding="0" width="660"&gt;&lt;font face="Times New Roman"&gt;
 &lt;/font&gt;&lt;tbody&gt;&lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes;"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;td style="background: rgb(243, 243, 243); padding: 0cm 5.4pt; border: 1pt solid silver; width: 495pt; mso-border-alt: solid silver .5pt;" vAlign="top" width="660"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;const&lt;/span&gt;
  &lt;span style="color: blue;"&gt;string&lt;/span&gt; DataServicesMetadataNamespace = &lt;span style="color: rgb(163, 21, 21);"&gt;"http://schemas.microsoft.com/ado/2007/08/dataservices/metadata"&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: rgb(43, 145, 175);"&gt;Regex&lt;/span&gt; xmlContentFromMime = &lt;span style="color: blue;"&gt;new&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;Regex&lt;/span&gt;(&lt;span style="color: rgb(163, 21, 21);"&gt;@"&amp;lt;\?xml[^&amp;gt;]+&amp;gt;\s*&amp;lt;\s*(\w+).*?&amp;lt;\s*/\s*\1&amp;gt;"&lt;/span&gt;,
  &lt;span style="color: rgb(43, 145, 175);"&gt;RegexOptions&lt;/span&gt;.Singleline | &lt;span style="color: rgb(43, 145, 175);"&gt;RegexOptions&lt;/span&gt;.Compiled);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: rgb(43, 145, 175);"&gt;Regex&lt;/span&gt; deleteContentFromMime = &lt;span style="color: blue;"&gt;new&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;Regex&lt;/span&gt;(&lt;span style="color: rgb(163, 21, 21);"&gt;"http://([\\w+?\\.\\w+])+([a-zA-Z0-9\\~\\!\\@\\#\\$\\%\\^\\&amp;amp;amp;\\*\\(\\)_\\-\\=\\+\\\\\\/\\?\\.\\:\\;\\'\\,]*)?"&lt;/span&gt;,
  &lt;span style="color: rgb(43, 145, 175);"&gt;RegexOptions&lt;/span&gt;.Singleline | &lt;span style="color: rgb(43, 145, 175);"&gt;RegexOptions&lt;/span&gt;.Compiled);&lt;/span&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;font size="3"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;o:p&gt;&lt;font size="3" face="Calibri"&gt;&amp;nbsp;&lt;/font&gt;&lt;/o:p&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font face="Calibri"&gt;Finally after decoding the message, we can perform our validation.
For that, we can use the result of the message decoding and parsing with the
auxiliary classes shown above and also do some mapping with the incoming user
identity.&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;font size="3" face="Calibri"&gt;Here is a sample of how we can get the incoming identity and
perform some authorization with a pre-configured group or groups (&lt;/font&gt;&lt;span style="line-height: 115%; font-family: Consolas; font-size: 9.5pt;"&gt;AuthorizedGroup&lt;/span&gt;&lt;font face="Calibri"&gt;&lt;font size="3"&gt;)
that we can read from configuration or some external repository.&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;table style="border: currentColor; width: 495pt; border-collapse: collapse; mso-border-alt: solid silver .5pt; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt;" class="MsoNormalTable" border="1" cellSpacing="0" cellPadding="0" width="660"&gt;&lt;font face="Times New Roman"&gt;
 &lt;/font&gt;&lt;tbody&gt;&lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes;"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;td style="background: rgb(243, 243, 243); padding: 0cm 5.4pt; border: 1pt solid silver; width: 495pt; mso-border-alt: solid silver .5pt;" vAlign="top" width="660"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;bool&lt;/span&gt;
  IsUserAllowed ()&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;var&lt;/span&gt;
  groups = GetWindowsGroups();&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt; groups.Contains(AuthorizedGroup,
  &lt;span style="color: rgb(43, 145, 175);"&gt;StringComparer&lt;/span&gt;.OrdinalIgnoreCase);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: rgb(43, 145, 175);"&gt;IEnumerable&lt;/span&gt;&amp;lt;&lt;span style="color: blue;"&gt;string&lt;/span&gt;&amp;gt;
  GetWindowsGroups()&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: rgb(43, 145, 175);"&gt;OperationContext&lt;/span&gt;
  operationContext = &lt;span style="color: rgb(43, 145, 175);"&gt;OperationContext&lt;/span&gt;.Current;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  operationContext == &lt;span style="color: blue;"&gt;null&lt;/span&gt; ? &lt;span style="color: blue;"&gt;new&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;List&lt;/span&gt;&amp;lt;&lt;span style="color: blue;"&gt;string&lt;/span&gt;&amp;gt;() :
  GetWindowsGroups(operationContext.ServiceSecurityContext.WindowsIdentity);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: rgb(43, 145, 175);"&gt;IEnumerable&lt;/span&gt;&amp;lt;&lt;span style="color: blue;"&gt;string&lt;/span&gt;&amp;gt;
  GetWindowsGroups(&lt;span style="color: rgb(43, 145, 175);"&gt;WindowsIdentity&lt;/span&gt; identity)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  identity.Groups != &lt;span style="color: blue;"&gt;null&lt;/span&gt; ?
  identity.Groups.Translate(&lt;span style="color: blue;"&gt;typeof&lt;/span&gt;(&lt;span style="color: rgb(43, 145, 175);"&gt;NTAccount&lt;/span&gt;)).&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;Select&amp;lt;&lt;span style="color: rgb(43, 145, 175);"&gt;IdentityReference&lt;/span&gt;, &lt;span style="color: blue;"&gt;string&lt;/span&gt;&amp;gt;(i
  =&amp;gt; i.Value) : &lt;span style="color: blue;"&gt;new&lt;/span&gt; &lt;span style="color: blue;"&gt;string&lt;/span&gt;[0];&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;/span&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;font size="3"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;o:p&gt;&lt;font size="3" face="Calibri"&gt;&amp;nbsp;&lt;/font&gt;&lt;/o:p&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;p style="margin: 0cm 0cm 10pt;" class="MsoNormal"&gt;&lt;font size="3"&gt;&lt;font face="Calibri"&gt;An interesting part of this implementation is that it can be
completely decoupled from the actual service implementation so we can very easily
switch between different authorization strategies with a simple config change.&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/font&gt;&lt;/p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7831408" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Security" scheme="http://weblogs.asp.net/hernandl/archive/tags/Security/default.aspx" /><category term="Web Services" scheme="http://weblogs.asp.net/hernandl/archive/tags/Web+Services/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Decoding messages in WCF Data Services </title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2011/06/15/decoding-messages-in-wcf-data-services.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2011/06/15/decoding-messages-in-wcf-data-services.aspx</id><published>2011-06-15T16:33:00Z</published><updated>2011-06-15T16:33:00Z</updated><content type="html">&lt;p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;Recently I had to solve an interesting problem while
working with &lt;a href="http://msdn.microsoft.com/en-us/library/cc668792.aspx" mce_href="http://msdn.microsoft.com/en-us/library/cc668792.aspx"&gt;&lt;font color="#0000ff"&gt;WCF
Data Services&lt;/font&gt;&lt;/a&gt; and how to decode an incoming WCF message so I can do
something useful with its content.&lt;/span&gt;&lt;/p&gt;&lt;p style="margin: 5pt 0cm 0pt;" class="Para"&gt;&lt;span style="mso-bidi-font-family: Arial; mso-bidi-font-size: 10.0pt;"&gt;Let’s say that you have an already &lt;a href="http://msdn.microsoft.com/en-us/library/dd728286.aspx" mce_href="http://msdn.microsoft.com/en-us/library/dd728286.aspx"&gt;&lt;font color="#0000ff"&gt;configured&lt;/font&gt;&lt;/a&gt; Data
Service and you intercept the message using some sort extension/interceptors in
WCF. &lt;/span&gt;&lt;/p&gt;&lt;p style="margin: 5pt 0cm 0pt;" class="Para"&gt;&lt;span style="mso-bidi-font-family: Arial; mso-bidi-font-size: 10.0pt;"&gt;Here is an example of such function:&lt;/span&gt;&lt;/p&gt;&lt;p style="margin: 5pt 0cm 0pt;" class="Para"&gt;&lt;span style="mso-bidi-font-family: Arial; mso-bidi-font-size: 10.0pt;"&gt;&lt;/span&gt;&amp;nbsp;&lt;/p&gt;&lt;table style="border: currentColor; width: 495pt; border-collapse: collapse; mso-border-alt: solid silver .5pt; mso-padding-alt: 0cm 5.4pt 0cm 5.4pt;" class="MsoNormalTable" border="1" cellSpacing="0" cellPadding="0" width="660"&gt;&lt;font face="Times New Roman"&gt;
 &lt;/font&gt;&lt;tbody&gt;&lt;tr style="mso-yfti-irow: 0; mso-yfti-firstrow: yes; mso-yfti-lastrow: yes;"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;td style="background: rgb(243, 243, 243); padding: 0cm 5.4pt; border: 1pt solid silver; width: 495pt; mso-border-alt: solid silver .5pt;" vAlign="top" width="660"&gt;&lt;font face="Times New Roman"&gt;
  &lt;/font&gt;&lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="color: blue; font-family: Consolas; font-size: 9.5pt;"&gt;private&lt;/span&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt; &lt;span style="color: blue;"&gt;static&lt;/span&gt;
  &lt;span style="color: blue;"&gt;string&lt;/span&gt; DecodeMessage(&lt;span style="color: blue;"&gt;ref&lt;/span&gt;
  &lt;span style="color: rgb(43, 145, 175);"&gt;Message&lt;/span&gt; message)&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="color: blue;"&gt;if&lt;/span&gt;
  (message.IsEmpty)&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt; &lt;span style="color: blue;"&gt;null&lt;/span&gt;;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;o:p&gt;&amp;nbsp;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;using&lt;/span&gt; (&lt;span style="color: rgb(43, 145, 175);"&gt;MessageBuffer&lt;/span&gt;
  buffer = message.CreateBufferedCopy(&lt;span style="color: rgb(43, 145, 175);"&gt;Int32&lt;/span&gt;.MaxValue))&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
  &lt;/span&gt;&lt;span style="color: rgb(43, 145, 175);"&gt;Message&lt;/span&gt; copy =
  buffer.CreateMessage();&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
  &lt;/span&gt;&lt;span style="color: blue;"&gt;using&lt;/span&gt; (&lt;span style="color: rgb(43, 145, 175);"&gt;MemoryStream&lt;/span&gt;
  ms = &lt;span style="color: blue;"&gt;new&lt;/span&gt; &lt;span style="color: rgb(43, 145, 175);"&gt;MemoryStream&lt;/span&gt;())&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
  &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
  &lt;/span&gt;copy.Properties.Encoder.WriteMessage(copy, ms);&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
  &lt;/span&gt;ms.Flush();&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&lt;/span&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;
  &lt;/span&gt;message = buffer.CreateMessage();&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;span style="color: blue;"&gt;return&lt;/span&gt;
  &lt;span style="color: rgb(43, 145, 175);"&gt;Encoding&lt;/span&gt;.UTF8.GetString(ms.ToArray());&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;p style="margin: 0cm 0cm 0pt; line-height: normal; mso-layout-grid-align: none;" class="MsoNormal"&gt;&lt;span style="font-family: Consolas; font-size: 9.5pt;"&gt;}&lt;/span&gt;&lt;span style='font-family: "Courier New";'&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
  &lt;/td&gt;
 &lt;/tr&gt;
&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;&lt;font size="3"&gt;

&lt;/font&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;As you can notice, after some basic message validation,
we create a &lt;a href="http://blogs.msdn.com/b/drnick/archive/2006/07/26/this-message-cannot-support-the-operation-because-it-has-been-copied.aspx" mce_href="http://blogs.msdn.com/b/drnick/archive/2006/07/26/this-message-cannot-support-the-operation-because-it-has-been-copied.aspx"&gt;&lt;font color="#0000ff"&gt;copy
of the message&lt;/font&gt;&lt;/a&gt; to avoid changing the state of the original message which is
typically passed by reference. Then we write all the content to MemoryStream which
is handy for read/write operations. &lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;The key here is to use the encoder
specified in the message properties which may be &lt;a href="http://msdn.microsoft.com/en-us/library/ms733742.aspx" mce_href="http://msdn.microsoft.com/en-us/library/ms733742.aspx"&gt;&lt;font color="#0000ff"&gt;MTOM&lt;/font&gt;&lt;/a&gt; for this
kind of streamed message but it might be different according to the configured
binding. After writing all the message content to memory, we may read from
memory and create a string so we can easily inspect the actual message. If we
know that we will always deal with XML content, we can use an &lt;a href="http://msdn.microsoft.com/en-us/library/system.xml.xmlreader.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.xml.xmlreader.aspx"&gt;&lt;font color="#0000ff"&gt;XmlReader&lt;/font&gt;&lt;/a&gt;
or the like to manipulate the content without the string conversion which may pay
a performance penalty on large messages. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;span style='line-height: 115%; font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;In the above code, we return the content as string because
we may get an XML or Text formatted message so we can process accordingly.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;In the next post I will show how we
can use this code for inspecting a message to perform a custom authorization
with &lt;a href="http://msdn.microsoft.com/en-us/library/system.servicemodel.serviceauthorizationmanager.aspx" mce_href="http://msdn.microsoft.com/en-us/library/system.servicemodel.serviceauthorizationmanager.aspx"&gt;&lt;font color="#0000ff"&gt;ServiceAuthorizationManager&lt;/font&gt;&lt;/a&gt;.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt;'&gt;Stay tuned!&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;font size="3" face="Times New Roman"&gt;

&lt;/font&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7830718" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Web Services" scheme="http://weblogs.asp.net/hernandl/archive/tags/Web+Services/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Channel 9 presentation with the Composite Services Guidance</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2011/04/11/channel-9-presentation-with-the-composite-services-guidance.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2011/04/11/channel-9-presentation-with-the-composite-services-guidance.aspx</id><published>2011-04-11T23:34:00Z</published><updated>2011-04-11T23:34:00Z</updated><content type="html">&lt;p&gt;Take a look at &lt;a href="http://channel9.msdn.com/Shows/Endpoint/endpointtv-Patterns--Practices-Composite-Services-Guidance-Project" mce_href="http://channel9.msdn.com/Shows/Endpoint/endpointtv-Patterns--Practices-Composite-Services-Guidance-Project"&gt;this presentation&lt;/a&gt; if you want to get a good idea of what is this project directly from &lt;a href="http://blogs.msdn.com/b/dmitrio/" mce_href="http://blogs.msdn.com/b/dmitrio/"&gt;Dmitri&lt;/a&gt;, the "father" of the creature.&lt;/p&gt;&lt;p&gt;And new &lt;a href="http://compositeservices.codeplex.com/releases/view/62235" mce_href="http://compositeservices.codeplex.com/releases/view/62235"&gt;videos&lt;/a&gt; for Service Routing and Inventory Centralizartion patterns.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7753025" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Architecture" scheme="http://weblogs.asp.net/hernandl/archive/tags/Architecture/default.aspx" /><category term="Web Services" scheme="http://weblogs.asp.net/hernandl/archive/tags/Web+Services/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>New Videos for Composite Services Guidance - CTP2</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2011/03/31/new-videos-for-composite-services-guidance-ctp2.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2011/03/31/new-videos-for-composite-services-guidance-ctp2.aspx</id><published>2011-03-31T10:27:00Z</published><updated>2011-03-31T10:27:00Z</updated><content type="html">&lt;p&gt;You can get the latest videos for &lt;a href="http://weblogs.asp.net/hernandl/archive/2011/03/09/patterns-amp-practices-composite-services-ctp2-is-public.aspx" mce_href="http://weblogs.asp.net/hernandl/archive/2011/03/09/patterns-amp-practices-composite-services-ctp2-is-public.aspx"&gt;Composite Services Guidance CTP2&lt;/a&gt;&amp;nbsp;that show many features of this project.&lt;/p&gt;&lt;p&gt;&lt;a href="http://compositeservices.codeplex.com/releases/view/62235" mce_href="http://compositeservices.codeplex.com/releases/view/62235"&gt;Videos Download&lt;/a&gt;&lt;/p&gt;&lt;div id="FileListItem2" class="FileListItemDiv"&gt;&lt;font color="#3e62a6"&gt;Video 1: Repair and Resubmit&lt;/font&gt; 
&lt;div&gt;&lt;font color="#3e62a6"&gt;Video 2: Analytic Tracing&lt;/font&gt; 
&lt;/div&gt;&lt;/div&gt;&lt;div id="FileListItem3" class="FileListItemDiv"&gt;&lt;div&gt;&lt;span id="fileItemInfo3" class="SubText"&gt;&lt;font color="#666666"&gt;
&lt;/font&gt;&lt;/span&gt; &lt;font color="#3e62a6"&gt;Video 3: Custom Probe Function&lt;/font&gt; 
&lt;/div&gt;&lt;/div&gt;&lt;div id="FileListItem4" class="FileListItemDiv"&gt;&lt;div&gt;&lt;font color="#3e62a6"&gt;Video 4: Termination Notification&lt;/font&gt; 
&lt;/div&gt;&lt;/div&gt;&lt;div id="FileListItem5" class="FileListItemDiv"&gt;&lt;div&gt;&lt;font color="#3e62a6"&gt;Video 5: Service Routing&lt;/font&gt; 
&lt;/div&gt;&lt;/div&gt;&lt;div id="FileListItem6" class="FileListItemDiv"&gt;&lt;div&gt;&lt;font color="#3e62a6"&gt;Video 6: Inventory Centralizatioin&lt;/font&gt; 
&lt;/div&gt;&lt;/div&gt;&lt;div id="FileListItem7" class="FileListItemDiv"&gt;&lt;div&gt;&lt;font color="#3e62a6"&gt;Video 7: Inventory Centralization Part 2 - 
Inventory Endpoint&lt;/font&gt; &lt;/div&gt;&lt;/div&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7739583" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Architecture" scheme="http://weblogs.asp.net/hernandl/archive/tags/Architecture/default.aspx" /><category term=".NET General" scheme="http://weblogs.asp.net/hernandl/archive/tags/.NET+General/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Inventory Centralization Patterns with Composite Services CTP2</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2011/03/16/inventory-centralization-patterns-with-composite-services-ctp2.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2011/03/16/inventory-centralization-patterns-with-composite-services-ctp2.aspx</id><published>2011-03-16T11:59:00Z</published><updated>2011-03-16T11:59:00Z</updated><content type="html">&lt;p&gt;Recently my friend and coworker Dmitri Ossipov started&amp;nbsp;&lt;a href="http://blogs.msdn.com/b/dmitrio/" mce_href="http://blogs.msdn.com/b/dmitrio/"&gt;his blog&lt;/a&gt; with&amp;nbsp;great posts about some of the details and many&amp;nbsp;useful links to well know and&amp;nbsp;documented &lt;a href="http://www.soapatterns.com/" mce_href="http://www.soapatterns.com/"&gt;SOA patterns&lt;/a&gt; that this CTP includes.&amp;nbsp;&amp;nbsp;&lt;/p&gt;&lt;p&gt;Check &lt;a href="http://blogs.msdn.com/b/dmitrio/archive/2011/03/14/applying-metadata-centralization-pattern-with-composite-services-ctp2.aspx" mce_href="http://blogs.msdn.com/b/dmitrio/archive/2011/03/14/applying-metadata-centralization-pattern-with-composite-services-ctp2.aspx"&gt;this&lt;/a&gt; out for details on how the CTP implements on of the most public patterns, the Inventory Centralization Patterns, in this case for Schema, Policy and Contracts.&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7724990" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Architecture" scheme="http://weblogs.asp.net/hernandl/archive/tags/Architecture/default.aspx" /><category term="Web Services" scheme="http://weblogs.asp.net/hernandl/archive/tags/Web+Services/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry><entry><title>Patterns &amp; Practices: Composite Services CTP2 is Public</title><link rel="alternate" type="text/html" href="http://weblogs.asp.net/hernandl/archive/2011/03/09/patterns-amp-practices-composite-services-ctp2-is-public.aspx" /><id>http://weblogs.asp.net/hernandl/archive/2011/03/09/patterns-amp-practices-composite-services-ctp2-is-public.aspx</id><published>2011-03-09T12:20:00Z</published><updated>2011-03-09T12:20:00Z</updated><content type="html">&lt;p mce_keep="true"&gt;Finally the last CTP and pre-release version for the Composite &lt;span style='font-family: "Arial","sans-serif"; font-size: 10pt; mso-fareast-font-family: Calibri; mso-fareast-theme-font: minor-latin; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA;' lang="EN-US"&gt;Services &lt;/span&gt;is out. There were quite a lot of changes since &lt;a href="http://weblogs.asp.net/hernandl/archive/2010/10/29/soa-based-composite-service-guidance-ctp1.aspx" mce_href="http://weblogs.asp.net/hernandl/archive/2010/10/29/soa-based-composite-service-guidance-ctp1.aspx"&gt;CTP1&lt;/a&gt;. We added many new samples and many enhancements to the repository (DB) which is now called Inventory in sync with &lt;a href="http://www.soapatterns.org/" mce_href="http://www.soapatterns.org/"&gt;SOA Patterns&lt;/a&gt;. Here is a brief list of the main changes according to the included documentations.&amp;nbsp;&lt;span style='mso-fareast-font-family: "Times New Roman";'&gt;&lt;font size="5"&gt;&amp;nbsp;&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;h1&gt;&lt;span style='mso-fareast-font-family: "Times New Roman";'&gt;&lt;font size="4"&gt;Changes and additions in this release&lt;?xml:namespace prefix = o ns = "urn:schemas-microsoft-com:office:office" /&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/h1&gt;
&lt;p class="ppBodyText"&gt;This CTP release contains reusable source code and samples to illustrate implementation for the following patterns and scenarios:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div class="ppBodyText"&gt;Repair and Resubmit – this pattern is implemented in &lt;a href="http://msdn.microsoft.com/en-us/biztalk/dd876606" mce_href="http://msdn.microsoft.com/en-us/biztalk/dd876606"&gt;ESB Toolkit 2.0&lt;/a&gt; as part of Exception Management Framework (EMF). This code drop provides code sample how to implement this pattern for Windows AppFabric workflow service, using Exceptions Web Service and workflow activities to create fault message, which will be created in EMF database.&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div class="ppBodyText"&gt;Analytic Tracing – this code drop contains reusable code and samples for implementing &lt;a href="http://msdn.microsoft.com/en-us/magazine/cc163437.aspx" mce_href="http://msdn.microsoft.com/en-us/magazine/cc163437.aspx"&gt;ETW tracing&lt;/a&gt;: event collector service and database that store collected events. This capability may be used for scenarios that need flexibility on how collected events are decoded and processed via extensibility points you can configure and implement:&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;plugins and event decoders with leveraging ETW tracing capabilities provided by the event collector service.&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp;&amp;nbsp; &lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div class="ppBodyText"&gt;Inventory Centralization – this code drop contains service catalog database, web services and samples to show how to implement Metadata Centralization, Schema Centralization and Policy Centralization patterns.&lt;span style="mso-spacerun: yes;"&gt;&amp;nbsp; &lt;/span&gt;&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div class="ppBodyText"&gt;Service Virtualization – we included sample for implementing this pattern using &lt;a href="http://msdn.microsoft.com/en-us/library/ee517421.aspx" mce_href="http://msdn.microsoft.com/en-us/library/ee517421.aspx"&gt;WCF routing service&lt;/a&gt;( which is part of .NET framework) and service metadata centralization capabilities to define routing service metadata in service catalog.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;
&lt;ul&gt;
&lt;li&gt;
&lt;div class="ppBodyText"&gt;Termination Notification – we included sample for implementing this pattern using sample WCF service and policy centralization capabilities provided by this CTP release.&lt;/div&gt;&lt;/li&gt;&lt;/ul&gt;

&lt;p class="ppBodyText"&gt;You will also find many new videos that will be uploaded to the &lt;a href="http://compositeservices.codeplex.com/" mce_href="http://compositeservices.codeplex.com/"&gt;home page&lt;/a&gt; any time soon.&lt;/p&gt;
&lt;p class="ppBodyText"&gt;Stay tunned for new posts regarding implemetation details and advanced customizations for custom policy exporters/importers&amp;nbsp;and monitoring.&lt;/p&gt;&lt;p class="ppBodyText"&gt;&lt;strong&gt;UPDATE: &lt;/strong&gt;Check further details on &lt;a href="http://blogs.msdn.com/b/dmitrio/" mce_href="http://blogs.msdn.com/b/dmitrio/"&gt;Dmitri's&lt;/a&gt; great blog here: &lt;a href="http://blogs.msdn.com/b/dmitrio/archive/2011/03/12/composite-services-ctp2-released.aspx" mce_href="http://blogs.msdn.com/b/dmitrio/archive/2011/03/12/composite-services-ctp2-released.aspx"&gt;Composite Services CTP2 Released&lt;/a&gt; and &lt;a href="http://blogs.msdn.com/b/dmitrio/archive/2011/03/14/applying-metadata-centralization-pattern-with-composite-services-ctp2.aspx" mce_href="http://blogs.msdn.com/b/dmitrio/archive/2011/03/14/applying-metadata-centralization-pattern-with-composite-services-ctp2.aspx"&gt;Applying Inventory Centralization Patterns with Composite Services CTP2&lt;/a&gt;&lt;/p&gt;&lt;img src="http://weblogs.asp.net/aggbug.aspx?PostID=7718456" width="1" height="1"&gt;</content><author><name>HernanDL</name><uri>http://weblogs.asp.net/members/HernanDL.aspx</uri></author><category term="Web Services" scheme="http://weblogs.asp.net/hernandl/archive/tags/Web+Services/default.aspx" /><category term="Patterns &amp;amp; Practices" scheme="http://weblogs.asp.net/hernandl/archive/tags/Patterns+_2600_amp_3B00_+Practices/default.aspx" /></entry></feed>