2011 node 0.4 book demo, extensively refactored to work in 2014 version of node 0.8