<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:copyright="http://blogs.law.harvard.edu/tech/rss" xmlns:image="http://purl.org/rss/1.0/modules/image/">
    <channel>
        <title>Paul's Petrov Whiteboard</title>
        <link>http://geekswithblogs.net/paulp/Default.aspx</link>
        <description>[BizTalk, Enterprise Application Integration, Business Process Automation, SOA, .NET]</description>
        <language>en-US</language>
        <copyright>Paul Petrov</copyright>
        <managingEditor>paul@petrovs.com</managingEditor>
        <generator>Subtext Version 0.0.0.0</generator>
        <image>
            <title>Paul's Petrov Whiteboard</title>
            <url>http://geekswithblogs.net/images/RSS2Image.gif</url>
            <link>http://geekswithblogs.net/paulp/Default.aspx</link>
            <width>77</width>
            <height>60</height>
        </image>
        <item>
            <title>Handling SOAP Exceptions in BizTalk Orchestrations with WCF Send Adapter</title>
            <category>BizTalk</category>
            <category>EAI</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/06/23/123096.aspx</link>
            <description>&lt;font size="2"&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;Below is an idea how to improve SOAP exception handling in BizTalk to WCF communication. Let’s consider approach recommended in BizTalk SDK documentation (&lt;a href="http://go.microsoft.com/fwlink/?LinkId=99650"&gt;Catch Typed Fault Exception sample&lt;/a&gt;):&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt; &lt;/div&gt;
&lt;ol style="MARGIN-TOP: 0in" type="1"&gt;
    &lt;li style="MARGIN: 0in 0in 0pt"&gt;Add custom WCF fault to the service contract and add corresponding exception handler in the BizTalk orchestration. &lt;/li&gt;
    &lt;li style="MARGIN: 0in 0in 0pt"&gt;In BizTalk orchestration add hander that expects System.Web.Services.Protocols.SoapException to catch any general SOAP exceptions &lt;/li&gt;
