Skip to content

Commit ddada64

Browse files
authored
Increase number of Python/flask workers (TechEmpower#5824)
As per: http://calpaterson.com/async-python-is-not-faster.html The number of gunicorn workers is probably too low for Flask. Cal recommends overshooting then dialling back (and also that the cost of too many workers is higher than the cost of too few), so I've upped the number of workers to a (seemingly crazy) 8.
1 parent 850a816 commit ddada64

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

frameworks/Python/flask/gunicorn_conf.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
_is_pypy = hasattr(sys, 'pypy_version_info')
66
_is_travis = os.environ.get('TRAVIS') == 'true'
77

8-
workers = multiprocessing.cpu_count() * 3
8+
workers = multiprocessing.cpu_count() * 8
99
if _is_travis:
1010
workers = 2
1111

0 commit comments

Comments
 (0)