Bye, bye classic ASP, I love you, but you will not be missed ...
I have used Windows and classic ASP for over half my life. Classic ASP even outlived my first dog, and brings up a lot of memories.
I started learning classic ASP using personal web server on Windows 95, which was basically IIS 4 with a limit on it.
At that time I did not have access to Internet at home, so I looked at the asp scripts included in IIS to learn. I guess this gave me a good start as I learned the code style from those who implemented it.
Before classic ASP I had done some programming in Qbasic, so it was easy switching over to vbScript as the syntax looked the same.
I have now switched platform to Linux and Node.JS. And I have learned a lot in the process.
A few years ago I looked at something called Node.JS and asked myself:
At that time, I had never used prototype in JS. But I had just begun to use Classes in vbScript, slowly starting to transcend from a functional programming style, into an object oriented style.
I had used classic ASP for about fifteen years and started to get really good at it. But classic ASP was considered deprecated by many, even though Windows supports it in their latest Windows server. Language wise vbScript and classic ASP is very stable. There has been no updates for classic ASP in years. I guess Microsoft want you to switch over to their dotnet ecosystem. And most ASP programmers have already made the transition to asp.net a long time ago.
But then something happened. All the major browsers started to support something called Websockets.
I though Websockets could be really useful in a web chat. I had already implemented a chat in classic asp, but the HTTP overhead was too much, making the chat use up much more bandwidth then necessary.
I started looking at various implementation of Websockets, but they all seemed too complicated and in languages I wasn't proficient in. But one implementation kept coming up, and it was in this weird Node.JS thing. Getting a bit desperate I finally gave Node.JS a chance.
Node JS introduced new paradigms and thought me a lot about programming ...
Object oriented programming
For some time, I had worked on a 3d engine for the browser, using HTML div's for rendering, and was looking into using Canvas instead, as most browsers now supported it.
But after learning more about 3d I got convinced that abstractions was a good thing. And started using matrices, points and vectors instead of just x,y,z.
In all my programming career I had always coded in a sequential pattern. So Asynchronous functions was really hard to wrap my head around.
Classic ASP is multi threaded. And ASP makes threading very easy. You just use Application.Lock and Application.UnLock to make your code thread safe if needed.
This makes classic asp perform just as well as Node.js. So I guess one thing I will actually miss from classic asp is the multi threading. And when todays CPU's get more and more cores instead of getting much faster, threading totally makes sense. It's a bit weird that something made in 1996 actually handles todays hardware that good!
When using Node.JS I first though it was annoying that you couldn't include code and had to make modules instead. But now I think the modular implementation in Node.JS is what makes Node.JS so great, and the reason behind the success of NPM and the Node.JS community and ecosystem.
Often when you need to do something advanced, someone have already solved it and written a module for it in Node.JS. Which you can use FOR FREE!
Node.JS vs Classic ASP
I will certainly not miss chipping out hundreds of dollars for each .dll compiled library in classic ASP. Imagine if you had to pay licenses for each module in Node.JS!!
To run classic ASP you need to have the Windows OS. This is really a deal breaker, as a Windows server license cost just as much as the hardware for a new server.
It has been a steep learning curve switching to Linux, but hopefully this investment will make me save money in the future.
I am very confident in my classic ASP skills and can do almost anything with it. But classic ASP is not suitable for real time applications, where the opposite holds true for Node.JS. I can now make real time games for the browser!
Object oriented programming, asynchronous functions, prototype, and modules has leveled up my programming skills and opened up new opportunities. With modules and abstractions in Node.JS, you have the combined knowledge of thousands of programmers at your fingertips!
Written by Johan Zetterberg April 20, 2015.