summary refs log tree commit diff
path: root/synapse/push
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2016-08-17 18:00:04 +0100
committerErik Johnston <erik@matrix.org>2016-08-17 18:00:18 +0100
commitabcb9aee5b52421df620830609606d778eeb8ca0 (patch)
treefe1219ceec2ef35235b849ca687a3593df8545eb /synapse/push
parentMerge pull request #1021 from matrix-org/erikj/mediasecurity_policy (diff)
downloadsynapse-abcb9aee5b52421df620830609606d778eeb8ca0.tar.xz
Make push Measure finer grained
Diffstat (limited to 'synapse/push')
-rw-r--r--synapse/push/action_generator.py9
1 files changed, 5 insertions, 4 deletions
diff --git a/synapse/push/action_generator.py b/synapse/push/action_generator.py
index 46e768e35c..b2c94bfaac 100644
--- a/synapse/push/action_generator.py
+++ b/synapse/push/action_generator.py
@@ -38,15 +38,16 @@ class ActionGenerator:
 
     @defer.inlineCallbacks
     def handle_push_actions_for_event(self, event, context):
-        with Measure(self.clock, "handle_push_actions_for_event"):
+        with Measure(self.clock, "evaluator_for_event"):
             bulk_evaluator = yield evaluator_for_event(
                 event, self.hs, self.store, context.current_state
             )
 
+        with Measure(self.clock, "action_for_event_by_user"):
             actions_by_user = yield bulk_evaluator.action_for_event_by_user(
                 event, context.current_state
             )
 
-            context.push_actions = [
-                (uid, actions) for uid, actions in actions_by_user.items()
-            ]
+        context.push_actions = [
+            (uid, actions) for uid, actions in actions_by_user.items()
+        ]