From c5c5a7403bd1cb3c9e3a3529d220cb1ea55e89df Mon Sep 17 00:00:00 2001
From: Erik Johnston <erik@matrix.org>
Date: Mon, 16 May 2016 17:01:57 +0100
Subject: [PATCH] Make synctl read a cache factor from config file

---
 synapse/app/synctl.py | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/synapse/app/synctl.py b/synapse/app/synctl.py
index ab3a31d7b7..669a3ae92a 100755
--- a/synapse/app/synctl.py
+++ b/synapse/app/synctl.py
@@ -66,6 +66,10 @@ def main():
 
     config = yaml.load(open(configfile))
     pidfile = config["pid_file"]
+    cache_factor = config.get("synctl_cache_factor", None)
+
+    if cache_factor:
+        os.environ["SYNAPSE_CACHE_FACTOR"] = cache_factor
 
     action = sys.argv[1] if sys.argv[1:] else "usage"
     if action == "start":
-- 
GitLab