def _create_facade_lazily():
    global _LOCK
    with _LOCK:
        global _FACADE
        if (_FACADE is None):
            _FACADE = db_session.EngineFacade(CONF.database.connection, **dict(CONF.database))
        return _FACADE
def _create_facade_lazily():
    global _LOCK
    with _LOCK:
        global _FACADE
        if (_FACADE is None):
            _FACADE = db_session.EngineFacade(CONF.database.connection, **dict(CONF.database))
        return _FACADE