Browse Source

Moved teh max_threads multiplier

Patrick Falls 12 years ago
parent
commit
c16d5519fe
1 changed files with 2 additions and 2 deletions
  1. 2 2
      django/setup.py

+ 2 - 2
django/setup.py

@@ -11,9 +11,9 @@ def start(args):
   setup_util.replace_text("django/hello/hello/settings.py", "\/home\/ubuntu",  home)
   # because pooling doesn't work with meinheld, it's necessary to create a ton of gunicorn threads (think apache pre-fork)
   # to allow the OS to switch processes when waiting for socket I/O.
-  args.max_threads *= 8
+  #args.max_threads *= 8
   # and go from there until the database server runs out of memory for new threads (connections)
-  subprocess.Popen("gunicorn hello.wsgi:application --worker-class=\"egg:meinheld#gunicorn_worker\"  -b 0.0.0.0:8080 -w " + str((args.max_threads * 2)) + " --log-level=critical", shell=True, cwd="django/hello")
+  subprocess.Popen("gunicorn hello.wsgi:application --worker-class=\"egg:meinheld#gunicorn_worker\"  -b 0.0.0.0:8080 -w " + str((args.max_threads * 8)) + " --log-level=critical", shell=True, cwd="django/hello")
   return 0
 def stop():
   p = subprocess.Popen(['ps', 'aux'], stdout=subprocess.PIPE)