<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://aspiring-technology.com/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>LINQed IN - Troy Magennis' View on .NET, C# and Software Development</title><link>http://aspiring-technology.com/blogs/troym/default.aspx</link><description /><dc:language>en-US</dc:language><generator>CommunityServer 2.0 (Build: 60210.2610)</generator><item><title>Server Virtualization - Go Green!</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/05/13/2362.aspx</link><pubDate>Tue, 13 May 2008 16:18:19 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:2362</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/2362.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=2362</wfw:commentRss><description>&lt;p&gt;The company I work hosts a decent size data center to support its business (a website hitting around 1.5Mil hits a day, and countless business applications to keep the company in business). Around the end of last year our backup-power (UPS') and air-conditioning were hitting the alarming 90% level (this is understated!).&lt;/p&gt;  &lt;p&gt;The issue wasn't the number of production servers, but rather the pre-production servers for Development, Testing and Staging. Replicating the rather large interconnected complex environment took hundreds of servers, all at 5% CPU utilization most times during the month!&lt;/p&gt;  &lt;p&gt;&lt;strong&gt;Our Savior: Server virtualization&lt;/strong&gt;&lt;/p&gt;  &lt;p&gt;Just by converting as many pre-production servers to virtual instances and hosting these on decent machines, we saw a reduction to below 45% capacity. The additional benefit is that many of these machines were hosted on poor, unstable hardware previously - virtualized, these are running on solid hardware and in many cases perform better than they did.&lt;/p&gt;  &lt;p&gt;If every company house that has software development and testing server resources virtualized their pre-production environments imagine how much less power our server rooms would consume. That has got to be better for the financial operating cost and also better for the environment in general!&lt;/p&gt;  &lt;p&gt;Troy.&lt;/p&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=2362" width="1" height="1"&gt;</description></item><item><title>.NET 3.5 Enhancements Training Kit</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/04/17/2283.aspx</link><pubDate>Thu, 17 Apr 2008 12:40:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:2283</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/2283.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=2283</wfw:commentRss><description>&lt;P&gt;A comprehensive set of hands on labs and training material has been release for a number of .NET 3.5 Enhancements by the Visual Studio &amp;amp; .NET Framework evangelism team. Nice work guys.&lt;/P&gt;
&lt;P&gt;"&lt;SPAN&gt;The .NET Framework 3.5 Enhancements Training Kit includes presentations, hands-on labs, and demos. This content is designed to help you learn how to utilize the .NET 3.5 Enhancement features including: &lt;/SPAN&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;SPAN&gt;ASP.NET MVC, &lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;ASP.NET Dynamic Data, &lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;ASP.NET AJAX History, &lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;ASP.NET Silverlight controls, &lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;ADO.NET Data Services&lt;/SPAN&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;SPAN&gt;ADO.NET Entity Framework."&lt;/SPAN&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;SPAN&gt;You can &lt;A href="http://www.microsoft.com/downloads/details.aspx?FamilyID=355c80e9-fde0-4812-98b5-8a03f5874e96&amp;amp;displaylang=en"&gt;download it from here&lt;/A&gt;.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Troy.&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=2283" width="1" height="1"&gt;</description></item><item><title>Software Architect - The Test Kitchen for your Company</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/04/10/2241.aspx</link><pubDate>Thu, 10 Apr 2008 10:52:25 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:2241</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/2241.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=2241</wfw:commentRss><description>&lt;p&gt;I've become a fan of &lt;a href="http://americastestkitchen.com/" target="_blank"&gt;America's Test Kitchen&lt;/a&gt;, a TV and book series about cooking, where they not only show how to cook a great Pork roast, they will try it 10 different ways and see which one works best. They end simply by describing the best way (decided by a set of tasters normally) and publish that recipe with a pre-amble about all of the disasters.&lt;/p&gt;  &lt;p&gt;It occurred to me that when describing what a Software Architect does to non-technical people, I might start by saying &amp;quot;I'm the test kitchen for software development in my company; I try to solve a problem in numerous ways and then describe the one that worked best.&amp;quot;&lt;/p&gt;  &lt;p&gt;I see a lot of Architects unable to get their hands dirty in code; How do they really understand a new technology unless they are able to cook the perfect integration pattern in their favorite kitchen: Visual Studio 2008! I think what America's Test Kitchen does right is they document the process really well - what worked, what didn't and why. I know my Red Wine Sauce has improved immensely by using their books; If I could just communicate to my team why my Service Software Factory was designed the way it is!&lt;/p&gt;  &lt;p&gt;Troy.&lt;/p&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=2241" width="1" height="1"&gt;</description></item><item><title>AForge - Image, Math, Vision, Neuro and Computer Learning Libraries</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/04/09/2233.aspx</link><pubDate>Wed, 09 Apr 2008 21:20:57 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:2233</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/2233.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=2233</wfw:commentRss><description>&lt;p&gt;I'm probably the last to know, but I had a real need for some solid imaging and graphic library source code. I was incredibly impressed with the AForge library by Andrew K&lt;a href="http://code.google.com/u/andrew.kirillov/"&gt;irillov&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;Get the source and library here: &lt;a href="http://code.google.com/p/aforge/" target="_blank"&gt;AForge on code.google.com&lt;/a&gt;&lt;/p&gt;  &lt;blockquote&gt;   &lt;p&gt;&lt;strong&gt;AForge.NET&lt;/strong&gt; is a C# framework designed for developers and researchers in the fields of Computer Vision and Artificial Intelligence - image processing, neural networks, genetic algorithms, machine learning, etc. &lt;/p&gt;    &lt;p&gt;At this point the framework is comprised of 5 main and some additional libraries: &lt;/p&gt;    &lt;ul&gt;     &lt;li&gt;&lt;strong&gt;AForge.Imaging&lt;/strong&gt; &amp;#8211; a library for image processing routines and filers; &lt;/li&gt;      &lt;li&gt;&lt;strong&gt;AForge.Neuro&lt;/strong&gt; &amp;#8211; neural networks computation library; &lt;/li&gt;      &lt;li&gt;&lt;strong&gt;AForge.Genetic&lt;/strong&gt; &amp;#8211; evolution programming library; &lt;/li&gt;      &lt;li&gt;&lt;strong&gt;AForge.Vision&lt;/strong&gt; &amp;#8211; computer vision library; &lt;/li&gt;      &lt;li&gt;&lt;strong&gt;AForge.Machine Learning&lt;/strong&gt; &amp;#8211; machine learning library. &lt;/li&gt;   &lt;/ul&gt; &lt;/blockquote&gt;  &lt;p&gt;Releases are frequent; The code clearly written; Good samples - all round a great project. Nice work to all those involved.&lt;/p&gt;  &lt;p&gt;Troy.&lt;/p&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=2233" width="1" height="1"&gt;</description></item><item><title>Tips for WinForms Memory and Painting Debugging</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/04/09/2231.aspx</link><pubDate>Wed, 09 Apr 2008 21:04:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:2231</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/2231.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=2231</wfw:commentRss><description>&lt;P&gt;Every now and then I come across a Windows Forms application that has memory leak, or graphic resource leak issues. In managed environments like .NET, some developers overlook that many components wrap un-managed finite resources.&amp;nbsp; I worked with a fellow developer Mike Zhang today, and because of the difficulties in replicating the issue, we decided that a full pass through the entire source code fixing these issues was our best shot at solving a niggling production issue. After today, here are our top 4 tips and the first steps to ensuring you have a well behaved Windows Forms .NET application.&lt;/P&gt;
&lt;P&gt;&lt;B&gt;Begin Update / End Update (Blank, unpainted regions of the screen)&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;Many Windows controls have a BeginUpdate and EndUpdate methods. These inhibit any Paint events being called when a lot of data is being added to a ListView for example. Big trouble occurs if an EndUpdate isn’t called matching a BeginUpdate! Most general case, is an exception occurs after the begin, but before the EndUpdate gets called.&lt;/P&gt;
&lt;P&gt;&lt;U&gt;To Fix&lt;/U&gt;: Do a solution wide search for “BeginUpdate”; Go through the result list (yes, EVERY one of them) and ensure that a the EndUpdate is wrapped in a Finally block.&lt;/P&gt;
&lt;P&gt;BAD&lt;/P&gt;
&lt;DIV class=csharpcode&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   1:  &lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;this&lt;/SPAN&gt;.BeginUpdate();&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   2:  &lt;/SPAN&gt;&lt;SPAN class=rem&gt;// lots of work, including work that may throw an exception!&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   3:  &lt;/SPAN&gt;&lt;SPAN class=rem&gt;// ...&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   4:  &lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;this&lt;/SPAN&gt;.EndUpdate();&lt;/PRE&gt;&lt;/DIV&gt;
&lt;P&gt;GOOD&lt;/P&gt;
&lt;DIV class=csharpcode&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   1:  &lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;this&lt;/SPAN&gt;.BeginUpdate();&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   2:  &lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;try&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   3:  &lt;/SPAN&gt;{&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   4:  &lt;/SPAN&gt;     &lt;SPAN class=rem&gt;// lots of work, including work that may throw an exception!&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   5:  &lt;/SPAN&gt;}&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   6:  &lt;/SPAN&gt;&lt;SPAN class=kwrd&gt;finally&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   7:  &lt;/SPAN&gt;{&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   8:  &lt;/SPAN&gt;    &lt;SPAN class=rem&gt;// EndUpdate called even in the case of an Exception in the lots of work above.&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   9:  &lt;/SPAN&gt;    &lt;SPAN class=kwrd&gt;this&lt;/SPAN&gt;.EndUpdate();&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;  10:  &lt;/SPAN&gt;}&lt;/PRE&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;B&gt;Pen, Brush and Graphic Resources (Resource leak)&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;Even in .NET, a lot of managed code uses unmanaged resources. These managed wrappers implement the IDisposible pattern, where the Dispose method nicely releases all unmanaged resources. However – What if Dispose doesn’t get called? Either because Garbage Collection in .NET is happens on its own non-deterministic timetable, some external reference keeps an object alive, or an exception occurs and Dispose is never called. This manifests itself as areas that don’t draw properly or have an enclosed red cross.&lt;/P&gt;
&lt;P&gt;&lt;U&gt;To Fix&lt;/U&gt;: Do a solution wide search for “Graphic ”, “Pen “ and “Brush “; Go through the result list (yes, EVERY one of them) and ensure that the scope of the Brush, Pen or Graphic is within a using clause, or a try/finally block.&lt;/P&gt;
&lt;P&gt;Read: "using" statement reference on MSDN: &lt;A href="http://msdn2.microsoft.com/en-us/library/yh598w02.aspx"&gt;http://msdn2.microsoft.com/en-us/library/yh598w02.aspx&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;BAD&lt;/P&gt;
&lt;DIV class=csharpcode&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   1:  &lt;/SPAN&gt;    Graphics g = Graphics.FromImage(sourceImage);&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   2:  &lt;/SPAN&gt;    Pen pen = &lt;SPAN class=kwrd&gt;new&lt;/SPAN&gt; Pen();&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   3:  &lt;/SPAN&gt;    &lt;SPAN class=rem&gt;// lots of work, including work that might fail&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   4:  &lt;/SPAN&gt;    g.DrawRectangle(pen, 10, 10, 100, 100);&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   5:  &lt;/SPAN&gt;    &lt;SPAN class=kwrd&gt;throw&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;new&lt;/SPAN&gt; Exception();&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   6:  &lt;/SPAN&gt;    pen.Dispose(); &lt;SPAN class=rem&gt;// never called&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   7:  &lt;/SPAN&gt;    g.Dispose(); // never called&lt;/PRE&gt;&lt;/DIV&gt;
&lt;P&gt;GOOD&lt;/P&gt;
&lt;DIV class=csharpcode&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   1:  &lt;/SPAN&gt;    &lt;SPAN class=kwrd&gt;using&lt;/SPAN&gt;(Graphics g = Graphics.FromImage(sourceImage))&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   2:  &lt;/SPAN&gt;    {&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   3:  &lt;/SPAN&gt;        &lt;SPAN class=kwrd&gt;using&lt;/SPAN&gt;(Pen pen = &lt;SPAN class=kwrd&gt;new&lt;/SPAN&gt; Pen())&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   4:  &lt;/SPAN&gt;        {&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   5:  &lt;/SPAN&gt;            &lt;SPAN class=rem&gt;// lots of work, including work that might fail&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   6:  &lt;/SPAN&gt;            g.DrawRectangle(pen, 10, 10, 100, 100);&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   7:  &lt;/SPAN&gt;            &lt;SPAN class=kwrd&gt;throw&lt;/SPAN&gt; &lt;SPAN class=kwrd&gt;new&lt;/SPAN&gt; Exception();&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   8:  &lt;/SPAN&gt;         } &lt;SPAN class=rem&gt;// calls pen.Dispose() in all cases&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE&gt;&lt;SPAN class=lnum&gt;   9:  &lt;/SPAN&gt;    } &lt;SPAN class=rem&gt;// calls g.Dispose() in ALL cases&lt;/SPAN&gt;&lt;/PRE&gt;&lt;/DIV&gt;
&lt;P&gt;&lt;B&gt;Manual Event Wiring Up and Object Lifetime (memory and resource leak)&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;This is without a doubt the most common (and some say only common) memory leak on .NET applications. If your component subscribes to an event in &lt;U&gt;ANOTHER&lt;/U&gt; component or class, you must –&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;a) Unhook yourself in your Dispose method for the form or class you subscribed FROM&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;b) Avoid multiple hookups to an event if your form is opened, or called multiple times&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;Tips:&lt;/P&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;a) Hookup events using the Forms designer when possible; This automatically handles events in the proper way&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;b) To be sure multiple hookups don’t accidently occur, remove yourself from an event before hooking your event up (this is safe, even the first time) – &lt;BR&gt;&lt;BR&gt;BAD &lt;BR&gt;ValidationGlobalManager.OnValidate += &lt;SPAN class=kwrd&gt;new&lt;/SPAN&gt; My ValidationHandler(MyValidationFunction); &lt;/P&gt;
&lt;P&gt;&lt;BR&gt;GOOD &lt;BR&gt;&amp;nbsp; ValidationGlobalManager.OnValidate -= new My ValidationHandler(MyValidationFunction); &lt;BR&gt;&amp;nbsp; ValidationGlobalManager.OnValidate += new My ValidationHandler(MyValidationFunction);&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;BLOCKQUOTE&gt;
&lt;P&gt;c) If you hook up an event outside of InitializeComponent (i.e. NOT through the forms designer), then YOU are responsible for unhooking your event in the Dispose() method of your form.&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;B&gt;OnPaint and OnDraw Event Handlers - Call the base. implementation in all cases (unpredictable drawing behavior)&lt;/B&gt;&lt;/P&gt;
&lt;P&gt;Many controls allow you to implement your own OnDraw and OnPaint event handlers. However, the base.OnDraw(); or base.OnPaint(); methods MUST be called under all conditions, even in the case your code fails with an exception.&lt;/P&gt;
&lt;P&gt;&lt;U&gt;To Fix&lt;/U&gt;: Do a solution wide search for “OnDraw ” and “OnPaint“; Go through the result list (yes, EVERY one of them) and ensure that &lt;/P&gt;
&lt;P&gt;a) the base call is first, so it always runs, OR&lt;/P&gt;
&lt;P&gt;b) the base call is protected with a try/finally block&lt;/P&gt;
&lt;P&gt;Mike and Troy.&lt;/P&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=2231" width="1" height="1"&gt;</description></item><item><title>LINQ Reference Mug and Mousemat</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/02/08/1857.aspx</link><pubDate>Fri, 08 Feb 2008 21:05:01 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1857</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1857.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1857</wfw:commentRss><description>&lt;p&gt;I put together a mug and mouse-mat design with LINQ Reference information. I wanted to have a list of the standard query operators and the new C# Query Expression Syntax on hand at all times. My only concern is spilling coffee over the keyboard when looking up the "Join" syntax reference!&lt;/p&gt; &lt;p&gt;&lt;a href="http://www.hookedonlinq.com/LINQReferenceStuff.ashx"&gt;&lt;img height="104" alt="combo_mug_front" src="http://aspiring-technology.com/blogs/troym/images/LINQReferenceMugandMousemat_10C57/combo_mug_front.jpg" width="104" border="0"&gt;&lt;/a&gt; &lt;a href="http://www.hookedonlinq.com/LINQReferenceStuff.ashx"&gt;&lt;img height="104" alt="combo_mug_back" src="http://aspiring-technology.com/blogs/troym/images/LINQReferenceMugandMousemat_10C57/combo_mug_back.jpg" width="104" border="0"&gt;&lt;/a&gt; &lt;a href="http://www.hookedonlinq.com/LINQReferenceStuff.ashx"&gt;&lt;img height="104" alt="sqo_mousepad" src="http://aspiring-technology.com/blogs/troym/images/LINQReferenceMugandMousemat_10C57/sqo_mousepad.jpg" width="104" border="0"&gt;&lt;/a&gt; &lt;/p&gt; &lt;p&gt;They take information from the &lt;a href="http://www.hookedonlinq.com/"&gt;HookedOnLINQ&lt;/a&gt; Wiki website, and you can buy them for $14.99 if you think they might be useful.&lt;/p&gt; &lt;p&gt;&lt;a href="http://www.cafepress.com/linq.225122905" target="_blank"&gt;Buy a LINQ SQO and Query Expression for $14.99 + shipping&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;a href="http://www.cafepress.com/linq.225123673" target="_blank"&gt;Buy a LINQ SQO Mousemat for $14.99&lt;/a&gt;&lt;/p&gt; &lt;p&gt;I don't have a VB equivalent yet, and I'd be interested if anyone has ideas for improving them or can point out errors or omissions.&lt;/p&gt; &lt;p&gt;Troy.&lt;/p&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1857" width="1" height="1"&gt;</description></item><item><title>CodeCamp Seattle Notes</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/01/31/1744.aspx</link><pubDate>Thu, 31 Jan 2008 22:28:18 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1744</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1744.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1744</wfw:commentRss><description>&lt;p&gt;I was fortunate enough to attend &lt;a href="https://seattle.codecamp.us/"&gt;Code Camp in Seattle&lt;/a&gt; last weekend. It was great to see the event attended by around 300 keen developers.&lt;/p&gt; &lt;p&gt;I took notes throughout some sessions, and posted full details the &lt;a href="http://www.hookedonlinq.com"&gt;HookedOnLINQ&lt;/a&gt;.com website.&lt;/p&gt; &lt;p&gt;&lt;b&gt;&lt;a href="http://www.hookedonlinq.com/AllPages.aspx?SortBy=User&amp;amp;Cat=CodeCamp"&gt;&lt;/a&gt;&lt;/b&gt; &lt;ul&gt; &lt;li&gt;&lt;a href="http://www.hookedonlinq.com/EntityFrameworkCodeCamp.ashx"&gt;Entity Framework Notes from CodeCamp Seattle&lt;/a&gt;&lt;/li&gt; &lt;li&gt;&lt;a href="http://www.hookedonlinq.com/PLINQCodeCamp.ashx"&gt;Parallel LINQ CodeCamp Seattle Notes&lt;/a&gt;&lt;/li&gt; &lt;li&gt;&lt;a href="http://www.hookedonlinq.com/UnitTestingCodeCamp.ashx"&gt;Rethinking Unit Testing Codecamp Seattle Notes&lt;/a&gt;&lt;/li&gt; &lt;li&gt;&lt;a href="http://www.hookedonlinq.com/SilverlightCodeCamp.ashx"&gt;SilverLight Notes from CodeCamp Seattle&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt; &lt;p&gt;By far, the Parallel LINQ session was a standout. I was surprised just how cleanly the &lt;a href="http://blogs.msdn.com/pfxteam/"&gt;ParallelFx&lt;/a&gt; team have committed to making multiple processor development mainstream. This is a library and feature set that is important to watch. &lt;p&gt;Troy.&lt;/p&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1744" width="1" height="1"&gt;</description></item><item><title>Choosing between LINQ to SQL and LINQ to Entities</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/01/30/1740.aspx</link><pubDate>Wed, 30 Jan 2008 20:59:01 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1740</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1740.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1740</wfw:commentRss><description>&lt;p&gt;I've been fielding questions on this topic and struggled for a cohesive answer. Should some people wait until LINQ to Entities and the ADO.NET Entity framework is shipped or go LINQ to SQL now?&lt;/p&gt; &lt;p&gt;I saw on &lt;a href="http://blogs.msdn.com/kaevans/archive/2008/01/29/linq-to-sql-vs-linq-to-entities-smackdown.aspx"&gt;Kirk Allen Evan's Blog&lt;/a&gt; a pointer to a MSDN Article on this very question.&lt;/p&gt; &lt;p&gt;&amp;nbsp;&lt;a href="http://msdn2.microsoft.com/en-us/library/cc161164.aspx"&gt;Introducing LINQ to Relational Data&lt;/a&gt;&lt;/p&gt; &lt;p&gt;&lt;b&gt;Summary:&lt;/b&gt; This article introduces two implementations of LINQ, LINQ to SQL and LINQ to Entities, and the key scenarios for which each was designed. (19 printed pages)  &lt;p&gt; - Troy.&lt;/p&gt; &lt;div class="wlWriterSmartContent" id="scid:0767317B-992E-4b12-91E0-4F059A8CECA8:34d71b4d-7ad0-4706-aab2-abd1b774d68e"&gt;Technorati tags: &lt;a href="http://technorati.com/tags/LINQ" rel="tag"&gt;LINQ&lt;/a&gt;, &lt;a href="http://technorati.com/tags/LINQ%20to%20SQL" rel="tag"&gt;LINQ to SQL&lt;/a&gt;, &lt;a href="http://technorati.com/tags/LINQ%20to%20Entities" rel="tag"&gt;LINQ to Entities&lt;/a&gt;&lt;/div&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1740" width="1" height="1"&gt;</description></item><item><title>Prioritizing and Assigning Scale to Feature Lists and Bugs Efficiently</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/01/16/PrioritizingEfficiently.aspx</link><pubDate>Wed, 16 Jan 2008 15:14:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1657</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1657.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1657</wfw:commentRss><description>Sorting, prioritizing or ordering features and business
objectives (or tasks, or bugs, etc) with a large group of stakeholders can be
painful. Often the loudest voice in the room gets there way; some people just
sit in the corner too scared to raise their objections. After sitting through
many of these, I thought I’d post some ideas for improving the experience,
accuracy and interaction –

