Tech Ed 2007, Day 2 Wrap Up

Yesterday, I ventured into the world of Microsoft CRM 4.0 and IIS7 which were both very educational. Day two at Tech Ed was going to leave the products behind and jump into the deep end of software development.

Building BackgroundMotion using the Composite Web Block

The first presentation I attended was by Jeremy Boyd, a Microsoft Regional Director for New Zealand. The presentation was about building a community site named Background Motion which is all about sharing rich media that can be used as wallpaper within Vista utilising Dreamscene.

If the talk was simply about building a web site using ASP.NET, then it wouldn’t be all that interesting so Jeremy took everyone through how to utilise the Composite Web Block and developing against the Model View Presenter pattern, as opposed to ever popular Model View Controller approach. I really enjoyed seeing the Model View Presenter pattern in use first hand and I thought that the structure and flow felt really good; structure and order are always a good thing – anything to help code sprawling over time.

I have to give plenty of accolades to Jeremy, his presentation was without a doubt the smoothest that I have been involved with so far at Tech.Ed 2007. The flow of switching between the slides and into the Visual Studio was always seamless; no fluffing around configuring references or not having it compile unexpectedly. Jeremy used a simple system to make sure this worked as expected, he had numerous copies of his solution waiting in the appropriate state for each step of the presentation. No only were the technical aspects of the talk sorted out well in advance, his presentation style and pace throughout the talk were excellent.

Enterprise Library 3.x

The second talk I went into was about the Enterprise Library, formally known as Enterprise Application Blocks. Version three of the Enterprise Library comes with a bunch of bug fixes to some of their existing blocks such as the Data Access Application Block but the really interesting news was with the addition of the Validation Application Block and the Policy Injection Application Block.

Touching on each of those points briefly, the Validation Application Block is a generic validation package that provides an array of out of the box validation routines. Validation isn’t anything new, so the important point to note about the Validation Application block is that the same code will work identically using ASP.NET, Windows Forms and Windows Communication Foundation. You could use the validation block to provide ASP.NET level validation and provide a different or additional set of validation routines on the business object itself. The validation can be set up through configuration, attributes and through code. Through the use of the Validation Application Block, it is now convenient to only write validation routines and rules once where as it typically tends to be duplicated.

The real funk started happening when the Policy Injection Application Block came out to play. Using the Policy Injection Application Block, it is possible to separate out common tasks which happen across the enterprise or domain and reuse those through injection. As an example, common tasks like logging, authorisation and validation are common and typically should be reused throughout the code without copy/pasting the functionality. After configuring what policies to inject where and in what order, a new business object is instanced. Instead of getting back an instance of that business object, you get back a proxy that for all intended purposes looks and feels like the business object you asked for. When calling methods on this proxy business object, it invokes the Policy Injection engine and the request for the actual method must flow through pre and post execution paths on the policy injection engine before being accepted. Nifty stuff !

.NET Framework 3.0, Putting It All Together

This talk was about how to integrate all of the different .NET 3.x features into a single application. It appears that the community can see the strengths in any one of the components, however were struggling to see all of them integrated seamlessly together in a single application.

Enter Dinner Now, a fictional online business which lets you order take away food from more than one restaurant at a time and have it all delivered to your home. The Dinner Now sample application uses a wide spread of technology including IIS7, ASP.NET Ajax Extensions, Linq, Windows Communication Foundation, Windows Workflow Foundation, Windows Presentation Foundation, Windows Powershell, and the .NET Compact Framework.

The idea behind this presentation is quite exciting, however I felt that it could have had a little more meat in it. Maybe the talk was geared at a slightly lower entry point but I felt too much time was spent explaining what the different technologies accomplishes and not enough time going through the technical aspects of it. That said, I still found the presentation entertaining and it is fantastic that Microsoft have now recognised the requirement for a sample scenario that is more complex than Northwind.