&lt;/ol&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;This allows catching any custom WCF faults and handling them gracefully. It also handles general SOAP exceptions &lt;em&gt;but the downside is that SOAP exception caught will not be original SOAP fault that came over the wire from the service&lt;/em&gt;. It’s going to be secondary SOAP exception thrown by the adapter. Receive pipeline will try to match incoming message type using XPath expressions defined in the send port configuration. Since custom WCF faults are embedded as content of Detail node of the soap:Fault message there will be XPath expression like this: &lt;strong&gt;/*[local-name()='Fault']/*[local-name()='Detail']/* &lt;/strong&gt;| /*[local-name()='DivideResponse'], where the first part is matching any child of Detail element. In case if WCF service returns general SOAP fault it will put original exception in Detail element as ExceptionDetail node (QName: http://schemas.datacontract.org/2004/07/System.ServiceModel#ExceptionDetail). Since the schema for ExceptionDetail is unknown to pipeline it will throw SOAP exception with generic description and all original details will be lost. This secondary SOAP exception is the one that actually caught by our generic handler:&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt 0.25in"&gt; &lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt 0.25in"&gt;&lt;span style="FONT-SIZE: 8.5pt"&gt;There was a failure executing the response(receive) pipeline: "Microsoft.BizTalk.DefaultPipelines.XMLReceive, Microsoft.BizTalk.DefaultPipelines, Version=3.0.1.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" Source: "XML disassembler" Send Port: "WcfSendPort_Operator_WSHttpBinding_IOperation" URI: "http://localhost:8005/calculate" Reason: Finding the document specification by message type "http://schemas.datacontract.org/2004/07/System.ServiceModel#ExceptionDetail" failed. Verify the schema deployed properly.&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt 0.25in"&gt; &lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;One solution to this problem is to define http://schemas.datacontract.org/2004/07/System.ServiceModel#ExceptionDetail schema and include it as a fault contract for the WCF operation on the client side. That way all original SOAP fault details can be captured and propagated as ExceptionDetail fault. So that’s how I modified BizTalk orchestration in SDK sample:&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt; &lt;/div&gt;
&lt;ol style="MARGIN-TOP: 0in" type="1"&gt;
    &lt;li style="MARGIN: 0in 0in 0pt"&gt;Declared new schema ExceptionDetail. &lt;/li&gt;
    &lt;li style="MARGIN: 0in 0in 0pt"&gt;Created new multi-part message type IOperation_Divide_SoapFault that has part of type ExceptionDetail &lt;/li&gt;
    &lt;li style="MARGIN: 0in 0in 0pt"&gt;Added to Divide operation new GenericSoapFault fault of type IOperation_Divide_SoapFault &lt;/li&gt;
    &lt;li style="MARGIN: 0in 0in 0pt"&gt;Added exception handler CatchSoapExceptionDetails for this new fault &lt;/li&gt;
&lt;/ol&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;Notice no changes required on the service side, all I had to do is on the client. But I did one thing in the service code to throw SOAP exception if numerator equal to 0 (just to be able to test such scenario):&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt; &lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt"&gt;           &lt;span style="COLOR: blue"&gt;if&lt;/span&gt; (numerator == 0)&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt"&gt;                &lt;span style="COLOR: blue"&gt;throw&lt;/span&gt; &lt;span style="COLOR: blue"&gt;new&lt;/span&gt; System.Web.Services.Protocols.&lt;span style="COLOR: #2b91af"&gt;SoapException&lt;/span&gt;(&lt;span style="COLOR: #a31515"&gt;"Test exception"&lt;/span&gt;, &lt;span style="COLOR: blue"&gt;new&lt;/span&gt; &lt;span style="COLOR: #2b91af"&gt;XmlQualifiedName&lt;/span&gt;(&lt;span style="COLOR: #a31515"&gt;"A100"&lt;/span&gt;));&lt;/span&gt;&lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt; &lt;/div&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;Dropping input file with 0 as numerator (DivideGenerateSOAPExceptionInput.xml) will create following message in the Fault folder:&lt;/div&gt;
&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;?&lt;/span&gt;&lt;span class="html"&gt;xml&lt;/span&gt; &lt;span class="attr"&gt;version&lt;/span&gt;&lt;span class="kwrd"&gt;="1.0"&lt;/span&gt; &lt;span class="attr"&gt;encoding&lt;/span&gt;&lt;span class="kwrd"&gt;="utf-8"&lt;/span&gt;?&lt;span class="kwrd"&gt;&amp;gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;MyOperationException&lt;/span&gt; &lt;span class="attr"&gt;xmlns&lt;/span&gt;&lt;span class="kwrd"&gt;="http://schemas.datacontract.org/2004/07/Service"&lt;/span&gt; &lt;span class="attr"&gt;xmlns:i&lt;/span&gt;&lt;span class="kwrd"&gt;="http://www.w3.org/2001/XMLSchema-instance"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Error&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;ExceptionDetail xmlns="http://schemas.datacontract.org/2004/07/System.ServiceModel" xmlns:i="http://www.w3.org/2001/XMLSchema-instance"&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;HelpLink i:nil="true" /&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;InnerException i:nil="true" /&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;Message&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;Test exception&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;/Message&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;StackTrace&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;   at Service.Operator.Divide(Int32 numerator, Int32 denominator) in C:\Projects\TestBed\Typed Fault Exception Handling\WcfService\Program.cs:line 37
   at SyncInvokeDivide(Object , Object[] , Object[] )
   at System.ServiceModel.Dispatcher.SyncMethodInvoker.Invoke(Object instance, Object[] inputs, Object[]&lt;span class="attr"&gt;&amp;amp;amp;&lt;/span&gt;amp; outputs)
   at System.ServiceModel.Dispatcher.DispatchOperationRuntime.InvokeBegin(MessageRpc&lt;span class="attr"&gt;&amp;amp;amp;&lt;/span&gt;amp; rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage5(MessageRpc&lt;span class="attr"&gt;&amp;amp;amp;&lt;/span&gt;amp; rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage4(MessageRpc&lt;span class="attr"&gt;&amp;amp;amp;&lt;/span&gt;amp; rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage3(MessageRpc&lt;span class="attr"&gt;&amp;amp;amp;&lt;/span&gt;amp; rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage2(MessageRpc&lt;span class="attr"&gt;&amp;amp;amp;&lt;/span&gt;amp; rpc)
   at System.ServiceModel.Dispatcher.ImmutableDispatchRuntime.ProcessMessage1(MessageRpc&lt;span class="attr"&gt;&amp;amp;amp;&lt;/span&gt;amp; rpc)
   at System.ServiceModel.Dispatcher.MessageRpc.Process(Boolean isOperationContextSet)&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;/StackTrace&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;Type&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;System.Web.Services.Protocols.SoapException&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;/Type&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;&lt;span class="attr"&gt;&amp;amp;lt;&lt;/span&gt;/ExceptionDetail&lt;span class="attr"&gt;&amp;amp;gt;&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Error&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Operation&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;Divide&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Operation&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;MyOperationException&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt; Note it contains exception detail section with original "Test exception" message.&lt;/p&gt;
&lt;div style="MARGIN: 0in 0in 0pt"&gt;Another approach would be to use exclusively SOAP faults for all kind of custom and system faults, reducing number of exception handlers in orchestrations to one.  It can be achieved by implementing custom XML Disassembler pipeline component where incoming message would be inspected and if SOAP Fault is detected all properties can be copied to secondary SOAP fault thus preserving all original exception details.&lt;/div&gt;
&lt;p&gt;&lt;font size="2"&gt;Source code of modified SDK sample is &lt;a href="http://www.box.net/shared/rneikupwko"&gt;available here&lt;/a&gt;.&lt;/font&gt;&lt;/p&gt;
&lt;/font&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=123096"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=123096" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/123096.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/06/23/123096.aspx</guid>
            <pubDate>Mon, 23 Jun 2008 17:29:28 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/123096.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/06/23/123096.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/123096.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/123096.aspx</trackback:ping>
        </item>
        <item>
            <title>Storing BizTalk settings in custom configuration file using Enterprise Library</title>
            <category>.Net</category>
            <category>BizTalk</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/06/11/122803.aspx</link>
            <description>&lt;p&gt;Choice of configuration settings storage is an important topic when it comes to enterprise BizTalk application planning. One of the &lt;a href="http://geekswithblogs.net/michaelstephenson/archive/2008/05/25/122381.aspx"&gt;many options&lt;/a&gt; is to use regular .Net configuration files. Some prefer this way over the Enterprise SSO database option for reasons of simplicity and familiarity. I wanted to show how it can be done with Microsoft Enterprise Library configuration application block.&lt;/p&gt;
&lt;p&gt;In this case Enterprise Library configuration section is placed in the BTNTSvc.exe.config file while application settings are stored in a separate configuration file. The problem here is how do we make EntLib to load required settings file at runtime.  Its done by simple helper class CustomSettings that looks up registry entry for the location and name of the application configuration file and creates FileConfigurationSource with it. The registry entry can be created  by MSI installation package.&lt;/p&gt;
&lt;p&gt;The initialization method of this static helper class looks like this (thread synchronization code omited for brevity):&lt;/p&gt;
&lt;pre class="csharpcode"&gt;          RegistryKey regKey = &lt;span class="kwrd"&gt;null&lt;/span&gt;;

          &lt;span class="kwrd"&gt;try&lt;/span&gt;
          {
             regKey = Registry.LocalMachine.OpenSubKey(&lt;span class="str"&gt;@"Software\MyCompany\MyApplication"&lt;/span&gt;);
             configurationFile = Path.Combine(
             (&lt;span class="kwrd"&gt;string&lt;/span&gt;)regKey.GetValue(&lt;span class="str"&gt;"ConfigDir"&lt;/span&gt;),
             (&lt;span class="kwrd"&gt;string&lt;/span&gt;)regKey.GetValue(&lt;span class="str"&gt;"ConfigFile"&lt;/span&gt;));

              ExeConfigurationFileMap fileMap = &lt;span class="kwrd"&gt;new&lt;/span&gt; ExeConfigurationFileMap();
              fileMap.ExeConfigFilename = configurationFile;
              configuration = ConfigurationManager.OpenMappedExeConfiguration(fileMap, ConfigurationUserLevel.None);
              configurationSource = &lt;span class="kwrd"&gt;new&lt;/span&gt; FileConfigurationSource(configurationFile);

              &lt;span class="rem"&gt;//- store configPath in the settings&lt;/span&gt;
              configuration.AppSettings.Settings.Add(
              &lt;span class="kwrd"&gt;new&lt;/span&gt; KeyValueConfigurationElement(&lt;span class="str"&gt;"configDir"&lt;/span&gt;, (&lt;span class="kwrd"&gt;string&lt;/span&gt;)regKey.GetValue(&lt;span class="str"&gt;"ConfigDir"&lt;/span&gt;)));
           }
           &lt;span class="kwrd"&gt;catch&lt;/span&gt; (Exception ex)
           {
              Debug.WriteLine(&lt;span class="str"&gt;"Exception while initializing Settings:"&lt;/span&gt; + ex.ToString());
              &lt;span class="kwrd"&gt;throw&lt;/span&gt; ex;
           }
           &lt;span class="kwrd"&gt;finally&lt;/span&gt;
           {
              &lt;span class="kwrd"&gt;if&lt;/span&gt; (regKey != &lt;span class="kwrd"&gt;null&lt;/span&gt;) regKey.Close();
           }&lt;/pre&gt;
&lt;p&gt; Then it has method to access properties by name:&lt;/p&gt;
&lt;pre class="csharpcode"&gt;        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;static&lt;/span&gt; &lt;span class="kwrd"&gt;string&lt;/span&gt; GetValue(&lt;span class="kwrd"&gt;string&lt;/span&gt; name)
        {
            KeyValueConfigurationElement entry = Configuration.AppSettings.Settings[name];

            &lt;span class="kwrd"&gt;if&lt;/span&gt; (entry == &lt;span class="kwrd"&gt;null&lt;/span&gt;)
                &lt;span class="kwrd"&gt;throw&lt;/span&gt; &lt;span class="kwrd"&gt;new&lt;/span&gt; ConfigurationErrorsException(&lt;span class="str"&gt;"Key '"&lt;/span&gt; + name + &lt;span class="str"&gt;"' is not found in the configuration file."&lt;/span&gt;);

            &lt;span class="kwrd"&gt;return&lt;/span&gt; Configuration.AppSettings.Settings[name].Value;
        }&lt;/pre&gt;
&lt;p&gt; Which is used as in:&lt;/p&gt;
&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;string&lt;/span&gt; propertyValue = CustomSettings.GetValue(&lt;span class="str"&gt;"propertyName"&lt;/span&gt;);&lt;/pre&gt;
&lt;p&gt; &lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=122803"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=122803" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/122803.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/06/11/122803.aspx</guid>
            <pubDate>Wed, 11 Jun 2008 20:12:37 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/122803.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/06/11/122803.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/122803.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/122803.aspx</trackback:ping>
        </item>
        <item>
            <title>MSBuild Tasks for BizTalk Continuous Integration</title>
            <category>.Net</category>
            <category>BizTalk</category>
            <category>EAI</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/06/09/122746.aspx</link>
            <description>&lt;p&gt;If you store BizTalk application settings in Enterprise SSO database and adapt continuous integration you'll find this MS Build task useful. DeploySSOConfigStore task reads settings from XML configuration file and saves them to the SSO database. The XML can be created (exported) using &lt;a href="http://seroter.wordpress.com/"&gt;Richard Seroter's&lt;/a&gt; SSO tool which I &lt;a href="http://geekswithblogs.net/paulp/archive/2008/05/16/122205.aspx"&gt;modified to support this operation&lt;/a&gt;. So, if you change your configuration settings, just update XML file in the source control and build process will pick it up and propagate changes to your target environment. Using this task is very simple, it accepts just one parameter - location of the XML settings file:&lt;/p&gt;
&lt;pre class="csharpcode"&gt;    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;UsingTask&lt;/span&gt; &lt;span class="attr"&gt;AssemblyFile&lt;/span&gt;&lt;span class="kwrd"&gt;="CustomMSBuildTasks.BizTalk.dll"&lt;/span&gt; &lt;span class="attr"&gt;TaskName&lt;/span&gt;&lt;span class="kwrd"&gt;="CustomMSBuildTasks.BizTalk.DeploySSOConfigStore"&lt;/span&gt;&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;

    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;Target&lt;/span&gt; &lt;span class="attr"&gt;Name&lt;/span&gt;&lt;span class="kwrd"&gt;="DeploySSOConfigStore"&lt;/span&gt; &lt;span class="attr"&gt;DependsOnTargets&lt;/span&gt;&lt;span class="kwrd"&gt;="BizTalkDeploy"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;CustomMSBuildTasks.BizTalk.DeploySSOConfigStore&lt;/span&gt; XmlConfigurationUrl="$(SolutionRoot)\$(BuildBranch)\Source\BizTalkSettings\BizTalk.Configuration.xml"&lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;Target&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt;I also added another useful task for publishing WCF services: PublishBizTalkWcfServices. It's very simple but does all that stuff: setting up virtual directories (if needed), publishing contracts, creating receive locations. It has comprehensive logging that helps tracking down deployment issues quickly.&lt;/p&gt;
&lt;pre class="csharpcode"&gt;    &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;class&lt;/span&gt; PublishBizTalkWcfServices : Task
    {
        &lt;span class="kwrd"&gt;private&lt;/span&gt; &lt;span class="kwrd"&gt;string&lt;/span&gt; serviceDescriptionUrl;

        &lt;span class="rem"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
        &lt;span class="rem"&gt;/// The URL to the description file.&lt;/span&gt;
        &lt;span class="rem"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
        [Required]
        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;string&lt;/span&gt; ServiceDescriptionUrl
        {
            get { &lt;span class="kwrd"&gt;return&lt;/span&gt; serviceDescriptionUrl; }
            set { serviceDescriptionUrl = &lt;span class="kwrd"&gt;value&lt;/span&gt;; }
        }

        &lt;span class="rem"&gt;/// &amp;lt;summary&amp;gt;&lt;/span&gt;
        &lt;span class="rem"&gt;/// Publishes BizTalk schemas as WCF services.&lt;/span&gt;
        &lt;span class="rem"&gt;/// &amp;lt;/summary&amp;gt;&lt;/span&gt;
        &lt;span class="rem"&gt;/// &amp;lt;returns&amp;gt;&amp;lt;/returns&amp;gt;&lt;/span&gt;
        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;override&lt;/span&gt; &lt;span class="kwrd"&gt;bool&lt;/span&gt; Execute()
        {
            WcfServiceDescription description = WcfServiceDescription.LoadXml(ServiceDescriptionUrl);

            Publisher publisher = &lt;span class="kwrd"&gt;new&lt;/span&gt; Publisher();
            publisher.BackgroundWorker = &lt;span class="kwrd"&gt;new&lt;/span&gt; System.ComponentModel.BackgroundWorker();
            publisher.BackgroundWorker.WorkerReportsProgress = &lt;span class="kwrd"&gt;true&lt;/span&gt;;
            publisher.BackgroundWorker.ProgressChanged += &lt;span class="kwrd"&gt;new&lt;/span&gt; System.ComponentModel.ProgressChangedEventHandler(BackgroundWorker_ProgressChanged);

            &lt;span class="kwrd"&gt;try&lt;/span&gt;
            {
                PublishingResults results = publisher.Publish(description);

                Log.LogMessage(results.Message);
            }
            &lt;span class="kwrd"&gt;catch&lt;/span&gt; (Exception ex)
            {
                Log.LogError(ex.ToString(), &lt;span class="kwrd"&gt;null&lt;/span&gt;);
                &lt;span class="kwrd"&gt;return&lt;/span&gt; &lt;span class="kwrd"&gt;false&lt;/span&gt;;
            }
            &lt;span class="kwrd"&gt;return&lt;/span&gt; &lt;span class="kwrd"&gt;true&lt;/span&gt;;
        }

        &lt;span class="kwrd"&gt;public&lt;/span&gt; &lt;span class="kwrd"&gt;void&lt;/span&gt; BackgroundWorker_ProgressChanged(&lt;span class="kwrd"&gt;object&lt;/span&gt; sender, System.ComponentModel.ProgressChangedEventArgs e)
        {
            Log.LogMessage(e.UserState.ToString(), &lt;span class="kwrd"&gt;null&lt;/span&gt;);
        }
    }&lt;/pre&gt;
&lt;p&gt;Complete Visual Studio project is &lt;a href="http://www.box.net/shared/b7ry6iuw4o"&gt;available here&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=122746"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=122746" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/122746.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/06/09/122746.aspx</guid>
            <pubDate>Tue, 10 Jun 2008 01:04:19 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/122746.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/06/09/122746.aspx#feedback</comments>
            <slash:comments>2</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/122746.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/122746.aspx</trackback:ping>
        </item>
        <item>
            <title>Improved SSO Configuration Data Store Tool</title>
            <category>.Net</category>
            <category>BizTalk</category>
            <category>EAI</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/05/16/122205.aspx</link>
            <description>&lt;p&gt;&lt;a href="http://seroter.wordpress.com/"&gt;Richard Seroter&lt;/a&gt; published &lt;a href="http://seroter.wordpress.com/2007/09/21/biztalk-sso-configuration-data-storage-tool/"&gt;useful utility&lt;/a&gt; to store/retrieve BizTalk configuration settings in Enterprise SSO database. I added some more functionality to it.&lt;/p&gt;
&lt;p&gt;First, I added Export/Import functions allowing to actually save values in the external XML file (Richard's implementation allowed storing only field names, calling for extra work should you delete and restore SSO aplication). I kept file format the same but added values stored as text nodes:&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;pre class="csharpcode"&gt;&lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;sso&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
  &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;application&lt;/span&gt; &lt;span class="attr"&gt;name&lt;/span&gt;&lt;span class="kwrd"&gt;="eCommerce.BizTalk.Configuration"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;description&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;Configuration storage for eCommerce BizTalk applications&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;description&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;appUserAccount&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;BizTalk Application Users&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;appUserAccount&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;appAdminAccount&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;BizTalk Server Administrators&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;appAdminAccount&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;contactInfo&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;http://geekswithblogs.net/paulp&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;contactInfo&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;field&lt;/span&gt; &lt;span class="attr"&gt;ordinal&lt;/span&gt;&lt;span class="kwrd"&gt;="0"&lt;/span&gt; &lt;span class="attr"&gt;label&lt;/span&gt;&lt;span class="kwrd"&gt;="App1.SiteId"&lt;/span&gt; &lt;span class="attr"&gt;masked&lt;/span&gt;&lt;span class="kwrd"&gt;="no"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;2&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;field&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;field&lt;/span&gt; &lt;span class="attr"&gt;ordinal&lt;/span&gt;&lt;span class="kwrd"&gt;="1"&lt;/span&gt; &lt;span class="attr"&gt;label&lt;/span&gt;&lt;span class="kwrd"&gt;="App1.UserId"&lt;/span&gt; &lt;span class="attr"&gt;masked&lt;/span&gt;&lt;span class="kwrd"&gt;="no"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;8&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;field&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;field&lt;/span&gt; &lt;span class="attr"&gt;ordinal&lt;/span&gt;&lt;span class="kwrd"&gt;="2"&lt;/span&gt; &lt;span class="attr"&gt;label&lt;/span&gt;&lt;span class="kwrd"&gt;="App2.Timeout"&lt;/span&gt; &lt;span class="attr"&gt;masked&lt;/span&gt;&lt;span class="kwrd"&gt;="no"&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;5000&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;field&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
    &lt;span class="kwrd"&gt;&amp;lt;&lt;/span&gt;&lt;span class="html"&gt;flags&lt;/span&gt; &lt;span class="attr"&gt;configStoreApp&lt;/span&gt;&lt;span class="kwrd"&gt;="yes"&lt;/span&gt; &lt;span class="attr"&gt;allowLocalAccounts&lt;/span&gt;&lt;span class="kwrd"&gt;="yes"&lt;/span&gt; &lt;span class="attr"&gt;enableApp&lt;/span&gt;&lt;span class="kwrd"&gt;="yes"&lt;/span&gt; &lt;span class="kwrd"&gt;/&amp;gt;&lt;/span&gt;
  &lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;application&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;
&lt;span class="kwrd"&gt;&amp;lt;/&lt;/span&gt;&lt;span class="html"&gt;sso&lt;/span&gt;&lt;span class="kwrd"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;New usage scenarios: &lt;/p&gt;
&lt;p&gt;1. Saving configuration: &lt;/p&gt;
&lt;p&gt;1.1 Create application; &lt;br /&gt;
1.2 Save to XML; &lt;br /&gt;
1.3 Manage application - Retrieve settings; &lt;br /&gt;
1.4 Export to XML file created in (1.2).&lt;/p&gt;
&lt;p&gt;2. Restoring previously saved configuration: &lt;/p&gt;
&lt;p&gt;2.1 Create application; &lt;br /&gt;
2.2 Manage application - Import configuration from file created in (1.4) ; &lt;br /&gt;
2.3 Save Changes.&lt;/p&gt;
&lt;p&gt;Accordingly, menu items Import/Export available when the Manage Application tab is selected only.&lt;/p&gt;
&lt;p&gt;The second part of improvement is where I failed. I added "Select Application" button on the Manage Application tab to browse for available applications in SSO database. Currently, it won't find any ConfigStore application it will come back with "No Applications Found" message. &lt;font face="Arial"&gt;I left this button on intentionally hoping that some would help me to solve this problem. It appears that neither ISSOMapper nor ISSOMapper2 return list of ConfigStore type SSO application. This API call will return application of types Individual, Group or Host Group but not ConfigStore which is the one we create using this tool. At least with the SSOFlag combination being set (0x&lt;font face="Arial"&gt;140006). I tried different flag combinations but could not make it work. &lt;/font&gt;So please let me know.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;The code can be &lt;a href="http://www.box.net/shared/anugsg5k48"&gt;downloaded here&lt;/a&gt;.&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=122205"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=122205" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/122205.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/05/16/122205.aspx</guid>
            <pubDate>Fri, 16 May 2008 20:54:34 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/122205.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/05/16/122205.aspx#feedback</comments>
            <slash:comments>4</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/122205.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/122205.aspx</trackback:ping>
        </item>
        <item>
            <title>Generic BizTalk message broker source code</title>
            <category>BizTalk</category>
            <category>EAI</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/02/04/119274.aspx</link>
            <description>I uploaded source code for the generic BizTalk message broker described in &lt;a href="http://geekswithblogs.net/paulp/archive/2008/01/24/118874.aspx"&gt;this post&lt;/a&gt;.&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=119274"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=119274" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/119274.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/02/04/119274.aspx</guid>
            <pubDate>Mon, 04 Feb 2008 18:18:30 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/119274.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/02/04/119274.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/119274.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/119274.aspx</trackback:ping>
        </item>
        <item>
            <title>Our Airports</title>
            <category>Aviation</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/01/30/119112.aspx</link>
            <description>&lt;p&gt;Fellow pilot and talented IT professional, &lt;a href="http://www.megginson.com/blogs/lahso/"&gt;David Megginson&lt;/a&gt;, put out neat web site &lt;font face="Arial"&gt;&lt;a href="http://www.ourairports.com"&gt;http://www.ourairports.com&lt;/a&gt; that allows to leave comments about airports visited (as pilot or passenger), and share personal maps. I added those where I landed as a pilot from the logbook and it shows how I definitely need some real "cross country" trips :)&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial"&gt;&lt;iframe src="http://www.ourairports.com/members/airman/map.html?role=any" frameborder="0" width="500" scrolling="no" height="400"&gt;&lt;/iframe&gt;&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=119112"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=119112" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/119112.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/01/30/119112.aspx</guid>
            <pubDate>Thu, 31 Jan 2008 05:30:34 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/119112.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/01/30/119112.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/119112.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/119112.aspx</trackback:ping>
        </item>
        <item>
            <title>Generic BizTalk Patterns: Message Broker with Dynamic Transformation</title>
            <category>BizTalk</category>
            <category>EAI</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/01/24/118874.aspx</link>
            <description>&lt;p&gt;&lt;font face="Arial"&gt;This time we'll combine loosely-typed BizTalk messaging concept with dynamic mapping to create generic transformation orchestration. Then we'll add it to the message broker created in the &lt;a href="http://geekswithblogs.net/paulp/archive/2008/01/15/118550.aspx"&gt;first article&lt;/a&gt; to make it even more powerful. &lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial"&gt;Quite often message dispatching task must be combined with some content adaptation: data mapping, filtering, calculation, etc. Generally, maps are used in BizTalk to achieve that. Since maps are based on source and destination schemas we need to find a way to abstract transformation process from specific schema type to common XmlDocument. What makes it possible is XLANGs &lt;font face="Courier New"&gt;transform&lt;/font&gt; command. This command accepts output message as argument and uses System.Type of BizTalk map. It allows us dynamically load and apply any map type to any message type.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial"&gt;First, we have to author schemas and maps. I created two input schemas for this project: NewEmployee.xsd, NewOrder.xml; two output schemas: Employee.xsd, Order.xsd; and two corresponding maps: NewEmployee_to_Employee, NewOrder_to_Order.&lt;/font&gt;I did some changes in DispatchMessage orchestration to integrate with TransformMessage.odx. I added new message variable msgTransformed which is an output from transformation orchestration. Then I simply added Decide shape to check if transformation required for incoming fie. If yes, we pass map key and input message to the TransformMessage.odx using CallOrchestration shape. If no mapping provided then we simply copy incoming message content to msgTransformed:&lt;/p&gt;
&lt;p&gt;Again, to retrieve required map name at runtime, we're going to use the same key-value pairs in the configuration file. In our example we used file name as the key so let's follow this trend. If we're gonna store these keys in the same configuration file we need to modify them to keep unique, for example by adding ".MAP" prefix, i.e. &amp;lt;add key="NewEmployee.xml.MAP" value="GenericBiztalkPatterns.Maps.NewEmployee_to_Employee" /&amp;gt;. &lt;/p&gt;
&lt;p&gt;To keep things clean and reusable I factored out mapping functionality in separate TransformMessage.odx. orchestration. This orchestration contains three parameters: msgInput, mapKey, out msgOutput which are self explanatory. Notice, all message parameters are of XmlDocument type again. The orchestration id very simple itself. Read fully qualified map name by passed in key and get Type of this map:&lt;/p&gt;
&lt;p&gt;&lt;font face="Courier New"&gt;mapTypeQName = System.Configuration.ConfigurationManager.AppSettings[mapKey];&lt;br /&gt;
mapType = System.Type.GetType(mapTypeQName);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Then in ConstructMessage shape just apply transformation:&lt;/p&gt;
&lt;p&gt;&lt;font face="Courier New"&gt;transform(msgOutput) = mapType(msgInput);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;That's how it looks in designer:&lt;/p&gt;
&lt;p&gt;&lt;img alt="" src="http://geekswithblogs.net/images/geekswithblogs_net/paulp/4383/o_GenericBizTalkPatterns_TransformMessage1.gif" /&gt;&lt;/p&gt;
&lt;p&gt;I did some changes in DispatchMessage.odx to integrate with TransformMessage.odx. There is new message variable msgTransformed which is going to be an output from transformation. Also, I added Decide shape to check if mapping required. If yes, then input message and map key is passed into TransformMessage.odx through CallOrchestration shape. Ohterwise, input message simply copied to msgTransformed:&lt;/p&gt;
&lt;p&gt;&lt;img alt="" src="http://geekswithblogs.net/images/geekswithblogs_net/paulp/4383/o_GenericBizTalkPatterns_DispatchMessage3.gif" /&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt;Now, all we need is to make sure there're proper entries in the configuration file:&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial"&gt;  &amp;lt;add key="NewEmployee.xml" value="file://C:\Projects\Design Patterns\GenericBizTalkPatterns\GenericBizTalkPatterns.MessageBroker\Ports\File.out\employee.xml" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="NewEmployee.xml.MAP" value="GenericBizTalkPatterns.MessageBroker.Maps.NewEmployee_to_Employee, GenericBizTalkPatterns.MessageBroker, Version=1.0.0.0, Culture=neutral, PublicKeyToken=44e796208f4e4812" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="NewOrder.xml" value="ftp://[Your FTP server path here]/order.xml" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="NewOrder.xml.MAP" value="GenericBizTalkPatterns.MessageBroker.Maps.NewOrder_to_Order, GenericBizTalkPatterns.MessageBroker, Version=1.0.0.0, Culture=neutral, PublicKeyToken=44e796208f4e4812" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="FTPUserName" value="[Your FTP username]" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="FTPPassword" value="[You FTP password]" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="FTPMode" value="true" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="FTPRepresentationType" value="Binary" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="FTPCommandLog" value="C:\Projects\Design Patterns\GenericBizTalkPatterns\GenericBizTalkPatterns.MessageBroker\ftp.log" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="FTPBeforePut_NewOrder.xml" value="" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="NotRoutedDestination" value="file://C:\Projects\Design Patterns\GenericBizTalkPatterns\GenericBizTalkPatterns.MessageBroker\Ports\backup" /&amp;gt;&lt;br /&gt;
  &amp;lt;add key="NotSuportedProtocolDestination" value="file://C:\Projects\Design Patterns\GenericBizTalkPatterns\GenericBizTalkPatterns.MessageBroker\Ports\backup" /&amp;gt;&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;At some point, configuration file can get quite large, that's why I prefer to keep group of settings in individual configuration files, like destinations.config, maps.config, etc., but that's a topic for another article. So far, we've seen how generic messaging concept can help creating flexible agile BizTalk applications. [&lt;a href="http://www.box.net/shared/6vgw0cv0g0"&gt;Source code is available&lt;/a&gt;]&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=118874"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=118874" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/118874.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/01/24/118874.aspx</guid>
            <pubDate>Thu, 24 Jan 2008 19:25:31 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/118874.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/01/24/118874.aspx#feedback</comments>
            <slash:comments>4</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/118874.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/118874.aspx</trackback:ping>
        </item>
        <item>
            <title>Generic BizTalk Patterns: Message Broker</title>
            <category>BizTalk</category>
            <category>EAI</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/01/15/118550.aspx</link>
            <description>&lt;p&gt;Although current BizTalk release does not support .NET generics it does support concept of genericity at the message level. It is possible, of course, through "untyped" messages or messages that don't have specific type attached to their context. Such messages are represented as System.Xml.XmlDocument type in orchestrations. To read more on message typing aspect of BizTalk please refer to &lt;a href="http://geekswithblogs.net/cyoung/articles/58349.aspx"&gt;this excellent post&lt;/a&gt; by Charles Young. I'd like show practical examples of applying generic programming to typical BizTalk tasks. These examples will help to make your BizTalk solutions leaner, more flexible, and easier to maintain.&lt;/p&gt;
&lt;p&gt;Let's start with very common pattern where BizTalk is used as merely message dispatcher - &lt;a href="http://msdn2.microsoft.com/en-us/library/ms978579.aspx"&gt;Message Broker&lt;/a&gt;. The goal of our generic message broker will be to dispatch any type of message to its destination decided at runtime. So, by avoiding type dependency and early routing binding (basically, hardcoding) we would get single very flexible orchestration which can easily handle requirement changes - one of the top goals of good application design.&lt;/p&gt;
&lt;p&gt;Some things to consider before creating BizTalk orchestration. First, we need to figure out how and where to store input to output destination map. Since, it's just key-value pairs, application configuration file will work fine. In my work, I prefer to keep collections of homogenous setting like this in separate xml config files and read them in custom XmlSerializable map (objects like NameValueCollection or Dictionary being non XmlSerializable won't work in orchestration unless placed inside atomic transaction scope). I'll place them in application configuration file now to keep it simple. Next thing, is to decide what to use as a key. Since messages all of the same type to orchestration, we should select something that uniquely maps message to destination. Let's assume that per our requirements it's a input file name, although it can be anything inside message content. The destination will be expressed as complete URL, i.e. [protocol]://[path]/[fileName], for example &lt;a href="ftp://myserver/files/dest.dat"&gt;ftp://myserver/files/dest.dat&lt;/a&gt;. So, the map entry can look like this: &amp;lt;add key="emp.dat" value=&lt;a href="file://myserver/incoming/employees.dat"&gt;file://myserver/incoming/employees.dat&lt;/a&gt; /&amp;gt;. I use .dat extension here just to emphasize it's applicable to any files and not only XML.&lt;/p&gt;
&lt;p&gt;Once questions have been answered, the orchestration comes together fairly quickly. On the global level it has one input port, expression to read routing configuration, Decide shape to branch on routing availability condition, and dynamic send port. Receive shape receives input message of XmlDocument type. Output message of the same type is sent through dynamic send port after routing address and all properties have been set:&lt;/p&gt;
&lt;p&gt;&lt;img alt="DispatchMessage orchestration high level view" src="http://geekswithblogs.net/images/geekswithblogs_net/paulp/4383/r_DispatchMessage_1.gif" /&gt;&lt;/p&gt;
&lt;p&gt;Inside Decide_IfRoutingAvailable shape there are two branches of execution. If routing address is found then it will read destination URL from the configuration and select transport protocol. Otherwise, destination will be set to the backup location from configuration file in order for the message to be preserved:&lt;/p&gt;
&lt;p&gt;&lt;img alt="" src="http://geekswithblogs.net/images/geekswithblogs_net/paulp/4383/o_DispatchMessage_2.gif" /&gt;&lt;/p&gt;
&lt;p&gt;Once protocol is identified, we can create output message and set its properties and destination address. In case if protocol is not supported, we route message to the backup location using the same dynamic send port. That's how it looks inside Choose Protocole decide shape:&lt;/p&gt;
&lt;p&gt;&lt;img alt="DispatchMessage - select protocol" src="http://geekswithblogs.net/images/geekswithblogs_net/paulp/4383/o_DispatchMessage_3.gif" /&gt;&lt;/p&gt;
&lt;p&gt;Let's dive into ConstructFtpMessage shape, to see how properties set:&lt;/p&gt;
&lt;font size="2"&gt;
&lt;p&gt;msgOutput = msgInput;&lt;br /&gt;
msgOutput(FTP.UserName) = System.Configuration.ConfigurationManager.AppSettings["FTPUserName"];&lt;br /&gt;
msgOutput(FTP.Password) = System.Configuration.ConfigurationManager.AppSettings["FTPPassword"]; &lt;br /&gt;
msgOutput(FTP.PassiveMode) = System.Convert.ToBoolean(System.Configuration.ConfigurationManager.AppSettings["FTPMode"]);&lt;br /&gt;
msgOutput(FTP.RepresentationType) = System.Configuration.ConfigurationManager.AppSettings["FTPRepresentationType"];&lt;br /&gt;
msgOutput(FTP.BeforePut) = System.Configuration.ConfigurationManager.AppSettings["FTPBeforePut_" + receivedFileName.ToUpper()];&lt;br /&gt;
msgOutput(FTP.CommandLogFileName) = System.Configuration.ConfigurationManager.AppSettings["FTPCommandLog"]; &lt;/p&gt;
&lt;/font&gt;
&lt;p&gt;First line simply copies our generic input message content to the output message. Susequent lines set FTP properties from configuration file. Then, all that left is to set destination URL on dynamic port and send output message through it:&lt;/p&gt;
&lt;font size="2"&gt;
&lt;p&gt;DestinationSendPort(Microsoft.XLANGs.BaseTypes.Address) = destUrl.ToString();&lt;/p&gt;
&lt;/font&gt;
&lt;p&gt;As the result, we have a single orchestration that can handle hundreds of different message schemas and multiple protocols. Another positive outcome is that deployment greatly simplified. The application has one orchestration, two ports, but only one of them is bound at deployment time. Also, note no schemas, no maps at this time, we will add them later when we augment application with content transformation functionality.&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=118550"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=118550" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/118550.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/01/15/118550.aspx</guid>
            <pubDate>Tue, 15 Jan 2008 06:13:34 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/118550.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/01/15/118550.aspx#feedback</comments>
            <slash:comments>2</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/118550.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/118550.aspx</trackback:ping>
        </item>
        <item>
            <title>Year of Flying</title>
            <category>Aviation</category>
            <link>http://geekswithblogs.net/paulp/archive/2008/01/01/118132.aspx</link>
            <description>&lt;p&gt;Happy New Year! It's good time to summarize flying experience as year past since getting pilot certificate. So, here's some dry statistics:&lt;/p&gt;
&lt;p&gt;
&lt;/p&gt;&lt;table cellspacing="1" cellpadding="1" width="250" summary="" border="0"&gt;
    &lt;tbody&gt;
        &lt;tr&gt;
            &lt;td&gt;Hours total&lt;/td&gt;
            &lt;td&gt;105.7&lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;Night&lt;/td&gt;
            &lt;td&gt;10.3&lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;Cross country&lt;/td&gt;
            &lt;td&gt;28.1&lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;Actual Instrument&lt;/td&gt;
            &lt;td&gt;0.1&lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;Simulated Instrument&lt;/td&gt;
            &lt;td&gt;11.8&lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;Day landings&lt;/td&gt;
            &lt;td&gt;270&lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;Night landings&lt;/td&gt;
            &lt;td&gt;39&lt;/td&gt;
        &lt;/tr&gt;
        &lt;tr&gt;
            &lt;td&gt;Instrument approaches&lt;/td&gt;
            &lt;td&gt;5&lt;/td&gt;
        &lt;/tr&gt;
    &lt;/tbody&gt;
&lt;/table&gt;

&lt;p&gt;Airplanes I've flown: &lt;a href="http://en.wikipedia.org/wiki/Cessna_152"&gt;Cessna C152&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Cessna_172#172M"&gt;Cessna C172M&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Cessna_172#172SP"&gt;Cessna C172SP&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Cessna_177#Cessna_177RG"&gt;Cessna C177RG&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Piper_Cherokee#PA-28-161_Cherokee_Warrior_II"&gt;Piper PA28-161&lt;/a&gt;, &lt;a href="http://en.wikipedia.org/wiki/Piper_Archer"&gt;Piper PA28-181&lt;/a&gt;, &lt;a href="http://www.evektor.cz/at/en/sportstar-popis-en.html"&gt;Evektor Sportstar&lt;/a&gt;, &lt;a href="http://www.vansaircraft.com/public/rv-7int.htm"&gt;Vans RV-7A&lt;/a&gt;, &lt;a href="http://www.airliners.net/search/photo.search?aircraft_genericsearch=Wheeler%20Express&amp;amp;distinct_entry=true"&gt;Wheeler Express&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Airports I landed at: &lt;a href="http://www.airnav.com/airport/KPAE"&gt;PAE&lt;/a&gt; (Everett, WA), &lt;a href="http://www.airnav.com/airport/KAWO"&gt;AWO&lt;/a&gt; (Arlington, WA), &lt;a href="http://www.airnav.com/airport/KBLI"&gt;BLI&lt;/a&gt; (Bellingham, WA), &lt;a href="http://www.airnav.com/airport/KOLM"&gt;OLM&lt;/a&gt; (Olympia, WA), &lt;a href="http://www.airnav.com/airport/KRNT"&gt;RNT&lt;/a&gt; (Renton, WA), &lt;a href="http://www.airnav.com/airport/KCML"&gt;CLM&lt;/a&gt; (Port Angeles, WA), &lt;a href="http://www.airnav.com/airport/S43"&gt;S43&lt;/a&gt; (Snohomish, WA), &lt;a href="http://www.airnav.com/airport/W16"&gt;W16&lt;/a&gt; (Monroe, WA), &lt;a href="http://www.airnav.com/airport/KGPM"&gt;GPM&lt;/a&gt; (Grand Prairie, TX), &lt;a href="http://www.airnav.com/airport/KADS"&gt;ADS&lt;/a&gt; (Addison, TX), &lt;a href="http://www.airnav.com/airport/KRBD"&gt;RBD&lt;/a&gt; (Dallas, TX), &lt;a href="http://www.airnav.com/airport/KTKI"&gt;TKI&lt;/a&gt; (McKinney, TX), &lt;a href="http://www.airnav.com/airport/KXBP"&gt;XBP&lt;/a&gt; (Bridgeport, TX), &lt;a href="http://www.airnav.com/airport/KSEP"&gt;SEP&lt;/a&gt; (Stephenville, TX), &lt;a href="http://www.airnav.com/airport/KFTW"&gt;FTW&lt;/a&gt; (Fort Worth, TX), &lt;a href="http://www.airnav.com/airport/KCRS"&gt;CRS&lt;/a&gt; (Corsicana, TX), &lt;a href="http://www.airnav.com/airport/KJWY"&gt;JWY&lt;/a&gt; (Midlothian, TX), &lt;a href="http://www.airnav.com/airport/KLNC"&gt;LNC&lt;/a&gt; (Lancaster, TX), &lt;a href="http://www.airnav.com/airport/KGKY"&gt;GKY&lt;/a&gt; (Arlington, TX), &lt;a href="http://www.airnav.com/airport/KUTS"&gt;UTS&lt;/a&gt; (Huntsville, TX), &lt;a href="http://www.airnav.com/airport/KGLS"&gt;GLS&lt;/a&gt; (Galveston, TX), &lt;a href="http://www.airnav.com/airport/KJXI"&gt;JXI&lt;/a&gt; (Gilmer, TX), &lt;a href="http://www.airnav.com/airport/T31"&gt;T31&lt;/a&gt; (McKinney, TX), &lt;a href="http://www.airnav.com/airport/KSWI"&gt;SWI&lt;/a&gt; (Sherman, TX), &lt;a href="http://www.airnav.com/airport/KDTO"&gt;DTO&lt;/a&gt; (Denton, TX), &lt;a href="http://www.airnav.com/airport/KGYI"&gt;GYI&lt;/a&gt; (Sherman/Denison, TX).&lt;/p&gt;
&lt;p&gt;One thing I don't want to add up though is the amount of money spent on flying :)&lt;/p&gt;
&lt;p&gt;I started instrument training and logged some simulated time under the hood. So, the new year flying resolutions will be to finish instrument training and get that rating, log at least 60 hours total time, get tailwheel endorsement, get high performance and/or complex endorsements. This should keep me pretty busy, I guess. :) Happy flying in New Year!&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=118132"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=118132" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/118132.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2008/01/01/118132.aspx</guid>
            <pubDate>Wed, 02 Jan 2008 05:16:25 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/118132.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2008/01/01/118132.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/118132.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/118132.aspx</trackback:ping>
        </item>
        <item>
            <title>Generic custom configuration elements collection based on ConfigurationElementCollection</title>
            <category>.Net</category>
            <category>Software Engineering</category>
            <link>http://geekswithblogs.net/paulp/archive/2007/11/13/116830.aspx</link>
            <description>&lt;p&gt;&lt;span style="FONT-SIZE: 9pt; FONT-FAMILY: Arial"&gt;Simple trick that saves me some time and coding when writing custom configuration objects is to define generic collection for them. Let's say I created several custom configuration elements derived from my CustomConfigElementBase which in turn inherits from &lt;a href="http://msdn2.microsoft.com/en-us/library/system.configuration.configurationelement.aspx"&gt;System.Configuration.ConfigurationElement&lt;/a&gt;. Instead of defining strongly typed collections for each type I can simply define class:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;public class &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;GenericConfigElementCollection&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;&amp;lt;T&amp;gt; : &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;ConfigurationElementCollection&lt;u1:p&gt;&lt;/u1:p&gt;&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;where&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; T : &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;CustomConfigElementBase&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;, &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;new&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;()&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: &amp;quot;Courier New&amp;quot;"&gt;{&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;  public&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; T &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;this&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;[&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;int&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; index]&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  {&lt;/span&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;    get&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;    &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;{&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;      return base&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;.BaseGet(index) &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;as&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; T;&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;    }&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;    set&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;    &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;{&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;      if&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; (&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;base&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;.BaseGet(index) != &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;null&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;)&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;       base&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;.BaseRemoveAt(index);&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;      base&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;.BaseAdd(index, &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;value&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;);&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;    }&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  }&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;  protected override &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;ConfigurationElement&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; CreateNewElement()&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  {&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;    return new&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; T();&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  }&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;  protected override object&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; GetElementKey(&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;ConfigurationElement&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; element)&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  {&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;    return&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; ((T)element).ElementKey;&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  }&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: &amp;quot;Courier New&amp;quot;"&gt;}&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt;Note, that base custom configuration element has property ElementKey to satisfy GetElementKey method implementation. If your custom elements have different keys, you can override this property. It's possible to skip CustomConfigElementBase and define generic collection with ConfigurationElement type restriction. GetElementKey implementation would use reflection to retreive key property:&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt;&lt;/span&gt;&lt;/p&gt;
&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;public class &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;GenericConfigElementCollection&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;&amp;lt;T&amp;gt; : &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;ConfigurationElementCollection&lt;u1:p&gt;&lt;/u1:p&gt;&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;where&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; T : &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;ConfigurationElement&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;, &lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;new&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;()&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;{&lt;/span&gt;&lt;/p&gt;
&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;  protected override object&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; GetElementKey(&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;ConfigurationElement&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt; element)&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  {&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;    //- find and return property which is a key for a given type T using reflection&lt;/span&gt;&lt;span style="COLOR: blue"&gt;&lt;u1:p&gt;&lt;/u1:p&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: blue; FONT-FAMILY: Arial"&gt;    ...&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;  }&lt;/span&gt;&lt;/p&gt;
&lt;/span&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: black; FONT-FAMILY: Arial"&gt;}&lt;/span&gt;&lt;/p&gt;
&lt;/span&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt;Now, when we define configuration section we just return generic collection of appropriate type:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt; &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;    &lt;/span&gt;&lt;span style="COLOR: blue"&gt;public&lt;/span&gt; &lt;span style="COLOR: blue"&gt;class&lt;/span&gt; &lt;span style="COLOR: teal"&gt;MyCustomConfigSection&lt;/span&gt; : &lt;span style="COLOR: teal"&gt;ConfigurationSection&lt;u1:p&gt;&lt;/u1:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;    &lt;/span&gt;{&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;        &lt;/span&gt;[&lt;span style="COLOR: teal"&gt;ConfigurationProperty&lt;/span&gt;(&lt;span style="COLOR: maroon"&gt;"myCustomSettings"&lt;/span&gt;, IsRequired = &lt;span style="COLOR: blue"&gt;true&lt;/span&gt;)]&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;        &lt;/span&gt;&lt;span style="COLOR: blue"&gt;public&lt;/span&gt; &lt;span style="COLOR: teal"&gt;GenericConfigElementCollection&lt;/span&gt;&amp;lt;&lt;span style="COLOR: teal"&gt;MyCustomConfigElement&lt;/span&gt;&amp;gt; MyCustomSettings&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;        &lt;/span&gt;{&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;            &lt;/span&gt;&lt;span style="COLOR: blue"&gt;get&lt;u1:p&gt;&lt;/u1:p&gt;&lt;/span&gt;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;            &lt;/span&gt;{&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;                &lt;/span&gt;&lt;span style="COLOR: blue"&gt;return&lt;/span&gt; &lt;span style="COLOR: blue"&gt;this&lt;/span&gt;[&lt;span style="COLOR: maroon"&gt;"myCustomSettings"&lt;/span&gt;] &lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;                  &lt;span style="COLOR: blue"&gt;as&lt;/span&gt; &lt;span style="COLOR: teal"&gt;GenericConfigElementCollection&lt;/span&gt;&amp;lt;&lt;span style="COLOR: teal"&gt;MyCustomConfigElement&lt;/span&gt;&amp;gt;;&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;            &lt;/span&gt;}&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt; mso-layout-grid-align: none"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;        &lt;/span&gt;}&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;u1:p&gt;&lt;/u1:p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial; mso-no-proof: yes"&gt;&lt;span style="mso-spacerun: yes"&gt;    &lt;/span&gt;}&lt;/span&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt;And then just use it in an application code:&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: &amp;quot;Courier New&amp;quot;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;GenericConfigElementCollection&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt;&amp;lt;&lt;span style="COLOR: teal"&gt;MyCustomConfigElement&lt;/span&gt;&amp;gt; configCollection = configSection.MyCustomSettings;&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: &amp;quot;Courier New&amp;quot;"&gt;&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: Arial"&gt;MyCustomConfigSection&lt;/span&gt;&lt;span style="FONT-SIZE: 10pt; FONT-FAMILY: Arial"&gt; configSection = (&lt;span style="COLOR: teal"&gt;MyCustomConfigSection&lt;/span&gt;)&lt;span style="COLOR: teal"&gt;ConfigurationManager&lt;/span&gt;.GetSection(&lt;span style="COLOR: maroon"&gt;"mySection"&lt;/span&gt;);&lt;/span&gt;&lt;/p&gt;
&lt;p&gt; &lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=116830"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=116830" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/116830.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2007/11/13/116830.aspx</guid>
            <pubDate>Tue, 13 Nov 2007 19:32:37 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/116830.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2007/11/13/116830.aspx#feedback</comments>
            <slash:comments>4</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/116830.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/116830.aspx</trackback:ping>
        </item>
        <item>
            <title>Sending flat files to IBM z/OS mainframe by BizTalk FTP adapter</title>
            <category>BizTalk</category>
            <category>EAI</category>
            <link>http://geekswithblogs.net/paulp/archive/2007/10/19/116153.aspx</link>
            <description>&lt;p&gt;Recently, I had to create an orchestration that transfers files to the &lt;a href="http://www.ibm.com/"&gt;IBM&lt;/a&gt; mainframe running &lt;a href="http://www-03.ibm.com/servers/eserver/zseries/zos/"&gt;z/OS&lt;/a&gt; (also called sometimes MVS - Multiple Virtual Storage because of the legacy). The orchestration used dynamic FTP port to correlate incoming messages to the destination. During this exercise I learned something about FTPing to the mainframe with BizTalk adapter.&lt;/p&gt;
&lt;p&gt;First, flat files obviously must be passed in ASCII mode so the FTP server is able to convert them to EBCDIC format. Passed in binary mode files will not be readable as text files since these two formats have incompatible code pages. To ensure proper conversion set FTP.RepresentationType to "ASCII" on the message context.&lt;/p&gt;
&lt;p&gt;Second, records in files must be separated with CR LF not just LF as I was getting from UNIX system. Otherwise, only one record was transferred. You'd likely get a message like "&lt;font face="Arial"&gt;250 Transfer completed (data was truncated)".&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Third, record size must be passed to the mainframe system. This is done by setting FTP.BeforePut property to command options like: &lt;font face="Arial"&gt;SITE DCB LRECL=50 RECFM=FB where LRECL sets the record size of 50 characters.&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;Finally, on some MVS datasets we experienced data truncation even if the LRECL was set properly when record size in flat file exceeded 80 characters. Those unlucky files kept getting truncated to 80 characters per records (which is default value for z/OS) until I sent command WRAPRECORD. So, for such cases setting FTP.BeforePut to something like "&lt;font face="Arial"&gt;SITE DCB LRECL=600 RECFM=FB WRAPRECORD" did the trick.&lt;/font&gt;&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=116153"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=116153" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/116153.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2007/10/19/116153.aspx</guid>
            <pubDate>Fri, 19 Oct 2007 05:17:04 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/116153.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2007/10/19/116153.aspx#feedback</comments>
            <slash:comments>2</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/116153.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/116153.aspx</trackback:ping>
        </item>
        <item>
            <title>Annual breakfast pancake fly-in photos</title>
            <category>Aviation</category>
            <link>http://geekswithblogs.net/paulp/archive/2007/06/06/113045.aspx</link>
            <description>&lt;p&gt;I took son and a friend to Mid-Way Regional airport for the annual breakfast pancake fly-in. It was second time my older son was up in the small plane and he coped very well with his fear he had on the first flight and was really excited. We got there a bit late and missed racing cars but we saw all planes, toured into DC-3, watched T-28B Trojan and T-6 Texan take-offs and &lt;a href="http://www.flickr.com/photos/petrovs/sets/72157600306282048"&gt;other good things&lt;/a&gt;. On the way back we landed at &lt;a href="http://www.airnav.com/airport/KLNC"&gt;Lancaster&lt;/a&gt;, had a lunch and sat in the &lt;a href="http://en.wikipedia.org/wiki/Aero_L-29_Delf%C3%ADn"&gt;L-29&lt;/a&gt; cockpit owned by local pilot. One day I want to fly one.&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=113045"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=113045" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/113045.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2007/06/06/113045.aspx</guid>
            <pubDate>Wed, 06 Jun 2007 18:47:35 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/113045.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2007/06/06/113045.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/113045.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/113045.aspx</trackback:ping>
        </item>
        <item>
            <title>The Disassembler cannot retrieve the document specification using this name...</title>
            <category>BizTalk</category>
            <link>http://geekswithblogs.net/paulp/archive/2007/06/06/113043.aspx</link>
            <description>&lt;p&gt; &lt;span style="FONT-SIZE: 9pt; FONT-FAMILY: Arial"&gt;I've seen developers stumble across this error. Complete message can look like this:&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 7.5pt; FONT-FAMILY: Arial"&gt;A message received by adapter "FILE" on receive location "Receive LocationTransform1" with URI "\\server001\\File.IO\ReceiveLocation1\*.*" is suspended. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 7.5pt; FONT-FAMILY: Arial"&gt;Error details: There was a failure executing the receive pipeline: "MyApplication.ReceivePipeline, MySolution.Application.Pipelines, Version=1.0.0.0, Culture=neutral, PublicKeyToken=5cf43733eafbdceb" Source: "FlatFileDisassembler" Receive Port: "ReceivePortTransform" URI: "\\server001\\File.IO\ReceiveLocation1\\*.*" Reason: The Disassembler cannot retrieve the document specification using this name: "MySolution.MyApplication.Schemas.Alpha,MySolution.MyApplication.Schemas,Version=1.0.0.0,Culture=neutral,PublicKeyToken=5cf43733eafbdceb". &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 9pt; FONT-FAMILY: Arial"&gt;One typical scenario to receive this error is deploying new schema into BizTalk database and forgetting to install it into the GAC. For single server configuration it is easily avoided if assemblies are added to MSI with option GacOnImport. For multi-server deployment GacOnImport won't be enough as it only installs assembly in the GAC of one box. You still need to run MSI on every box in the group so the GacOnInstall do the job.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 9pt; FONT-FAMILY: Arial"&gt;Another case when you get to see this message is if one of host instances still using old version of the updated assembly. Restarting host instance(s) should easily take care of the problem. But I've often seen developers stuck in frustration. This can happen on large solutions with complex deployment structure with multiple applications, hosts and servers. Consider two servers BizTalk group where 3 applications are deployed. Each application uses its own host which in turn has two instances (one per server). In total we have 6 host instances in this group. When one of the applications is updated its host instances should be restarted without stopping other's applications hosts. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 9pt; FONT-FAMILY: Arial"&gt;If applications use the same adapters (i.e. File adapter) and if per application adapter hosts were not assigned then they will be sharing common host for send/receive operations and in most cases it will be default BizTalkApplicationHost. In this situation it's easy to miss restarting required host instance. To avoid this when sharing BizTalk group with multiple applications always assign your dedicated host for send and receive handlers and include corresponding host instances restart operation into post-deployment procedure. &lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 9pt; FONT-FAMILY: Arial"&gt;To create adapter host open Platform Settings/Adapters of the BizTalk group administration. Select adapter and add your host as new send and receive handler to adapter configuration. Then, in application configuration, go to send port or receive location properties and select your host from send or receive handler dropdown.&lt;o:p&gt;&lt;/o:p&gt;&lt;/span&gt;&lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=113043"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=113043" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/113043.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2007/06/06/113043.aspx</guid>
            <pubDate>Wed, 06 Jun 2007 18:22:13 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/113043.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2007/06/06/113043.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/113043.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/113043.aspx</trackback:ping>
        </item>
        <item>
            <title>The Daily WTF for Dummies</title>
            <category>Software Engineering</category>
            <link>http://geekswithblogs.net/paulp/archive/2007/05/29/112827.aspx</link>
            <description>&lt;p&gt;I don't know why &lt;a href="http://worsethanfailure.com"&gt;this site&lt;/a&gt; changed it's good ol' name from The Daily WTF to "politically correct" WorseThanFailure but I wouldn't do it in my case. I happen to perform code reviews on Java to .Net migration recently and in both I find enough "programming pearls" to keep me saying WTF every day for weeks. I thought about posting some of them and sharing the link with creators of such masterpieces as I may guess who's behind. They might get angry at me but it's for good to let them learn from their mistakes (if capable). &lt;/p&gt;
&lt;p&gt;There's a Russian book for children by Gregory Oster. The title translates like &lt;a href="http://www.amazon.com/Vrednye-sovety-Kniga-neposlushnykh-roditelei/dp/5853210173/ref=sr_1_1/102-2124632-9039339?ie=UTF8&amp;amp;s=books&amp;amp;qid=1180466786&amp;amp;sr=1-1"&gt;Harmful Advice for Naughty Children and Their Parents&lt;/a&gt;. Unfortunately, it's not been translated in English yet. It's filled with sarcastic rhymes and stories that will make your abs sore of laughing. The only English reference to this book I found &lt;a href="http://maaskva.blogspot.com/2006/04/gregory-oster.html"&gt;is here&lt;/a&gt;. The book "teaches" kids to do bad things in quite humorous fashion.&lt;/p&gt;
&lt;p&gt;I compiled some "tips" from code reviews in the manner of "The Harmful Advice: For Lamer Programmers and Wannabies". Code is stripped and de-personated so no harm to business only to developer's ego perhaps:&lt;/p&gt;
&lt;p&gt;1. Whenever you use ADO.NET open as many DataReaders as possible and &lt;em&gt;do not close&lt;/em&gt; them when done. Better yet, open several of them in nested loops. It's OK to keep connections open, that's what connection pools for, right?&lt;/p&gt;
&lt;p&gt;2. When you get the data back in the DataReader, religiously check the data field for null:&lt;/p&gt;
&lt;pre&gt;    if(dataReader[0] != null)&lt;br /&gt;    { myVal = dataReader[0];&lt;br /&gt;    }&lt;/pre&gt;
&lt;p&gt;Sometimes, it's good to double check later down the road:&lt;/p&gt;
&lt;pre&gt;    if(myVal != null){}&lt;/pre&gt;
&lt;p&gt;It's all about defensive programming. And never trust DbNull and IsDbNull method of the DataReader.&lt;/p&gt;
&lt;p&gt;3. Don't rely on reference types (.NET), they are evil. In most important cases pass them using ref keyword:&lt;/p&gt;
&lt;pre&gt;    SomeMethod(int param1, string param2, ref SomeClass imfeelingspecial);&lt;/pre&gt;
&lt;p&gt;4. Value types in .Net are more useful than you'd think. On a good day they can pass your data in and out just as easy as reference types:&lt;/p&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;SomeStruct commonInfo = new SomeStruct();&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;commonInfo.Field = “Let's see.”;&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;o:p&gt;...&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;FoodProcessor proc = new FoodProcessor(commonInfo);&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;proc.MunchData(); //- munches data and re-assigns commonInfo fields&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;...&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;if(commonInfo.Field == "Expected Value From FoodProcessor")&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;{// &amp;lt;- lots of prayers needed to make it here!&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;else&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;{//- Doh! It always comes here anyways...&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;}&lt;/pre&gt;
&lt;p&gt;5.  Do not trust SQL select results, it's not always &lt;span style="FONT-SIZE: 9pt; FONT-FAMILY: Arial; mso-fareast-font-family: 'Times New Roman'; mso-ansi-language: EN-US; mso-fareast-language: EN-US; mso-bidi-language: AR-SA"&gt;obvious &lt;/span&gt;how many columns it returns. Make a habilt of checking the columns count in the resordset:&lt;font size="3"&gt;&lt;font face="Times New Roman"&gt;&lt;span style="mso-spacerun: yes"&gt;&lt;/span&gt;&lt;/font&gt;&lt;/font&gt; &lt;/p&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;string sqlQuery = "SELECT column1, column2, column3 from SomeTable WHERE column4 = " + someVal;&lt;span style="mso-spacerun: yes"&gt;                                 &lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;...                                     &lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt; &lt;/span&gt;if (reader.Read())&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;     &lt;/span&gt;int fcnt = reader.FieldCount;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;     &lt;/span&gt;if (fcnt &amp;gt;= 1)&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;     &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;         &lt;/span&gt;var1 = reader.GetString(0);&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;     &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;     &lt;/span&gt;if (fcnt &amp;gt;= 2)&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;     &lt;/span&gt;{&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;         &lt;/span&gt;var2 = reader.GetString(1);&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="mso-spacerun: yes"&gt;     &lt;/span&gt;}&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;}&lt;/pre&gt;
&lt;p&gt;6. For money calculation always use low precision floating data types:&lt;/p&gt;
&lt;pre style="MARGIN-LEFT: 0.5in"&gt;&lt;span style="COLOR: teal"&gt;Float&lt;/span&gt; itmPrice = &lt;span style="COLOR: blue"&gt;new&lt;/span&gt; &lt;span style="COLOR: teal"&gt;Float&lt;/span&gt;(getIn().getRecords(count).getItemPrice());&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre style="MARGIN-LEFT: 0.5in"&gt;&lt;span style="COLOR: teal"&gt;Float&lt;/span&gt; itmQty = &lt;span style="COLOR: blue"&gt;new&lt;/span&gt; &lt;span style="COLOR: teal"&gt;Float&lt;/span&gt;(getIn().getRecords(count).getItemQuantity());&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre style="MARGIN-LEFT: 0.5in"&gt;&lt;span style="COLOR: blue"&gt;float&lt;/span&gt; exPrice = itmPrice.floatValue() * itmQty.floatValue();&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;pre style="MARGIN-LEFT: 0.5in"&gt;extendPrice = extendPrice.valueOf(exPrice);&lt;o:p&gt;&lt;/o:p&gt;&lt;/pre&gt;
&lt;p&gt;So, in this Java example, for itmPrice = 2.66 and itmQty=995 you will get a nice special price of 2646.7002. Decimal arithmetic is for pedants.&lt;/p&gt;
&lt;p&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font face="Arial" color="#000000"&gt;7. Always warm up the CPU before performing date calculations. This can be achieved by using many variables of different types and converting them back in forth to each other:&lt;/font&gt;&lt;/span&gt;&lt;/p&gt;
&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;Calendar myCal = Calendar.getInstance();&lt;span style="mso-tab-count: 8"&gt;    &lt;/span&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;span style="mso-tab-count: 8"&gt;&lt;/span&gt;&lt;font color="#000000"&gt;      myCal.setTime(myDate);&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 13"&gt;      &lt;/span&gt;Float fltTermNbr = new Float(newSrvcTerm);&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;Float sevenDays = new Float("7");&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;float fltTermNbrInDays = fltTermNbr.floatValue() * sevenDays.floatValue();&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;String strTermNbrInDays = "";&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;strTermNbrInDays = strTermNbrInDays.valueOf(fltTermNbrInDays);&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;strTermNbrInDays = strTermNbrInDays.substring(0, strTermNbrInDays.indexOf("."));&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;Integer IntegerTermNbrInDays = new Integer(strTermNbrInDays);&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;int intTermNbrInDays = IntegerTermNbrInDays.intValue();&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="MsoNormal" style="MARGIN: 0in 0in 0pt"&gt;&lt;span style="FONT-SIZE: 10pt; COLOR: teal; FONT-FAMILY: 'Courier New'"&gt;&lt;font color="#000000"&gt;&lt;span style="mso-tab-count: 1"&gt;      &lt;/span&gt;myCal.add(myCal.DAY_OF_YEAR, intTermNbrInDays);&lt;o:p&gt;&lt;/o:p&gt;&lt;/font&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;p&gt;&lt;font face="Arial" color="#000000"&gt;Just for us, lazy ones, all the Java code above is trying to do is:&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial" color="#000000"&gt;             int termNbrInDays = Convert.ToInt32(newSrvcTerm) * 7;&lt;br /&gt;
             myDate = myCal.AddDays(myDate, termNbrInDays);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font face="Arial" color="#000000"&gt;Still suck at writing bad code? Consider a mentor. Hire a developer with the thickest resume and largest amount keywords in it. At the end, one must be really hardworking to create one. Give him a title he wants: usually Lead Architect or something like this. Let him write the code and teach others. Well, I have to go back and dig up some more jewels...&lt;/font&gt;&lt;/p&gt;
&lt;/span&gt;
&lt;p&gt; &lt;/p&gt;
&lt;p&gt; &lt;/p&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=112827"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=112827" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/112827.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2007/05/29/112827.aspx</guid>
            <pubDate>Tue, 29 May 2007 22:51:22 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/112827.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2007/05/29/112827.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/112827.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/112827.aspx</trackback:ping>
        </item>
        <item>
            <title>Evektor SportStar Checkout</title>
            <category>Aviation</category>
            <link>http://geekswithblogs.net/paulp/archive/2007/05/24/112716.aspx</link>
            <description>&lt;div&gt;
&lt;p&gt;I recently got checked out in &lt;a href="http://www.evektoramerica.com/sportstarplus.htm"&gt;Evektor SportStar&lt;/a&gt;. It's a two seat Czech built light sport airplane that becoming increasingly popular with the new &lt;a href="http://www.sportpilot.org/"&gt;sport pilot&lt;/a&gt; rules. I've been wanting to try it out for a long time but it's so popular that's always busy flying and booked well ahead. Apparently, many jumped on the sport pilot bandwagon as it's cheaper and faster way to get up in the air. At the same time some folks saving money during regular private pilot training as SportStar's hourly rental rate is lower than Cessna 172 and comparable to Cessna 150/152.&lt;/p&gt;
&lt;p&gt;The preflight is simple and includes all typical checkpoints for 2-4 seat trainer airplane. The geared liquid cooled engine adds checking coolant level step. During preflight I noticed good quality construction and excellent fit and finish. The cockpit has adequate shoulder room and bubble canopy has plenty of headroom for over 6' pilot. In Texas heat though this greenhouse will fry you in no time, so keep it open as long as possible. Seats are firm and comfortable all controls are laid out well and within hands reach. Manual flaps extension handle is between seats and flaps position can be verified by the handle position only as the flaps are not visible due to wing design. Headset jacks located on the panel behind the seats and slightly to the right which all makes favorable condition for tangling headset wires with 5-point seatbelt harness.&lt;/p&gt;
&lt;p&gt;Starting engine is very simple and once it's on there's only one throttle handle to operate, no mixture here. The vernier throttle control is something to get used to after Cessna's plunger type. I always wondered why all aircraft have such different user interfaces: panel layouts, control levers, switches grouping and locations etc. Why don't they create a few standards for critical controls. It would make pilot transition into new cockpits much easier and reduce workload especially during critical situations when motor reactions kick in. Anyways, the vernier lever must be twisted to smoothly adjust engine RPM (clockwise to increase ) and for abrupt changes can be moved back and forth after releasing the lock button. Almost as mixture control in Cessnas but loaded with push-in spring. The spring pushes throttle in pretty strong and engine response is quick, so be on your toes. And we complain about confusing UI in software. :)&lt;/p&gt;
&lt;p&gt;Take-off roll is pretty easy, it doesn't require as much right rudder input as 172. Also, nose wheel is connected with rudder by rods so it's very sensitive comparing to mushiness of Cessnas. That makes one more transition gotcha from Cessna as you don't expect it react so quickly and can start yawing left and right during take-off roll. The trick is in quick smaller rudder inputs. Once at rotation speed it will lift off itself with just a hint of back pressure on the stick. &lt;/p&gt;
&lt;p&gt;Once in the air - it's fun. The visibility is outstanding: high seating position, low cut sides, small engine cowl and all around glass canopy makes you like flying in the soap bubble. Steep turns are easy and stalls are non-event  -  it's just mushing around and sinks without noticeable wing drop tendency. No stall warning though, so watch your airspeed. Speaking of which it was about 40 kts when it decided to stall and I observed 95kts at 4500 rpm at cruise. I wish it had better radios, they suck in this airplane, constantly picking interference from TV towers or some other sources. Old Cessna's radios don't do that.&lt;/p&gt;
&lt;p&gt;Landing was where I had most difficulties. The light weight makes it even less stable in turbulence than Cessna 150. And after 172 I had a tendency to overcontrol because of SportStar responsive controls. The throttle handle didn't help either and I was behind in making power adjustments. Geared engine RPMs are not the same numbers as for direct drive motors and it took time to find right approach power setting first times. It has three flaps settings: 15, 30 and 50 degrees. At 50 it makes quite steep approach and sinks fast when you loose speed. I used it twice but think it's better kept for short field landings. Most of the landings I've done with flaps at 30 and it worked best making it similar to 30 degrees flaps approahes in Cessna's.   Flaring is easy as long as you get new sight picture. The rollout was tricky due to it's highly sensitive nose wheel -  it can easily lead into pilot induced oscillation. Crosswind landing is different too as SportStar has a little wing clearance that limits amount of allowed wing drop in a side slip. This essentially dictates crab all the way to touchdown and kick-in the rudder in the last moment. Once rolling on mains keep the nose wheel off and don't forget to straighten it before it touches runway - it can take you to the boonies.&lt;/p&gt;
&lt;p&gt;Once all of transition's trouble areas have been addressed the fun begins. It's nice vroom-vroom airplane for sightseeing and local trips. Makes a good trainer too I guess. It's new, comfortable, responsive, looks great in the air and on the ramp and easier on the wallet while building time (5gph fuel flow). It's good to see FBOs coming to understand the value of light sport planes and hope it will keep flying affordable.&lt;/p&gt;
&lt;p&gt;&lt;img alt="" src="http://geekswithblogs.net/images/geekswithblogs_net/paulp/4383/o_CIMG1728.JPG" /&gt;&lt;/p&gt;
&lt;/div&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=112716"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=112716" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/paulp/aggbug/112716.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>Paul Petrov</dc:creator>
            <guid>http://geekswithblogs.net/paulp/archive/2007/05/24/112716.aspx</guid>
            <pubDate>Thu, 24 May 2007 16:19:47 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/paulp/comments/112716.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/paulp/archive/2007/05/24/112716.aspx#feedback</comments>
            <slash:comments>18</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/paulp/comments/commentRss/112716.aspx</wfw:commentRss>
            <trackback:ping>http://geekswithblogs.net/paulp/services/trackbacks/112716.aspx</trackback:ping>
        </item>
    </channel>
</rss>