summary refs log tree commit diff
path: root/synapse/appservice
diff options
context:
space:
mode:
Diffstat (limited to 'synapse/appservice')
-rw-r--r--synapse/appservice/api.py1
-rw-r--r--synapse/appservice/scheduler.py4
2 files changed, 4 insertions, 1 deletions
diff --git a/synapse/appservice/api.py b/synapse/appservice/api.py
index c17fb219c5..3acb8867a2 100644
--- a/synapse/appservice/api.py
+++ b/synapse/appservice/api.py
@@ -79,6 +79,7 @@ class ApplicationServiceApi(SimpleHttpClient):
             logger.warning("push_bulk: Missing txn ID sending events to %s",
                            service.url)
             txn_id = str(0)
+        txn_id = str(txn_id)
 
         uri = service.url + ("/transactions/%s" %
                              urllib.quote(txn_id))
diff --git a/synapse/appservice/scheduler.py b/synapse/appservice/scheduler.py
index 068d4bd087..3ee2406463 100644
--- a/synapse/appservice/scheduler.py
+++ b/synapse/appservice/scheduler.py
@@ -175,7 +175,7 @@ class _TransactionController(object):
     @defer.inlineCallbacks
     def _is_service_up(self, service):
         state = yield self.store.get_appservice_state(service)
-        defer.returnValue(state == ApplicationServiceState.UP)
+        defer.returnValue(state == ApplicationServiceState.UP or state is None)
 
 
 class _Recoverer(object):
@@ -208,6 +208,8 @@ class _Recoverer(object):
     def retry(self):
         txn = yield self._get_oldest_txn()
         if txn:
+            logger.info("Retrying transaction %s for service %s",
+                        txn.id, txn.service)
             if txn.send(self.as_api):
                 txn.complete(self.store)
                 # reset the backoff counter and retry immediately