summary refs log tree commit diff
path: root/synapse/replication
diff options
context:
space:
mode:
authorMark Haines <mark.haines@matrix.org>2016-04-28 10:57:49 +0100
committerMark Haines <mark.haines@matrix.org>2016-04-28 10:57:49 +0100
commit8d7ad44331d7eff4a140b1e4777532d8a3fb26cb (patch)
treefaddd565b52aa68dc1108a1c0c5903e66ae591c3 /synapse/replication
parentMerge pull request #755 from matrix-org/markjh/right_direction (diff)
downloadsynapse-8d7ad44331d7eff4a140b1e4777532d8a3fb26cb.tar.xz
Report per request metrics for all of the things using request_handler
Diffstat (limited to 'synapse/replication')
-rw-r--r--synapse/replication/pusher_resource.py3
-rw-r--r--synapse/replication/resource.py3
2 files changed, 4 insertions, 2 deletions
diff --git a/synapse/replication/pusher_resource.py b/synapse/replication/pusher_resource.py
index b87026d79a..9b01ab3c13 100644
--- a/synapse/replication/pusher_resource.py
+++ b/synapse/replication/pusher_resource.py
@@ -31,12 +31,13 @@ class PusherResource(Resource):
         self.version_string = hs.version_string
         self.store = hs.get_datastore()
         self.notifier = hs.get_notifier()
+        self.clock = hs.get_clock()
 
     def render_POST(self, request):
         self._async_render_POST(request)
         return NOT_DONE_YET
 
-    @request_handler
+    @request_handler()
     @defer.inlineCallbacks
     def _async_render_POST(self, request):
         content = parse_json_object_from_request(request)
diff --git a/synapse/replication/resource.py b/synapse/replication/resource.py
index 149fc4c650..ff78c60f13 100644
--- a/synapse/replication/resource.py
+++ b/synapse/replication/resource.py
@@ -112,6 +112,7 @@ class ReplicationResource(Resource):
         self.presence_handler = hs.get_handlers().presence_handler
         self.typing_handler = hs.get_handlers().typing_notification_handler
         self.notifier = hs.notifier
+        self.clock = hs.get_clock()
 
         self.putChild("remove_pushers", PusherResource(hs))
 
@@ -139,7 +140,7 @@ class ReplicationResource(Resource):
             state_token,
         ))
 
-    @request_handler
+    @request_handler()
     @defer.inlineCallbacks
     def _async_render_GET(self, request):
         limit = parse_integer(request, "limit", 100)