(
        self, bind_addr, wsgi_app, numthreads=10, server_name=None,
        max=-1, request_queue_size=5, timeout=10, shutdown_timeout=5,
        accepted_queue_size=-1, accepted_queue_timeout=10,
        peercreds_enabled=False, peercreds_resolve_enabled=False,
    )
Initialize WSGI Server instance.

        Args:
            bind_addr (tuple): network interface to listen to
            wsgi_app (callable): WSGI application callable
            numthreads (int): number of threads for WSGI thread pool
            server_name (str): web server name to be advertised via
                Server HTTP header
            max (int): maximum number of worker threads
            request_queue_size (int): the 'backlog' arg to
                socket.listen(); max queued connections
            timeout (int): the timeout in seconds for accepted connections
            shutdown_timeout (int): the total time, in seconds, to
                wait for worker threads to cleanly exit
            accepted_queue_size (int): maximum number of active
                requests in queue
            accepted_queue_timeout (int): timeout for putting request
                into queue
Initialize WSGI Server instance.
Initialize WSGI Server instance .
def __init__(
        self, bind_addr, wsgi_app, numthreads=10, server_name=None,
        max=-1, request_queue_size=5, timeout=10, shutdown_timeout=5,
        accepted_queue_size=-1, accepted_queue_timeout=10,
        peercreds_enabled=False, peercreds_resolve_enabled=False,
    ):
        """Initialize WSGI Server instance.

        Args:
            bind_addr (tuple): network interface to listen to
            wsgi_app (callable): WSGI application callable
            numthreads (int): number of threads for WSGI thread pool
            server_name (str): web server name to be advertised via
                Server HTTP header
            max (int): maximum number of worker threads
            request_queue_size (int): the 'backlog' arg to
                socket.listen(); max queued connections
            timeout (int): the timeout in seconds for accepted connections
            shutdown_timeout (int): the total time, in seconds, to
                wait for worker threads to cleanly exit
            accepted_queue_size (int): maximum number of active
                requests in queue
            accepted_queue_timeout (int): timeout for putting request
                into queue
        """
        super(Server, self).__init__(
            bind_addr,
            gateway=wsgi_gateways[self.wsgi_version],
            server_name=server_name,
            peercreds_enabled=peercreds_enabled,
            peercreds_resolve_enabled=peercreds_resolve_enabled,
        )
        self.wsgi_app = wsgi_app
        self.request_queue_size = request_queue_size
        self.timeout = timeout
        self.shutdown_timeout = shutdown_timeout
        self.requests = threadpool.ThreadPool(
            self, min=numthreads or 1, max=max,
            accepted_queue_size=accepted_queue_size,
            accepted_queue_timeout=accepted_queue_timeout,
        )
def __init__ ( self , bind_addr , wsgi_app , numthreads = 10 , server_name = None , max = - 1 , request_queue_size = 5 , timeout = 10 , shutdown_timeout = 5 , accepted_queue_size = - 1 , accepted_queue_timeout = 10 , peercreds_enabled = False , peercreds_resolve_enabled = False , ) : super ( Server , self ) . __init__ ( bind_addr , gateway = wsgi_gateways [ self . wsgi_version ] , server_name = server_name , peercreds_enabled = peercreds_enabled , peercreds_resolve_enabled = peercreds_resolve_enabled , ) self . wsgi_app = wsgi_app self . request_queue_size = request_queue_size self . timeout = timeout self . shutdown_timeout = shutdown_timeout self . requests = threadpool . ThreadPool ( self , min = numthreads or 1 , max = max , accepted_queue_size = accepted_queue_size , accepted_queue_timeout = accepted_queue_timeout , )