mirror of
https://mau.dev/maunium/synapse.git
synced 2024-12-14 21:43:50 +01:00
Add Measure block for persist_events
This seems like a useful thing to measure.
This commit is contained in:
parent
d65ceb4b48
commit
889a2a853a
1 changed files with 5 additions and 4 deletions
|
@ -283,10 +283,11 @@ class EventsStore(EventsWorkerStore):
|
|||
def _maybe_start_persisting(self, room_id):
|
||||
@defer.inlineCallbacks
|
||||
def persisting_queue(item):
|
||||
yield self._persist_events(
|
||||
item.events_and_contexts,
|
||||
backfilled=item.backfilled,
|
||||
)
|
||||
with Measure(self._clock, "persist_events"):
|
||||
yield self._persist_events(
|
||||
item.events_and_contexts,
|
||||
backfilled=item.backfilled,
|
||||
)
|
||||
|
||||
self._event_persist_queue.handle_queue(room_id, persisting_queue)
|
||||
|
||||
|
|
Loading…
Reference in a new issue