Code example from the book Node.js in Action