More Unsung Microsoft Technology: the HTTP Handler (.ashx) Story Is Rarely Told ‘Correctly’
I like .ashx
files in ASP.NET 2.0. The ASHX file type allows me to quickly and easily implement REST calls. It just works in a few lines of code. Now the Microsoft politics: first, Microsoft ‘likes’ SOAP—not REST. I look forward to the Dave Winer documentary on this history. But for the sake of this Blog post we can safely say that Microsoft has no interest in promoting ASHX REST as an alternative to SOAP. In fact, such a promotion can be seen as “irresponsible” because SOAP has built-in, idiot-proof, enterprise-wide discovery and interoperability and REST does not.
So how does Microsoft ‘sell’ ASHX? The table below summarizes:
“[Introduction to HTTP Handlers](http://windowssdk.msdn.microsoft.com/library/default.asp?url=/library/en-us/dv_aspnetcon/html/51612dbe-a809-456b-94bf-47acde2f4ad1.asp)” | This article predates the release of ASP.NET 2.0. This introductory article shows that Microsoft provides two scenarios for ASHX: RSS feeds and the image server. The assumption here is that the latter scenario dominated until the Blog exploded on the scene. |
“[Using HTTP Modules and Handlers to Create Pluggable ASP.NET Components](http://msdn.microsoft.com/asp.net/default.aspx?pull=/library/en-us/dnaspp/html/elmah.asp)” | This article predates the release of ASP.NET 2.0. Here ASHX is introduced as a “tool of reuse” for resource handling. XML is one of those resources and it is featured in the form of RSS—used for Web application error logging. |
“[Life Without Refresh](http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnaspp/html/lifewithoutrefresh.asp)” | This article predates the release of ASP.NET 2.0. Dmitri Khanine and Phil Carrillo present a double feature of unsung Microsoft technologies: AJAX and ASHX. ASHX is buried in the section “Web Server Support for JavaScript RPC.” |
“[HTTP Handlers and HTTP Modules in ASP.NET](http://www.15seconds.com/issue/020417.htm)” | This article predates the release of ASP.NET 2.0. This Mansoor Ahmed Siddiqui article is not a Microsoft publication but it does tow the Microsoft line to ASP.NET-centric and IIS-centric use of HTTP Handlers in a supportive role to ‘proper’ ASPX ASP.NET applications. |