Skip to content

Instantly share code, notes, and snippets.

View carlzhangxuan's full-sized avatar
:octocat:
On vacation

z carlzhangxuan

:octocat:
On vacation
View GitHub Profile
class Application(tornado.web.Application):
def __init__(self):
tornado.web.Application.__init__(self, handlers, **settings)
self.db_session = db_session
self.redis = redis.StrictRedis()
self.session_store = RedisSessionStore(self.redis)
class BaseHandler(tornado.web.RequestHandler):