&lt;ol&gt;&lt;li&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;Do a quick read through of all the items to set
the room to a common definition and understanding of the terms and items being
discussed&lt;/li&gt;&lt;li&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;Clearly post the definition of each scale on a
poster/whiteboard in clear view. If you are the moderator stand near it to
re-affirm the definitions during discussion&lt;/li&gt;&lt;li&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;&lt;span&gt;&lt;/span&gt;People
can assign the boundary conditions quicker than the middle territory. Often a
quick pass through the list solely to assign the top rating or the bottom
rating (in, out, will, won’t, etc). This process also warms the group up and
gets the blood flowing. It is important that if there is ANY dissent, that item
be skipped&lt;/li&gt;&lt;li&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;The moderator should keep an eye on if someone
isn’t contributing and focus a question for opinion in that person’s direction
when the domain would suit (especially if it is an “obvious” yes or no). This
is also a way of making sure a dominant personality gets slowed down in driving
an agenda&lt;/li&gt;&lt;li&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;People get better at the process through
experience. At regular intervals, revisit a subset and ascertain the group
still feels the same way&lt;/li&gt;&lt;li&gt;&lt;span&gt;&lt;span&gt;&lt;span&gt;&amp;nbsp;&lt;/span&gt;&lt;/span&gt;&lt;/span&gt;After each break (at least every 1 hour),
re-evaluate the last few items to “re-synch” people’s barometer. Depending on
the time of day or the day of the week (or the amount of caffeine here in
Seattle) – people can change their votes&lt;/li&gt;&lt;/ol&gt;











