modified to use tornado instead of gae-webapp2