[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[snapshot/master] 10 threads max per process, since for now every thread might need a db handle and we do not want to run out of those



---
 etc/apache.conf                     |    2 +-
 web/app/snapshot/lib/app_globals.py |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/etc/apache.conf b/etc/apache.conf
index 459d21e..8ffb6ec 100644
--- a/etc/apache.conf
+++ b/etc/apache.conf
@@ -1,6 +1,6 @@
 # vim: set ts=2 sw=2 et si sm:
 
-WSGIDaemonProcess snapshot.debian.org user=nobody group=nogroup home=/ processes=4 threads=40 maximum-requests=5000 inactivity-timeout=1800 umask=0077 display-name=wsgi-snapshot.debian.org
+WSGIDaemonProcess snapshot.debian.org user=nobody group=nogroup home=/ processes=4 threads=10 maximum-requests=5000 inactivity-timeout=1800 umask=0077 display-name=wsgi-snapshot.debian.org
 
 <VirtualHost *:80>
   ServerName snapshot.debian.org
diff --git a/web/app/snapshot/lib/app_globals.py b/web/app/snapshot/lib/app_globals.py
index 793cbd3..ba3ab5d 100644
--- a/web/app/snapshot/lib/app_globals.py
+++ b/web/app/snapshot/lib/app_globals.py
@@ -25,7 +25,7 @@ class Globals(object):
             newkey = key.replace("snapshot.db.", '', 1)
             db_config[newkey] = app_conf[key]
 
-        self.pool = psycopg2.pool.ThreadedConnectionPool(5, 20, **db_config)
+        self.pool = psycopg2.pool.ThreadedConnectionPool(5, 10, **db_config)
         self.shm = SnapshotModel(app_conf['snapshot.farmpath'], self.pool)
 
         default_expires = {}
-- 
1.5.6.5


Reply to: