• Poul-Henning Kamp's avatar
    The acceptor already has a back-off feature for when we run out of · d44838bf
    Poul-Henning Kamp authored
    filedescriptors, generalize that concept and use it for all cases
    where we cannot accept and/or serve the connection:  (Lack of sessions,
    lack of workerthreads).
    
    This is controlled by three paramters:
    
    Everytime we run into trouble, we increase the sleep-time by:
    	acceptor_sleep_incr (0.001 s)
    
    But we never let it get above
    	acceptor_sleep_max  (0.050 s)
    
    Once we manage to accept and schedule a connection, we multiply
    the sleep-time by:
    	acceptor_sleep_decay (0.9)
    
    The default numbers are more or less picked out of thin air.
    
    Two new stats counters help us keep track of this:
    	accept_fail
    		where accept(2) returns error.  This can be out of
    		file-descriptors, but also clients which closed while
    		they were stuck in the accept-queue.  Under normal
    		operation, a minor trickle is probably to be expected.
    
    	client_drop
    		New connection dropped, because we could not get a
    		session for it, or because the workerthreads were
    		too busy.
    
    	client_drop_late
    		An previously served connection was dropped for the
    		same reasons.
    
    As always, feedback welcome.
    
    
    
    
    git-svn-id: http://www.varnish-cache.org/svn/trunk/varnish-cache@4497 d4fa192b-c00b-0410-8231-f00ffab90ce4
    d44838bf
Name
Last commit
Last update
..
Makefile.am Loading commit data...
acct_fields.h Loading commit data...
c.sh Loading commit data...
cache.h Loading commit data...
cache_acceptor.c Loading commit data...
cache_backend.c Loading commit data...
cache_backend.h Loading commit data...
cache_backend_cfg.c Loading commit data...
cache_backend_poll.c Loading commit data...
cache_backend_poll.h Loading commit data...
cache_ban.c Loading commit data...
cache_ban.h Loading commit data...
cache_center.c Loading commit data...
cache_cli.c Loading commit data...
cache_dir_random.c Loading commit data...
cache_dir_round_robin.c Loading commit data...
cache_esi.c Loading commit data...
cache_expire.c Loading commit data...
cache_fetch.c Loading commit data...
cache_hash.c Loading commit data...
cache_http.c Loading commit data...
cache_httpconn.c Loading commit data...
cache_lck.c Loading commit data...
cache_main.c Loading commit data...
cache_panic.c Loading commit data...
cache_pipe.c Loading commit data...
cache_pool.c Loading commit data...
cache_response.c Loading commit data...
cache_session.c Loading commit data...
cache_vary.c Loading commit data...
cache_vcl.c Loading commit data...
cache_vrt.c Loading commit data...
cache_vrt_re.c Loading commit data...
cache_waiter.h Loading commit data...
cache_waiter_epoll.c Loading commit data...
cache_waiter_kqueue.c Loading commit data...
cache_waiter_poll.c Loading commit data...
cache_waiter_ports.c Loading commit data...
cache_wrw.c Loading commit data...
cache_ws.c Loading commit data...
common.h Loading commit data...
default.vcl Loading commit data...
flint.lnt Loading commit data...
flint.sh Loading commit data...
hash_classic.c Loading commit data...
hash_critbit.c Loading commit data...
hash_simple_list.c Loading commit data...
hash_slinger.h Loading commit data...
heritage.h Loading commit data...
instance.c Loading commit data...
mgt.h Loading commit data...
mgt_child.c Loading commit data...
mgt_cli.c Loading commit data...
mgt_cli.h Loading commit data...
mgt_param.c Loading commit data...
mgt_pool.c Loading commit data...
mgt_vcc.c Loading commit data...
rfc2616.c Loading commit data...
s.sh Loading commit data...
shmlog.c Loading commit data...
steps.h Loading commit data...
stevedore.c Loading commit data...
stevedore.h Loading commit data...
stevedore_utils.c Loading commit data...
storage_file.c Loading commit data...
storage_malloc.c Loading commit data...
storage_persistent.c Loading commit data...
storage_synth.c Loading commit data...
storage_umem.c Loading commit data...
varnishd.1 Loading commit data...
varnishd.c Loading commit data...
vclflint.lnt Loading commit data...
vclflint.sh Loading commit data...
vparam.h Loading commit data...