summary refs log tree commit diff
path: root/synapse/replication/slave/storage/client_ips.py
diff options
context:
space:
mode:
authorEric Eastwood <erice@element.io>2021-11-03 02:10:07 -0500
committerEric Eastwood <erice@element.io>2021-11-03 02:10:07 -0500
commitec35be57e056a795f7ebe393c81ffcb5bccd5872 (patch)
tree5a592e56da1016f180e1097bee20f03425b74539 /synapse/replication/slave/storage/client_ips.py
parentFix lints (diff)
parentAdd index to `local_group_updates.stream_id` (#11231) (diff)
downloadsynapse-ec35be57e056a795f7ebe393c81ffcb5bccd5872.tar.xz
Merge branch 'develop' into madlittlemods/return-historical-events-in-order-from-backfill
Conflicts:
	scripts-dev/complement.sh
	synapse/handlers/federation_event.py
	synapse/handlers/message.py
	synapse/storage/databases/main/event_federation.py
Diffstat (limited to 'synapse/replication/slave/storage/client_ips.py')
-rw-r--r--synapse/replication/slave/storage/client_ips.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/synapse/replication/slave/storage/client_ips.py b/synapse/replication/slave/storage/client_ips.py

index 436d39c320..61cd7e5228 100644 --- a/synapse/replication/slave/storage/client_ips.py +++ b/synapse/replication/slave/storage/client_ips.py
@@ -12,15 +12,20 @@ # See the License for the specific language governing permissions and # limitations under the License. +from typing import TYPE_CHECKING + from synapse.storage.database import DatabasePool from synapse.storage.databases.main.client_ips import LAST_SEEN_GRANULARITY from synapse.util.caches.lrucache import LruCache from ._base import BaseSlavedStore +if TYPE_CHECKING: + from synapse.server import HomeServer + class SlavedClientIpStore(BaseSlavedStore): - def __init__(self, database: DatabasePool, db_conn, hs): + def __init__(self, database: DatabasePool, db_conn, hs: "HomeServer"): super().__init__(database, db_conn, hs) self.client_ip_last_seen: LruCache[tuple, int] = LruCache(