def connect(thread_index):
    cherrypy.thread_data.scoped_session_class = GlobalSession

def open_dbsession():
    pass
Best practice for integrating CherryPy web-framework, SQLAlchemy sessions and lighttpd to serve a high-load webservice