diff options
author | reivilibre <oliverw@matrix.org> | 2022-04-01 13:08:55 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-01 13:08:55 +0100 |
commit | f8712228801d9c4753e65819fa4241818b56953b (patch) | |
tree | fffb61404df1fe81c8598a1ac4b7d37c62747638 /synapse/replication/tcp/commands.py | |
parent | Raise an exception when getting state at an outlier (#12191) (diff) | |
download | synapse-f8712228801d9c4753e65819fa4241818b56953b.tar.xz |
Move `update_client_ip` background job from the main process to the background worker. (#12251)
Diffstat (limited to 'synapse/replication/tcp/commands.py')
-rw-r--r-- | synapse/replication/tcp/commands.py | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/synapse/replication/tcp/commands.py b/synapse/replication/tcp/commands.py index 3654f6c03c..fe34948168 100644 --- a/synapse/replication/tcp/commands.py +++ b/synapse/replication/tcp/commands.py @@ -356,7 +356,7 @@ class UserIpCommand(Command): access_token: str, ip: str, user_agent: str, - device_id: str, + device_id: Optional[str], last_seen: int, ): self.user_id = user_id @@ -389,6 +389,12 @@ class UserIpCommand(Command): ) ) + def __repr__(self) -> str: + return ( + f"UserIpCommand({self.user_id!r}, .., {self.ip!r}, " + f"{self.user_agent!r}, {self.device_id!r}, {self.last_seen})" + ) + class RemoteServerUpCommand(_SimpleCommand): """Sent when a worker has detected that a remote server is no longer |