<div dir="ltr">Hi!<div><br></div><div>We know that consistent hash upstream improve its selection in the latest version.</div><div><br></div><div><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px;font-size:12px;color:rgb(0,0,0)"><span id="gmail-l1.19" class="gmail-minusline" style="color:rgb(220,20,60);white-space:pre-wrap;display:inline-block;box-sizing:border-box;width:1122px;padding:1px 0px 1px 5em">- if (hp->tries >= points->number) {</span><a href="http://hg.nginx.org/nginx/rev/6c52b24fcf8e#l1.19" style="text-decoration-line:none;display:inline-block;width:4em;height:1em"></a>
<span id="gmail-l1.20" class="gmail-minusline" style="color:rgb(220,20,60);white-space:pre-wrap;display:inline-block;box-sizing:border-box;width:1122px;padding:1px 0px 1px 5em">- pc->name = hp->rrp.peers->name;</span><a href="http://hg.nginx.org/nginx/rev/6c52b24fcf8e#l1.20" style="text-decoration-line:none;display:inline-block;width:4em;height:1em"></a>
<span id="gmail-l1.21" class="gmail-plusline" style="color:green;white-space:pre-wrap;display:inline-block;box-sizing:border-box;width:1122px;padding:1px 0px 1px 5em">+ if (hp->tries > 20) {</span><a href="http://hg.nginx.org/nginx/rev/6c52b24fcf8e#l1.21" style="text-decoration-line:none;display:inline-block;width:4em;height:1em"></a>
<span id="gmail-l1.22" style="white-space:pre-wrap;display:inline-block;box-sizing:border-box;width:1122px;padding:1px 0px 1px 5em"> ngx_http_upstream_rr_peers_unlock(hp->rrp.peers);</span><a href="http://hg.nginx.org/nginx/rev/6c52b24fcf8e#l1.22" style="text-decoration-line:none;display:inline-block;width:4em;height:1em"></a>
<span id="gmail-l1.23" class="gmail-minusline" style="color:rgb(220,20,60);white-space:pre-wrap;display:inline-block;box-sizing:border-box;width:1122px;padding:1px 0px 1px 5em">- return NGX_BUSY;</span><a href="http://hg.nginx.org/nginx/rev/6c52b24fcf8e#l1.23" style="text-decoration-line:none;display:inline-block;width:4em;height:1em"></a>
<span id="gmail-l1.24" class="gmail-plusline" style="color:green;white-space:pre-wrap;display:inline-block;box-sizing:border-box;width:1122px;padding:1px 0px 1px 5em">+ return hp->get_rr_peer(pc, &hp->rrp);</span></pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px;font-size:12px;color:rgb(0,0,0)"><span class="gmail-plusline" style="color:green;white-space:pre-wrap;display:inline-block;box-sizing:border-box;width:1122px;padding:1px 0px 1px 5em"><br></span></pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px;font-size:12px;color:rgb(0,0,0)"><br></pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px;font-size:12px">Does it mean that "backup" option is allowed in the module?</pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px;font-size:12px"><br></pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px"> |NGX_HTTP_UPSTREAM_MAX_CONNS
|NGX_HTTP_UPSTREAM_MAX_FAILS
|NGX_HTTP_UPSTREAM_FAIL_TIMEOUT
+ |NGX_HTTP_UPSTREAM_BACKUP
|NGX_HTTP_UPSTREAM_DOWN;</pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px"><br></pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px">I wonder how to archive the effect of "backup" in hash like round robin,</pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px">even if we don't want to use error_page.</pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px"><br></pre><pre class="gmail-sourcelines gmail-wrap" style="margin-top:0px;margin-bottom:0px">Thanks.<br>
</pre></div></div>