Nima Dilmaghani’s Technology Blog

Microsoft announces its new MVC architecture for Web Apps

Today at the conference, Scott Guthrie demoed the new MVC architecture that Microsoft will be releasing in Spring 2008 for web apps. The first CTP should be available in two weeks. This architecture is very similar in many ways to the Rails architecture but takes full advantage of Microsoft .NET 3.5’s features and the strong typing in .NET. The crowed of alpha geeks that where incredibly critical of Microsoft the night before all gathered in one room and intently listened. Many questions were asked: Does this framework work with such and such? Can I do so and so. Scott’s answer was yes to all of these questions. The crowed was enchanted by Guthrie. No one had anything negative to say. There were a few syntactic and minor suggestions. And some mental wresting from some of the geeks, but Scott’s technical answers addressed the issues raised. Everyone was incredibly impressed. Scott’s presentation and rapid fire answers to questions demonstrated his detailed understanding of all the testing frameworks as well as alternative development frameworks out there and his team’s synthesis of all this knowledge in what appears to be a superior product to what currently exists in the market.
This will be a MVC pattern similar to Rails with a similar URL mapping convention and an architecture that allows you to plug in your favorite testing tools. Both Scott Hanselman and Philip Wheat taped the talk and will post it shortly. I strongly recommend watching it. This architecture is far superior in separation of concerns, testability, maintainability, and scalability to the existing ASP.NET architecture that was basically mimicking a state-full WinForms environment in a stateless web world to bring existing WinForms developers up to speed with web application development quickly. It will enter a heated battle with Ruby on Rails for the top spot as the best way to develop modern web apps. The Microsoft .NET Framework will have certain advantages such as WCF, Linq, and strong typing while the dynamic nature of Ruby and it’s faster innovation rates due to its open source nature will have other advantages. It will be interesting to see how this fight will pan out.

Note that because of a fundamental change in the design, there will be a new (smaller) set of ASP.NET controls that will work in this model. This architecture relies more on the native html controls (which is a good thing. See my CSS blog post to see what hoops you need to jump through to make ASP.NET controls work well with CSS). AJAX Control Toolkit controls that talk to the server also will get counter parts that will work in this model. There will be no change to the Microsoft Ajax Library or the networking stack of the Microsoft Ajax offering. This stack will also improve the existing ASP.NET architecture by replacing the UpdatePanel that was designed to wrap existing ASP.NET controls which were not originally designed for Ajax with a control that can be passed into the app as a JSON object and placed in a placeholder.

To read other perspectives please read the following blogs:

Bob Grommes, Chris Holmes, Howard Dierking, Jeffery Palermo, Jason Meridth, Joshua Flanagan Mike Moore, Roy Osherove,

Update: Sergio Pereira has written nice blog post that goes in more detail with sample code.

Back to the future with source code viewing with Visual Studio 2008

Posted in .NET, ASP.NET, engineering, Microsoft, programming, software, Technology and Software by nimad on October 4, 2007

Today Microsoft announced that it will be releasing many of the .NET Framework libraries under the Microsoft Reference License (Ms-RL).   Scott Guthrie’s post details what this means.  We have been able to see this source code using Reflector for a number of years so while getting the code in one big chunk is nicer (and now properly licensed) it is not that big of a deal.   A feature that has been lacking since the days of MFC is the ability to step into Microsoft source code in the Visual Studio debugger from your own code.  This was a great feature in MFC and I among others had asked Microsoft’s product team for it in 2005.  Today, my wish has been granted.  Starting with VS2008 you can actually step into Microsoft source code from your own code.  This will help developers everywhere better understand how Microsoft code works and write their code better.  It also puts Microsoft source code more in the spotlight and I hope this visibility will cause Microsoft developers to write better code.

My new wish is that future pieces of source code released in this manner should have the signature or alias of the developer who wrote it so if they did a poor job, the whole world would know.  While this wish coming true is very unlikely for many many reasons, I thought I put it down in writing none the less.