diff --git a/etc/nova/nova.conf.sample b/etc/nova/nova.conf.sample index 0bc34996e1d5..a5057d20ad32 100644 --- a/etc/nova/nova.conf.sample +++ b/etc/nova/nova.conf.sample @@ -306,6 +306,10 @@ # socket. Not supported on OS X. (integer value) #tcp_keepidle=600 +# Size of the pool of greenthreads used by wsgi (integer +# value) +#wsgi_default_pool_size=1000 + # # Options defined in nova.api.auth diff --git a/nova/wsgi.py b/nova/wsgi.py index 9a4ab90d5a1a..dd128b2a4905 100644 --- a/nova/wsgi.py +++ b/nova/wsgi.py @@ -64,7 +64,10 @@ wsgi_opts = [ cfg.IntOpt('tcp_keepidle', default=600, help="Sets the value of TCP_KEEPIDLE in seconds for each " - "server socket. Not supported on OS X.") + "server socket. Not supported on OS X."), + cfg.IntOpt('wsgi_default_pool_size', + default=1000, + help="Size of the pool of greenthreads used by wsgi"), ] CONF = cfg.CONF CONF.register_opts(wsgi_opts) @@ -75,7 +78,7 @@ LOG = logging.getLogger(__name__) class Server(object): """Server class to manage a WSGI server, serving a WSGI application.""" - default_pool_size = 1000 + default_pool_size = CONF.wsgi_default_pool_size def __init__(self, name, app, host='0.0.0.0', port=0, pool_size=None, protocol=eventlet.wsgi.HttpProtocol, backlog=128,