Logging around get_new_events_for_appservice

This commit is contained in:
Will Hunt 2019-03-20 16:32:44 +00:00
parent 15eb781f80
commit f4b3f2066f

View file

@ -340,6 +340,8 @@ class ApplicationServiceTransactionWorkerStore(ApplicationServiceWorkerStore,
def get_new_events_for_appservice(self, current_id, limit): def get_new_events_for_appservice(self, current_id, limit):
"""Get all new evnets""" """Get all new evnets"""
logger.info("call get_new_events_for_appservice(%s, %s)", current_id, limit)
def get_new_events_for_appservice_txn(txn): def get_new_events_for_appservice_txn(txn):
sql = ( sql = (
"SELECT e.stream_ordering, e.event_id" "SELECT e.stream_ordering, e.event_id"
@ -365,8 +367,12 @@ class ApplicationServiceTransactionWorkerStore(ApplicationServiceWorkerStore,
"get_new_events_for_appservice", get_new_events_for_appservice_txn, "get_new_events_for_appservice", get_new_events_for_appservice_txn,
) )
logger.info("call get_new_events_for_appservice len(event_ids) = %s", len(event_ids))
events = yield self._get_events(event_ids) events = yield self._get_events(event_ids)
logger.info("call get_new_events_for_appservice len(event_ids) = %s", len(events))
defer.returnValue((upper_bound, events)) defer.returnValue((upper_bound, events))