python - Gunicorn with gevent workers and threads -


i have server 4 cores.

when setting gunicorn workers , threads can assign same number of workers , threads cpu's since doing different things?

for example

from gevent import monkey monkey.patch_all() import multiprocessing  workers = multiprocessing.cpu_count() * 2 + 1 bind = "127.0.0.1:5000" worker_class = 'gevent' worker_connections = 1000 threads = multiprocessing.cpu_count() * 2 + 1 

or should instead this

from gevent import monkey monkey.patch_all() import multiprocessing  workers = 2 * 2 + 1 bind = "127.0.0.1:5000" worker_class = 'gevent' worker_connections = 1000 threads = 2 * 2 + 1 


Comments

Popular posts from this blog

get url and add instance to a model with prefilled foreign key :django admin -

android - Keyboard hides my half of edit-text and button below it even in scroll view -

css - Make div keyboard-scrollable in jQuery Mobile? -