mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 12:06:08 -04:00
Define CACHE_SIZE_FACTOR once
This commit is contained in:
parent
47574c9cba
commit
b5e8d529e6
5 changed files with 6 additions and 21 deletions
|
@ -20,7 +20,8 @@ from twisted.internet import defer, reactor
|
|||
from ._base import Cache
|
||||
from . import background_updates
|
||||
|
||||
import os
|
||||
from synapse.util.caches import CACHE_SIZE_FACTOR
|
||||
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
@ -30,9 +31,6 @@ logger = logging.getLogger(__name__)
|
|||
LAST_SEEN_GRANULARITY = 120 * 1000
|
||||
|
||||
|
||||
CACHE_SIZE_FACTOR = float(os.environ.get("SYNAPSE_CACHE_FACTOR", 0.1))
|
||||
|
||||
|
||||
class ClientIpStore(background_updates.BackgroundUpdateStore):
|
||||
def __init__(self, hs):
|
||||
self.client_ip_last_seen = Cache(
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue