]> git.kaiwu.me - nginx.git/commit
Upstream: least_time balancer module
authorVladimir Homutov <vl@nginx.com>
Fri, 28 Oct 2016 13:01:53 +0000 (16:01 +0300)
committerSai Krishna Kumar Reddy YADAMAKANTI <46914419+saikrishnakumarreddy@users.noreply.github.com>
Mon, 4 May 2026 15:49:40 +0000 (21:19 +0530)
commit5760d6148eb0be156df58bba0054bbc34a6c7942
tree4cc5a99d9004af4995648ec2427e3083d61cb349
parent45554176cafc12e0e234a6511b5b4cd453dc8a31
Upstream: least_time balancer module

The module implements load-balancing algorithm based on least average
response header/last_byte time and least number of active connections.

The optional "inflight" mode enables accounting of incomplete
requests/sessions.  This allows to mitigate cases when an upstream
server hangs and does not close connections.

Example configuration:

upstream u {
    least_time header | last_byte [inflight];
    server a;
    server b;
}

Co-authored-by: Roman Arutyunyan <arut@nginx.com>
auto/modules
auto/options
src/http/modules/ngx_http_upstream_least_time_module.c [new file with mode: 0644]
src/http/ngx_http_upstream_round_robin.h