• Nils Goroll's avatar
    wake up herder from sleeping after destroying, sleep for longer · f5d5587e
    Nils Goroll authored
    Previously, after sending a thread to varnish heaven, the herder slept
    for wthread_destroy_delay unconditionally. Instead, we now wait on the
    cv so we get woken up in case we run dry during the delay.
    
    This change is relevant proportionally to the value of
    wthread_destroy_delay if the spread between thread_pool_min and
    thread_pool_max is big and varnish is exposed to sudden traffic peaks.
    
    IOW, it will probably be only relevant for high performance setups.
    
    Also, we now sleep for thread_pool_timeout unless a shorter delay is
    warranted. This will delay the effect of thread parameter changes for
    up to thread_pool_timeout seconds unless the pool runs dry, in which
    case they will become effective immediately.
    f5d5587e
r01490.vtc 844 Bytes