Microsoft Open Sourcing .NET is the Right Move

Microsoft announced a few days ago that it was open sourcing .NET. I consider this a huge move in the right direction. One of the principles of .NET was to separate the code from the underlying hardware. You code to the framework, not to the machine. If the framework (and the CLR) is portable, then the code is portable. In theory, Microsoft could then just port the framework to Apple or Linux hardware, and the code would just work, possibly without even a recompile.

But that was just theory. In practice, Microsoft only ported the framework to different versions of Windows, including the Windows phone and the Xbox, but not any of the competitors operating systems. This lost one of the huge potential advantages of .NET.

The Mono project tried to code around this by creating a compatible version on the other platforms, but they had to do a complete reimplementation. I have compared the code produced in one class in the Mono project to the code in the .NET Framework, and they are not at all the same. This tends to result in subtle differences in functionality between running on Windows with Microsoft's framework versus running on Mono. With the new open source available, Mono moves out of the fringes and becomes the main cross-platform version of the .NET Framework, as they incorporate Microsoft's code.

With the new announcement, Microsoft essentially makes porting possible without spending any resources to actually make it work on these other platforms. This is a win for Microsoft, but also for all of the programmers who have spent the last 13 years programming for .NET. Our investment in learning the ins and outs of .NET can now be used on a much wider set of machines. We don't have to learn a separate technology for programming for Android or the iPhone.

It is still unclear exactly how much Microsoft is going to open up. My biggest question is whether Microsoft will be open sourcing Windows Presentation Foundation (WPF). Mono had avoided working on this because it was a difficult project. The Mono developers estimated 30-60 person years to implement it in Mono. This cost would go down considerably if Microsoft open sources WPF. It still will take quite a bit of resources to port it, since WPF uses DirectX, whereas the ports would probably have to use OpenGL underneath it. However, the port would become a possible thing for Mono if they can just grab the source code.

Microsoft also simultaneously announced that Visual Studio would be free for classroom, education, and very small companies. The version they are giving away is essentially Visual Studio Professional, although with the name "Community Edition". Before this, they were giving away the Visual Studio Express version, but it had serious limitations, and wasn't really practical for developing real production code in many cases.

I would still like to see two things in the cheap/free versions of Visual Studio: 1) Code Coverage. The easiest way to tell whether your test suite has hit all the methods and properties in your code is Code Coverage. This currently only ships in the Premium edition (or better) of Visual Studio. 2) CodeLens. CodeLens provides information about your code directly in the Visual Studio interface. It is currently only available in the Visual Studio Ultimate edition. There may be other features I'd like to see move down, but these are the two that I could make immediate use of. I'm crossing my fingers and hoping they are in the Community and/or Professional Edition in Visual Studio 2015.

All of these moves are great moves for all of us who have invested in learning .NET, and I think this will eventually pay off for Microsoft as well. The .NET platform and the C# programming language are generally considered to be a well thought out easy-to-use environment for getting work done. Being able to leverage that across other platforms makes it a win for everyone. It's a bold move by Microsoft and its new CEO Satya Nadella.

No comments :

Post a Comment