<div dir="ltr">A director is considered healthy is any of its backend is healthy, so if you put a director in req.backend_hint, you're good.</div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature" data-smartmail="gmail_signature"><div dir="ltr"><div>-- <br></div>Guillaume Quintard<br></div></div></div>
<br><div class="gmail_quote">On Wed, Dec 7, 2016 at 9:29 AM, Thijs Cramer <span dir="ltr"><<a href="mailto:t.cramer@beslist.nl" target="_blank">t.cramer@beslist.nl</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Given the following code:<br>
<br>
==============================<wbr>===========<br>
sub vcl_synth {<br>
  if (resp.status == 999) {<br>
    set resp.status = 200;<br>
    set resp.http.Content-Type = "text/html; charset=utf-8";<br>
    synthetic( {"Static HTML"} );<br>
    return(deliver);<br>
  }<br>
}<br>
<br>
# Check if backend is healthy, otherwise, redirect<br>
if (!std.healthy(req.backend_<wbr>hint)) {<br>
  return (synth(999, "All backends down."));<br>
}<br>
<br>
==============================<wbr>===========<br>
<br>
Will the static page be served if ALL backends are down, or just when<br>
the specific backend it got back from the backend_hint is down?<br>
<br>
We want to be able to serve static html as a fallback if all backends<br>
are down.<br>
<br>
Is this the proper way to do this?<br>
<br>
Thanks in advance!<br>
<br>
- Thijs<br>
<br>
______________________________<wbr>_________________<br>
varnish-misc mailing list<br>
<a href="mailto:varnish-misc@varnish-cache.org">varnish-misc@varnish-cache.org</a><br>
<a href="https://www.varnish-cache.org/lists/mailman/listinfo/varnish-misc" rel="noreferrer" target="_blank">https://www.varnish-cache.org/<wbr>lists/mailman/listinfo/<wbr>varnish-misc</a></blockquote></div><br></div>