&lt;p class="MsoNormal"&gt;The prioritization process is absolutely central to any
agile process. Making sure you get accurately reflected priorities with large
group can be very challenging. &lt;/p&gt;

&lt;p class="MsoNormal"&gt;Troy.&lt;/p&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1657" width="1" height="1"&gt;</description><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1012.aspx">Software Development</category></item><item><title>Lean Architecture - How much up-front architecture is needed in a Agile project?</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/01/13/LeanArchitecture.aspx</link><pubDate>Sun, 13 Jan 2008 19:43:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1650</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1650.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1650</wfw:commentRss><description>&lt;P&gt;How much up-front design or architecture to do in an agile project is always a contentious issue. Having the job title with "Architect" in it makes me personally biased;&amp;nbsp;Having a background as a developer and product manager in&amp;nbsp;successful agile XP gives me a huge respect for agile development practices and somewhat balances my development approach. This posting tries to define my current view on how to balance good up-front architectural planning (minimal, but where it counts) and how to assess whether more or less architectural oversight needs to be applied during a project through intervention.&lt;/P&gt;
&lt;P&gt;Many agile scenarios promote that a project be split in a set of features; These features prioritized into milestones by the "Customer" and then these features be worked in in almost a serialized fashion. The focus is on completing the current feature, whilst&amp;nbsp;promoting that refactoring&amp;nbsp;be the tool of choice when a later feature adds or alters a previously signed-off complete and closed item.&lt;/P&gt;
&lt;P&gt;I can see some issues with this when followed blindly. My definition of "Refactoring" centers on improving currently functional code with lessons that emerge throughout a project. What I see in many projects is that "Refactoring" is the title given to an almost rewriting of a previously closed feature because the number and scope of changes to keep it operating in the face of the new feature. This is bad, and it is seriously affecting development velocity.&lt;/P&gt;
&lt;P&gt;Here is my proposed compromise, that allows features to be built in (semi)-ignorance of future features, whilst still allowing for intervention if a pattern of serious re-writing (or refactoring if you want to water the terminology&amp;nbsp; down) begins to affect velocity -&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Up-front architecture that should always be carried out as iteration 0 of any project includes anything that WILL BE NEEDED for EVERY feature (or requirements that will cause a registration of almost every feature that has already been completed). This includes technology choices, communication and integration patterns, operational requirements like logging, deployment strategy and localization requirements can be used as a starting list. 
&lt;LI&gt;&lt;STRONG&gt;At regular intervals (e.g. 1/4, 1/3, 1/2, 2/3, 3/4) of the way through features in a project analyze the task breakdowns of the latter features to determine if there is a class of task that might be eliminated by an architectural building block or by more holistic design/planning&lt;/STRONG&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;It is the second bullet point I want to discuss further in this posting.&lt;/P&gt;
&lt;P&gt;My boss &lt;A href="http://www.agilemanagement.net"&gt;David Anderson&lt;/A&gt; run a pretty tight Lean Software software development department. A lot of the lean principles are facilitated by using a &lt;A href="http://en.wikipedia.org/wiki/Kanban"&gt;Kanban&lt;/A&gt; tracking system (and its electronic counterpart being the data captured in Microsoft TFS). The data captured is very thorough and used as a management tool in determining progress, bottlenecks and general project health. &lt;STRONG&gt;My goal is to use the feature and tasks completed so far to assist in determining where architectural intervention or more up-front planning could avoid that class of task being necessary in future work.&lt;/STRONG&gt; &lt;/P&gt;
&lt;P&gt;Lets look at an example - In a current project that is very integration heavy with a large ERP/CRM system, that our lack of solid planning for the interface specifications (which weren't ready when we started, but are available now) is cause way too much rework as we move through the features in a linear fashion. It way pay dividends in team velocity to introduce a feature right now that looks at the spectrum of interface specifications we now have and strawman the entire message / web service interfaces. If this reduces the number of tasks in future feature that would have revisited completed interfaces and added that extra field, or changed that database schema - improved velocity is inevitable.&lt;/P&gt;
&lt;P&gt;&lt;STRONG&gt;But there is a balance - striving for perfection in this planning intervention would also be catastrophic to feature completion velocity. Going overboard with architecture is just as evil as sticking ones head in the sand and simply working longer hours or hiring more developers to close the backlog gap.&lt;/STRONG&gt;&lt;/P&gt;
&lt;P&gt;Be interested if other teams have analyzed task types to look for patterns or work that might be eliminated by a targeted architectural focus.&lt;/P&gt;
&lt;P&gt;Troy.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;DIV class=wlWriterSmartContent id=0767317B-992E-4b12-91E0-4F059A8CECA8:4eed3edf-8f74-45b2-a793-93c4fcfa1561&gt;Technorati tags: &lt;A href="http://technorati.com/tags/Software%20Architecture" rel=tag&gt;Software Architecture&lt;/A&gt;, &lt;A href="http://technorati.com/tags/Software%20Development" rel=tag&gt;Software Development&lt;/A&gt;, &lt;A href="http://technorati.com/tags/Kanban" rel=tag&gt;Kanban&lt;/A&gt;, &lt;A href="http://technorati.com/tags/David%20Anderson" rel=tag&gt;David Anderson&lt;/A&gt;&lt;/DIV&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1650" width="1" height="1"&gt;</description><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1011.aspx">Software Architecture</category><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1012.aspx">Software Development</category></item><item><title>How Many Languages Do You Need to Build a Website?</title><link>http://aspiring-technology.com/blogs/troym/archive/2008/01/10/HowManyLanguagesToBuildAWebsite.aspx</link><pubDate>Thu, 10 Jan 2008 22:59:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1643</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1643.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1643</wfw:commentRss><description>&lt;P&gt;Answer: &amp;gt; 6&lt;/P&gt;
&lt;P&gt;I was looking at a prototype web project today. The one point that struck me was the number of languages and different technologies that were used in assembling a solution:&lt;/P&gt;
&lt;P&gt;Cleint Side -&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;HTML for the page templates&lt;/LI&gt;
&lt;LI&gt;CSS for the stylesheets&lt;/LI&gt;
&lt;LI&gt;JavaScript for the client side interactive code (and understand the browser compatibility differences when coding)&lt;/LI&gt;
&lt;LI&gt;AJAX toolkit of your choice (still JavaScript, but you need to learn the intricacies of the one you are using)&lt;/LI&gt;
&lt;LI&gt;Flash or&amp;nbsp;Silverlight for embedded interactive animations, streaming video, or rich media element&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;Server Side (this is technology choice dependent) -&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;Ruby or&amp;nbsp;C# or&amp;nbsp;Java&amp;nbsp;for the server side code&lt;/LI&gt;
&lt;LI&gt;ORM Tool of choice (might be in the same language as above, but configuration file formats are a language/skill of its own)&lt;/LI&gt;
&lt;LI&gt;SQL - at some stage you are going to have to create database tables, script domain data or debug an ORM generated query! Face it, you need to know at least some SQL!&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;Developers not only need to have some understanding of these languages, but they also have to know how to debug and deploy each technology. What is the chance of hiring an off-the-street developer who knows all of these skills used in a project today in 12 months time?&lt;/P&gt;
&lt;P&gt;It seems like the web development tier is undergoing an explosion of little point tools. Pick an AJAX toolkit, pick an ORM solution, pick a MVC pattern to use. Many of our choices today in leveraging a tool to "expedite" initial development incurs a cost in maintainability, and some won't make the distance and be around or upgradable in a few years time. &amp;nbsp;&lt;/P&gt;
&lt;P&gt;I'm simply not sure whether this is a problem at all. Whilst I think there are benefits in designing a solution without external dependencies and using as few technologies and languages as possible, I'm not sure how important it is.&lt;/P&gt;
&lt;P&gt;Some other questions I have as I fall asleep -&lt;/P&gt;
&lt;P&gt;1. Does &lt;A href="http://projects.nikhilk.net/Projects/ScriptSharp.aspx"&gt;Script#&lt;/A&gt; help? (write C#, generates JavaScript)&lt;/P&gt;
&lt;P&gt;2. Does &lt;A href="http://silverlight.net/"&gt;Silverlight &lt;/A&gt;offer hope? (write C# and have it hosted in either JavaScript or a cross-platform runtime)&lt;/P&gt;
&lt;P&gt;3. Does using &lt;A href="http://www.hookedonlinq.com"&gt;LINQ to SQL &lt;/A&gt;or the &lt;A href="http://blogs.msdn.com/adonet/"&gt;ADO.NET Entity Framework &lt;/A&gt;&amp;nbsp;and/or &lt;A href="http://blogs.msdn.com/astoriateam/"&gt;Astoria &lt;/A&gt;offer enough ORM/Rest features whilst using C# as the development language?&lt;/P&gt;
&lt;P&gt;4. Does &lt;A href="http://labs.live.com/volta/"&gt;Volta&lt;/A&gt;&amp;nbsp;help us at all? "First, design and build your application as a .NET client application, then assign the portions of the application to run on the server and the client tiers late in the development process. The compiler creates cross-browser JavaScript for the client tier, web services for the server tier, and communication, serialization, synchronization, security, and other boilerplate code to tie the tiers together."&lt;/P&gt;
&lt;P&gt;5. Should we use Flash totally using &lt;A href="http://www.adobe.com/products/flex/"&gt;Adobe Flex&lt;/A&gt; and go with the time tested solution?&lt;/P&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1643" width="1" height="1"&gt;</description><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1008.aspx">Random</category></item><item><title>Failing Gracefully - Limited Functionality Mode on Failure</title><link>http://aspiring-technology.com/blogs/troym/archive/2007/12/03/Limited_ServiceMode.aspx</link><pubDate>Mon, 03 Dec 2007 12:23:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1344</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1344.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1344</wfw:commentRss><description>&lt;P&gt;I was impressed on a project a few years ago (&lt;A href="http://msdn2.microsoft.com/en-us/architecture/aa948850.aspx"&gt;CommSee Case Study&lt;/A&gt;) that the architecture allowed as much of the application to run (albeit in a limited fashion) even when the database server&amp;nbsp;was in-accessible for some reason (other services relying on web-services still operated); They called it Limited Service Mode. For real-time customer facing systems, there must be some functionality that is available when a resource has failed. It is all too easy to design a system that&amp;nbsp;fails completely leaving end-users with no sign-of-life&amp;nbsp;when operating conditions degrade.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;What are some of the aspects to consider when desiging in this sort of feature:&lt;/P&gt;
&lt;OL&gt;
&lt;LI&gt;Offline Mode - Can the application be built to operate offline and synchronize when network connection of database functionality resumes?&lt;/LI&gt;
&lt;LI&gt;If data is retrieved and sent to web-services, can the server-side start queuing these requests, and catch-up when the DB or SOA bus is restored?&lt;/LI&gt;
&lt;LI&gt;If it is a public website, at least the home page and contact us page should display, even if it is only in one language (hopefully the language which gets the majority of hits)&lt;/LI&gt;
&lt;LI&gt;Not all actions should be allowed; If data or financial loss could occur, then that feature isn't a candidate for use when in limited functionality mode&lt;/LI&gt;&lt;/OL&gt;
&lt;P&gt;It is an interesting thought experiment; When you are writing your next feature have a think about how you could improve its end-user experience in the case of a network, database or other failure mode.&lt;/P&gt;
&lt;P&gt;Troy.&lt;/P&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1344" width="1" height="1"&gt;</description><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1008.aspx">Random</category></item><item><title>Parallel Extensions to .NET 3.5 Framework CTP Released</title><link>http://aspiring-technology.com/blogs/troym/archive/2007/12/01/1295.aspx</link><pubDate>Sat, 01 Dec 2007 12:21:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1295</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1295.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1295</wfw:commentRss><description>&lt;P&gt;Microsoft released the first public CTP of their Parallel Extensions Framework for .NET. This framework reduces the entry barriers and improves the developer experience when writing Multi-threaded applications. Why is this so important? Because, the laptop or desktop you are reading this post on probably has a dual-core processor. The one you get for Christmas will probably have a 4 core processor, and your IT department is probably getting sales calls from their reps offering then 8, 16, 32, 64 core or multi-processor machines.&lt;/P&gt;
&lt;P&gt;I've had a play previously with &lt;A href="http://www.openmp.net"&gt;OpenMP&lt;/A&gt;&amp;nbsp;which is&amp;nbsp;a standard syntax for marking up C++ code that then executes parallel (supported since visual Studio 2005, .NET 2.0), but if we wanted these benefits in managed code you are faced with rolling your own threading implementation, (and then getting it working :-) )&amp;nbsp;Possible, but by no means as simple as it could be.&lt;/P&gt;
&lt;P&gt;These extensions will make it easier for everybody to write thread-safe, parallel operating code across as many processors or cores a machine has. You have got to love that.&lt;/P&gt;
&lt;P&gt;&lt;A href="http://msdn2.microsoft.com/en-us/concurrency/default.aspx"&gt;Parallel Computing Microsite on Microsoft.com&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.microsoft.com/downloads/details.aspx?FamilyID=e848dc1d-5be3-4941-8705-024bc7f180ba&amp;amp;displaylang=en"&gt;December 2007 Parallel Extensions CTP for Visual Studio 2008&lt;/A&gt;&amp;nbsp;Download&lt;/P&gt;
&lt;P&gt;&lt;A href="http://blogs.msdn.com/pfxteam/rss_tag_Parallel+Extensions.xml"&gt;Parallel Computing Blog for these Parallel Extensions&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;Go download them - What you can't multi-task at work???&lt;/P&gt;
&lt;P&gt;Troy.&lt;/P&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1295" width="1" height="1"&gt;</description></item><item><title>Building a Event Log Viewer using LINQ</title><link>http://aspiring-technology.com/blogs/troym/archive/2007/11/27/LINQEventLogViewer.aspx</link><pubDate>Tue, 27 Nov 2007 23:39:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1279</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>0</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1279.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1279</wfw:commentRss><description>&lt;P&gt;Now that LINQ is available to all developers with the release of Visual Studio 2008, it is going to take some time to realize all of its uses. I now find I&amp;nbsp;examine a .NET class library object and see if any properties implement an IEnumerable collection interface. &lt;/P&gt;
&lt;P&gt;Like the EventLog component does. You drag this component onto a form and you immediately can read and write to and from a Windows Event Log. I immediately wanted to see if I could use LINQ to filter and query the entries. &lt;/P&gt;
&lt;P&gt;My final aim is to make an RSS publisher for certain event log entries that match a filter. But for this example, I just wanted to display and filter the event log sources into a grid.&lt;/P&gt;
&lt;P&gt;&lt;IMG alt=Image src="http://www.hookedonlinq.com/GetFile.aspx?File=Images%2feventlogsample.gif"&gt;&lt;/P&gt;
&lt;P&gt;The full code can be &lt;A title="Downloaded here" href="http://www.hookedonlinq.com/GetFile.aspx?File=CodeSamples%2fLINQEventLogSample.zip"&gt;Downloaded here&lt;/A&gt;&amp;nbsp;or a full step-by-step available on the &lt;A href="http://www.hookedonlinq.com/EventLogViewerSample.ashx"&gt;HookedONLINQ Wiki site here.&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;The two important LINQ query bits look like this:&lt;/P&gt;&lt;PRE class=csharp&gt;        &lt;SPAN&gt;private&lt;/SPAN&gt; &lt;SPAN&gt;void&lt;/SPAN&gt; MainForm_Load&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;object&lt;/SPAN&gt; sender, EventArgs e&lt;SPAN&gt;)&lt;/SPAN&gt;
        &lt;SPAN&gt;{&lt;/SPAN&gt;
            &lt;SPAN&gt;// retrieve a list of all event log sources, and populate the drop-down combo box&lt;/SPAN&gt;
            eventLog.&lt;SPAN&gt;Log&lt;/SPAN&gt; = &lt;SPAN&gt;"Application"&lt;/SPAN&gt;;
&amp;nbsp;
            var sources = &lt;SPAN&gt;(&lt;/SPAN&gt;from EventLogEntry es &lt;SPAN&gt;in&lt;/SPAN&gt; eventLog.&lt;SPAN&gt;Entries&lt;/SPAN&gt;
                           orderby es.&lt;SPAN&gt;Source&lt;/SPAN&gt;
                           select es.&lt;SPAN&gt;Source&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;.&lt;SPAN&gt;Distinct&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;;
&amp;nbsp;
            comboBoxSource.&lt;SPAN&gt;DataSource&lt;/SPAN&gt; = sources.&lt;SPAN&gt;ToList&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;;
        &lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/PRE&gt;&lt;BR&gt;&lt;PRE class=csharp&gt;        &lt;SPAN&gt;private&lt;/SPAN&gt; &lt;SPAN&gt;void&lt;/SPAN&gt; comboBoxSource_SelectedIndexChanged&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;object&lt;/SPAN&gt; sender, EventArgs e&lt;SPAN&gt;)&lt;/SPAN&gt;
        &lt;SPAN&gt;{&lt;/SPAN&gt;
            &lt;SPAN&gt;// retrieve all the event log entries matching the source selection in the combo-box&lt;/SPAN&gt;
            var query = from EventLogEntry el &lt;SPAN&gt;in&lt;/SPAN&gt; eventLog.&lt;SPAN&gt;Entries&lt;/SPAN&gt;
                        where el.&lt;SPAN&gt;Source&lt;/SPAN&gt; == comboBoxSource.&lt;SPAN&gt;Text&lt;/SPAN&gt;
                        orderby el.&lt;SPAN&gt;TimeGenerated&lt;/SPAN&gt; descending
                        select &lt;A href="http://www.google.com/search?q=new+msdn.microsoft.com"&gt;&lt;SPAN&gt;new&lt;/SPAN&gt;&lt;/A&gt;
                        &lt;SPAN&gt;{&lt;/SPAN&gt;
                            Time = el.&lt;SPAN&gt;TimeGenerated&lt;/SPAN&gt;,
                            Source = el.&lt;SPAN&gt;Source&lt;/SPAN&gt;,
                            Message = el.&lt;SPAN&gt;Message&lt;/SPAN&gt;
                        &lt;SPAN&gt;}&lt;/SPAN&gt;;
&amp;nbsp;
            dataGridView.&lt;SPAN&gt;DataSource&lt;/SPAN&gt; = query.&lt;SPAN&gt;ToList&lt;/SPAN&gt;&lt;SPAN&gt;(&lt;/SPAN&gt;&lt;SPAN&gt;)&lt;/SPAN&gt;;
&amp;nbsp;
        &lt;SPAN&gt;}&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE class=csharp&gt;&lt;SPAN&gt;You can see that is pretty simple queries. To do the same using loops and if statements would have been considerable more work though. Keep an eye out for any type that exposes a list property, and keep LINQ in mind when using that property. If you are seeing lots of complicated for loops and if statements - you should refactor and use a LINQ query instead.&lt;/SPAN&gt;&lt;/PRE&gt;&lt;PRE class=csharp&gt;&lt;SPAN&gt;Troy. &lt;/SPAN&gt;&lt;/PRE&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1279" width="1" height="1"&gt;</description><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1002.aspx">LINQ</category><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1007.aspx">C# 3.0</category></item><item><title>Does Continuous Integration Scale to Enterprise Projects?</title><link>http://aspiring-technology.com/blogs/troym/archive/2007/11/26/DoesContinuousIntegrationScale.aspx</link><pubDate>Mon, 26 Nov 2007 16:41:00 GMT</pubDate><guid isPermaLink="false">21093a07-8b3d-42db-8cbf-3350fcbf5496:1269</guid><dc:creator>Troy.Magennis</dc:creator><slash:comments>1</slash:comments><comments>http://aspiring-technology.com/blogs/troym/comments/1269.aspx</comments><wfw:commentRss>http://aspiring-technology.com/blogs/troym/commentrss.aspx?PostID=1269</wfw:commentRss><description>&lt;P&gt;I've often heard and seen large teams struggle when implementing some agile project practices in large enterprises. I recently joined &lt;A href="http://www.corbis.com/"&gt;Corbis&lt;/A&gt;&amp;nbsp;who were using many agile practices (introduced by my boss, &lt;A href="http://www.agilemanagement.net/Articles/Weblog/blog.html"&gt;David Anderson &lt;/A&gt;who wrote Agile Management book), but Continuous Integration and Automated Builds weren't on the list.&lt;/P&gt;
&lt;P&gt;We discussed why CI was needed for a while, and then successfully implemented it. During this process, I kept careful notes on the barriers we encountered and how those barriers were overcome. On David's urging (I mentioned he was by boss right and does my reviews), I put together this draft article (&lt;A HREF="/blogs/troym/attachment/1269.ashx"&gt;attached to this post in PDF format&lt;/A&gt;). I'm keen to hear feeback on it.&lt;/P&gt;
&lt;P&gt;Here is the Introduction -&lt;/P&gt;
&lt;BLOCKQUOTE dir=ltr&gt;
&lt;H2&gt;Introduction&lt;/H2&gt;
&lt;P class=MsoNormal&gt;Continuous Integration and an Automated Build process are common practices employed by many high-functioning agile software teams. Many small teams are reporting high productivity improvements, but success stories of Continuous Integration and Automated Builds for Enterprise Scale software projects are much rarer. Some agile pundits have stated that there is a scale limitation for agile practices and these practices are in-appropriate for Enterprise Scale (or high staff count) projects.&lt;/P&gt;
&lt;P class=MsoNormal&gt;This article aims to explore if and why the measurable benefits of Continuous Integration and Automated Build processes begin to decline as application size, and team size grows.&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Our conclusion is that there is no inherent reason why Continuous Integration and Automate Build processes won’t scale to any size team. In fact, this article concludes that the problems these techniques solve are a higher pain point for Enterprise Scale applications and become more essential than ever. In addition, this article provides guidance on how to scale agile practices and how to make smart architectural choices up-front to ensure smooth adoption of Continuous Integration and Automated Builds leading to smoother projects and improved success rates.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BLOCKQUOTE&gt;
&lt;P&gt;&lt;SPAN&gt;Interested in your thoughts....&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;Troy.&lt;/SPAN&gt;&lt;/P&gt;&lt;img src="http://aspiring-technology.com/aggbug.aspx?PostID=1269" width="1" height="1"&gt;</description><enclosure url="http://aspiring-technology.com/blogs/troym/attachment/1269.ashx" length="697829" type="application/pdf" /><category domain="http://aspiring-technology.com/blogs/troym/archive/category/1009.aspx">Tools</category></item></channel></rss>