[Varnish] #1625: if(req.backend_hint == b1) compiles, but does nothing

Varnish varnish-bugs at varnish-cache.org
Thu Aug 27 09:01:49 CEST 2015

#1625: if(req.backend_hint == b1) compiles, but does nothing
 Reporter:  huguesalary  |       Owner:  phk
     Type:  defect       |      Status:  closed
 Priority:  normal       |   Milestone:
Component:  build        |     Version:  4.0.2
 Severity:  normal       |  Resolution:  worksforme
 Keywords:               |
Changes (by phk):

 * status:  new => closed
 * resolution:   => worksforme


 Apologies for taking so long to reply to this.

 The variable you want is beresp.backend, that gives you the actual backend
 the fetch was made from.  This variable is available in

 The trouble here is the way directors came into Varnish wasn't entirely
 thought out, and that caused directors like round-robin to have a "hidden"
 backend, which does the actual selection only at fetch-time.

 The real trouble is that people like to assign backends in vcl_recv{}, but
 doing too much work there is a waste of time for all cache-hits, so we
 want to keep it light-weight and not actually do the selection there.

 Varnish 5 will be a good time to revisit this.

Ticket URL: <https://www.varnish-cache.org/trac/ticket/1625#comment:4>
Varnish <https://varnish-cache.org/>
The Varnish HTTP Accelerator

More information about the varnish-bugs mailing list