One issue with many web development languages such as PHP or python is that all IO is blocking. So every time a program goes to the net, disk or database the thread or process blocks. It stops what it is doing and waits until the data comes back from the disk or network. In a heavily loaded server which is being bottlenecked by disk or network this can result in a great number of processes in disk or network wait states, this is less than ideal when trying to scale.
One novel program that is trying to deal with this is Node.JS. Node is a server side javascript enviorment that uses the Javascript event loop to work around this. Similar to the way Javascript will do AJAX on the browser Node.JS will do all its IO with a callback. In theory a single Node process can support thousands of users by never blocking on IO. I hope to play with Node.JS soon.
No comments:
Post a Comment