Coding Websites in C++

Friday, April 13, 2012

I’m trying to make more 20% time for myself to experiment with things that are scratching away in my head. So I decided to have a look into something I’ve been thinking about for a while. Why don’t we code websites in C++.

It isn’t a totally new idea. Google is coded in c++. A lot of Yahoo is or was. And it was actually incredibly easy to make a module for IIS7 that did it. Here’s a post I made in the programming forum with an explanation - and a bare bones project.

Good Stuff

Bad Stuff

I did get a nice system done. It has hotloading DLLs, so you could compile and refresh the page and it would automatically reload the DLL. It has virtual pages - so you can add a page string like “/my/page.html”, or “/my/page.*” and it’ll load the page from the specified class based on the request.

Ultimately I decided to stop working on it because I’m not totally convinced of the speed benefits (the database being the bottleneck). And while I do love C++ - I feel that coding websites in it would be cumbersome without spending some significant time coding a framework.

So here’s some useful links for anyone else thinking of doing this.

I get the feeling that there’s undiscovered potential in there somewhere, so I still have it rattling around in my head.

Turn your phone to view blog list