mirror of
https://mau.dev/maunium/synapse.git
synced 2025-03-05 05:00:24 +01:00
Correctly register shutdown handler for presence workers (#11518)
Fixes #11517
This commit is contained in:
parent
eccc49d755
commit
2a3ec6facf
2 changed files with 2 additions and 1 deletions
1
changelog.d/11518.bugfix
Normal file
1
changelog.d/11518.bugfix
Normal file
|
@ -0,0 +1 @@
|
||||||
|
Fix a regression in Synapse 1.48.0 where presence workers would not clear their presence updates over replication on shutdown.
|
|
@ -421,7 +421,7 @@ class WorkerPresenceHandler(BasePresenceHandler):
|
||||||
self._on_shutdown,
|
self._on_shutdown,
|
||||||
)
|
)
|
||||||
|
|
||||||
def _on_shutdown(self) -> None:
|
async def _on_shutdown(self) -> None:
|
||||||
if self._presence_enabled:
|
if self._presence_enabled:
|
||||||
self.hs.get_tcp_replication().send_command(
|
self.hs.get_tcp_replication().send_command(
|
||||||
ClearUserSyncsCommand(self.instance_id)
|
ClearUserSyncsCommand(self.instance_id)
|
||||||
|
|
Loading…
Add table
Reference in a new issue