]> err.no Git - varnish/commit
When an object is being fetched from the backend, other requests for it
authorphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Tue, 11 Dec 2007 12:04:58 +0000 (12:04 +0000)
committerphk <phk@d4fa192b-c00b-0410-8231-f00ffab90ce4>
Tue, 11 Dec 2007 12:04:58 +0000 (12:04 +0000)
commitcf095fdd9e45c0ee824b5c7634add7fe61d06ec8
tree78bce30097a3be03470c2881b2e9228f39f42dd5
parente8eaf6d544270dfb42bbea77597a6b50c309bca0
When an object is being fetched from the backend, other requests for it
are parked not holding a worker thread, until the fetching session lowers
the busy bit on the object.

At that point we would release all the parked requests into the thread
pool to be serviced, causing instant congestion and calls for road-pricing
if the backend were a bit slow on an oft-requested object.

Change the restart policy to be paced exponential:

When we clear the busy bits, we unpark "rush_exponent" requests into
the thread pool to start the show.

Whenever the object is dereferenced, in practice whenever a request
has been serviced, another "rush_exponent" worth of requests are
unparked into the tread pool.

Set the parameter to a conservative 3 until we know more about the
behaviour in practice.

If it is a big object and/or the clients are on slow lines, 3 may
be an order of magnitude to small.

Attempts to fix: #188

git-svn-id: svn+ssh://projects.linpro.no/svn/varnish/trunk@2294 d4fa192b-c00b-0410-8231-f00ffab90ce4
varnish-cache/bin/varnishd/cache_hash.c
varnish-cache/bin/varnishd/heritage.h
varnish-cache/bin/varnishd/mgt_param.c