@utils.dispatch_for_dialect('*', multiple=True)
def _init_events(engine, thread_checkin=True, connection_trace=False, **kw):

    _add_process_guards(engine)

    if connection_trace:
        _add_trace_comments(engine)

    if thread_checkin:
        sqlalchemy.event.listen(engine, 'checkin', _thread_yield)
Set up event listeners for all database backends.
dataset/ETHPy150Open openstack/oslo.db/oslo_db/sqlalchemy/engines.py/_init_events