mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-05-02 15:46:04 -04:00
Optionally track memory usage of each LruCache (#9881)
This will double count slightly in the presence of interned strings. It's off by default as it can consume a lot of resources.
This commit is contained in:
parent
1fb9a2d0bf
commit
ef889c98a6
8 changed files with 97 additions and 1 deletions
|
@ -454,6 +454,7 @@ def start(config_options):
|
|||
config.server.update_user_directory = False
|
||||
|
||||
synapse.events.USE_FROZEN_DICTS = config.use_frozen_dicts
|
||||
synapse.util.caches.TRACK_MEMORY_USAGE = config.caches.track_memory_usage
|
||||
|
||||
if config.server.gc_seconds:
|
||||
synapse.metrics.MIN_TIME_BETWEEN_GCS = config.server.gc_seconds
|
||||
|
|
|
@ -341,6 +341,7 @@ def setup(config_options):
|
|||
sys.exit(0)
|
||||
|
||||
events.USE_FROZEN_DICTS = config.use_frozen_dicts
|
||||
synapse.util.caches.TRACK_MEMORY_USAGE = config.caches.track_memory_usage
|
||||
|
||||
if config.server.gc_seconds:
|
||||
synapse.metrics.MIN_TIME_BETWEEN_GCS = config.server.gc_seconds
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue