mirror of
https://github.com/element-hq/synapse
synced 2024-09-03 20:10:11 +00:00
Better logging when pushes fail
This commit is contained in:
parent
e051abd20b
commit
03dd745fe2
1 changed files with 8 additions and 2 deletions
|
@ -333,7 +333,10 @@ class HttpPusher(object):
|
||||||
try:
|
try:
|
||||||
resp = yield self.http_client.post_json_get_json(self.url, notification_dict)
|
resp = yield self.http_client.post_json_get_json(self.url, notification_dict)
|
||||||
except Exception:
|
except Exception:
|
||||||
logger.warn("Failed to push %s ", self.url)
|
logger.warn(
|
||||||
|
"Failed to push event %s to %s",
|
||||||
|
event.event_id, self.name, exc_info=True,
|
||||||
|
)
|
||||||
defer.returnValue(False)
|
defer.returnValue(False)
|
||||||
rejected = []
|
rejected = []
|
||||||
if 'rejected' in resp:
|
if 'rejected' in resp:
|
||||||
|
@ -364,7 +367,10 @@ class HttpPusher(object):
|
||||||
try:
|
try:
|
||||||
resp = yield self.http_client.post_json_get_json(self.url, d)
|
resp = yield self.http_client.post_json_get_json(self.url, d)
|
||||||
except Exception:
|
except Exception:
|
||||||
logger.exception("Failed to push %s ", self.url)
|
logger.warn(
|
||||||
|
"Failed to send badge count to %s",
|
||||||
|
self.name, exc_info=True,
|
||||||
|
)
|
||||||
defer.returnValue(False)
|
defer.returnValue(False)
|
||||||
rejected = []
|
rejected = []
|
||||||
if 'rejected' in resp:
|
if 'rejected' in resp:
|
||||||
|
|
Loading…
Reference in a new issue