summary refs log tree commit diff
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2015-08-19 10:08:31 +0100
committerErik Johnston <erik@matrix.org>2015-08-19 10:08:31 +0100
commit78fa346b0781cf42ef8772638f9f8abb26b9a36f (patch)
tree883dd5ee0a3eff80d7ed001bc29ec7695613653d
parentBlock on storing the current last_tokens (diff)
downloadsynapse-78fa346b0781cf42ef8772638f9f8abb26b9a36f.tar.xz
Store the 'last_token' in the db, even if we processed no events
-rw-r--r--synapse/push/__init__.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/synapse/push/__init__.py b/synapse/push/__init__.py
index 483deb624c..13002e0db4 100644
--- a/synapse/push/__init__.py
+++ b/synapse/push/__init__.py
@@ -294,6 +294,12 @@ class Pusher(object):
         if not single_event:
             self.last_token = chunk['end']
             logger.debug("Event stream timeout for pushkey %s", self.pushkey)
+            yield self.store.update_pusher_last_token(
+                self.app_id,
+                self.pushkey,
+                self.user_name,
+                self.last_token
+            )
             return
 
         if not self.alive: