What every Perl programmer needs to know about .NET

.NET is the latest hype blitz from Microsoft (and you thought it was just a domain). If your eyes are glazing over or you're tempted to write it off as marketing speak, read on.

Although Microsoft is loath to admit it, .NET is really their answer to Sun. The Java language, the Java virtual machine and CORBA have proved to be a threat. .NET is the umbrella name for Microsoft's attempt to better Sun.

Whereas Java is the programming language for Sun's "computer is the network" effort, Microsoft has given us C# ("C sharp"). It's derived from C, and attempts to avoid some of the pitfalls of Java and C++. And much as Java compiles down to Java Virtual Machine (JVM) instructions, C# compiles down to Intermediate Language (IL).

Where Microsoft betters Sun is that while Java is the only real language that compiles to the JVM (see update below,) Microsoft intends IL to be cross-language. That is, Perl, Visual Basic and C# can be compiled down to IL. The idea is to make it possible to integrate multiple languages into one system.

Sun chose CORBA as its distributed application platform, but Microsoft has gone with SOAP (Simple Object Access Protocol). In my opinion, SOAP has one huge benefit over CORBA: mere mortals can implement it! Soap uses HTTP to send XML-encoded instance and method calls on remotely defined objects and receive return values. The umbrella term for SOAP and its cousin XML-RPC is "Web Services." There are already SOAP and XML-RPC modules for Perl.

While it's still early days for .NET, and there's still considerable potential for it all to turn out to be vaporware, Microsoft has begun to release .NET components. And it's not just Microsoft - a number of people are using SOAP to give concrete APIs to their Web-based systems. Think of all the times you've tried to parse HTML to extract information - the SOAP way of the future is for that information to be directly accessible through SOAP calls. As I said, this is already happening.

I've heard .NET described as "Microsoft's tacit admission that most shops are not 100 percent Microsoft, so Microsoft products need to work better with other platforms." There are many places for Perl in this new world:

More Information

So where can you learn more? Microsoft has a lot of information about .NET, of course.

http://www.microsoft.com/net/default.asp

There's an introduction from the Windows point of view (covering the plans for COM and ADO and all the other Windowsy things I didn't mention):

http://www.vbxml.com/xml/articles/dotnetintro/default.asp

Your best bet for things you can use now, though, are the SOAP and XML-RPC modules. Be warned: The SOAP modules are hard to get into.

XML-RPC via the Frontier::RPC module

http://bitsko.slc.ut.us/~ken/xml-rpc/

SOAP Modules:

http://www.cpan.org/modules/by-module/SOAP/

Here are some references for Web services:


I meant that while Microsoft is funding and encouraging other languages to compile down to the IL, Sun never seemed to do that with the JVM. As far as I could tell (and I am the first to admit that I am on the fringe of the Java world), their main push was to have Java be The Language. I'm interested to hear whether they really did encourage other languages to compile to the JVM.

Poor choice of words on my part, sorry for the confusion. See http://grunge.cs.tu-berlin.de/~tolk/vmlanguages.html for a list of languages that compile to the JVM.

Visit the home of the Perl programming language: Perl.org

Sponsored by

Monthly Archives

Powered by Movable Type 5.13-en