Tuesday, October 17, 2006

ASP.NET providers now pluggable

A couple years ago I wanted to learn C#, so a good way I thought was to write a medium sized project in C#. For the project I decided to do a Tomcat/Jetty-like "servlet" engine, but using ASP.NET instead of JSPs.

The Microsoft company line at the time was "if you want to do ASP.NET, you have to buy/install/run on IIS". Well, after I did a bit of research that turned out to be only half true. The actual ASP.NET engine was part of the .NET core runtime. Although it wasn't documented how to pass HTTP requests through to the ASP.NET engine Microsoft kindly provided just such an example with the Cassini sample web server.

So far so good. However, when I looked into slightly more complex things like security and session replication I hit a dead end - all of these things were very closely tied to SQL Server, all of the interfaces that would have been useful to extend and make generic were marked "sealed". Bummer. I gave up that pet project because I didn't want to be tied to just SQL Server.

I was therefore plesently surprised to see an infoq article titled "Create Your Own ASP.NET Providers", which tells you how to implement user and session providers in ASP.NET 2.0. I'm very tempted to resurrect that old project and implement some of the new Jetty 6 features like continuations and large scale NIO in C#. (Jetty.net anyone?)

No comments: