summary refs log tree commit diff
path: root/synapse/storage/background_updates.py
diff options
context:
space:
mode:
authorDavid Robertson <davidr@element.io>2023-09-01 12:41:56 +0100
committerGitHub <noreply@github.com>2023-09-01 12:41:56 +0100
commit6525fd65ee52e36929b9c35253c772da16aa2b99 (patch)
tree54a1f978d6966ba24042eeb9defa93c0d43992ae /synapse/storage/background_updates.py
parentIgnore redundant casts in latest deps CI job (#16213) (diff)
downloadsynapse-6525fd65ee52e36929b9c35253c772da16aa2b99.tar.xz
Log the details of background update failures (#16212)
Diffstat (limited to 'synapse/storage/background_updates.py')
-rw-r--r--synapse/storage/background_updates.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/synapse/storage/background_updates.py b/synapse/storage/background_updates.py
index ddca0af1da..7619f405fa 100644
--- a/synapse/storage/background_updates.py
+++ b/synapse/storage/background_updates.py
@@ -405,14 +405,14 @@ class BackgroundUpdater:
                 try:
                     result = await self.do_next_background_update(sleep)
                     back_to_back_failures = 0
-                except Exception:
+                except Exception as e:
+                    logger.exception("Error doing update: %s", e)
                     back_to_back_failures += 1
                     if back_to_back_failures >= 5:
                         self._aborted = True
                         raise RuntimeError(
                             "5 back-to-back background update failures; aborting."
                         )
-                    logger.exception("Error doing update")
                 else:
                     if result:
                         logger.info(