<feed xmlns='http://www.w3.org/2005/Atom'>
<title>nginx.git/src/http/ngx_http_upstream_round_robin.c, branch release-1.29.7</title>
<subtitle>nginx</subtitle>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/'/>
<entry>
<title>Sticky: added "draining" peer state.</title>
<updated>2026-03-09T17:08:30+00:00</updated>
<author>
<name>Vladimir Homutov</name>
<email>vl@nginx.com</email>
</author>
<published>2014-08-28T07:53:49+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=d12dd2405d659707f75eaa93d45ed762cc5bdd5d'/>
<id>d12dd2405d659707f75eaa93d45ed762cc5bdd5d</id>
<content type='text'>
While peer is draining, only sticky requests are served and the peer is never
selected to process new requests.

Co-authored-by: Ruslan Ermilov &lt;ru@nginx.com&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
While peer is draining, only sticky requests are served and the peer is never
selected to process new requests.

Co-authored-by: Ruslan Ermilov &lt;ru@nginx.com&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>Upstream: added sticky sessions support for upstreams.</title>
<updated>2026-03-09T17:08:30+00:00</updated>
<author>
<name>Vladimir Homutov</name>
<email>vl@nginx.com</email>
</author>
<published>2013-04-02T21:44:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=104734f21888cfec6994e092073f51a0d4b0fb47'/>
<id>104734f21888cfec6994e092073f51a0d4b0fb47</id>
<content type='text'>
Sticky sessions allow to route the same client to the same upstream server.

- upstream structures are extended to keep session-related information

- existing balancing modules are updated to provide an id of the selected
  server (SID) in pc-&gt;sid, and to select the server, given it's SID.

- other balancing modules are allowed to set the pc-&gt;hint value to choose
  the desired peer.  The sticky module will not change the hint if it's
  already set.

- the feature is enabled by default and can be disabled with the
  "--without-http_upstream_sticky" switch of the configure script.

The following configuration can be used to enable sticky sessions for
supported balancing modules:

    upstream u1 {
        server 127.0.0.1:8080;
        server 127.0.0.1:8081;

        sticky cookie server_id expires=1h domain=.example.com path=/;
    }

Co-authored-by: Ruslan Ermilov &lt;ru@nginx.com&gt;
Co-authored-by: Roman Arutyunyan &lt;arut@nginx.com&gt;
Co-authored-by: Maxim Dounin &lt;mdounin@mdounin.ru&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Sticky sessions allow to route the same client to the same upstream server.

- upstream structures are extended to keep session-related information

- existing balancing modules are updated to provide an id of the selected
  server (SID) in pc-&gt;sid, and to select the server, given it's SID.

- other balancing modules are allowed to set the pc-&gt;hint value to choose
  the desired peer.  The sticky module will not change the hint if it's
  already set.

- the feature is enabled by default and can be disabled with the
  "--without-http_upstream_sticky" switch of the configure script.

The following configuration can be used to enable sticky sessions for
supported balancing modules:

    upstream u1 {
        server 127.0.0.1:8080;
        server 127.0.0.1:8081;

        sticky cookie server_id expires=1h domain=.example.com path=/;
    }

Co-authored-by: Ruslan Ermilov &lt;ru@nginx.com&gt;
Co-authored-by: Roman Arutyunyan &lt;arut@nginx.com&gt;
Co-authored-by: Maxim Dounin &lt;mdounin@mdounin.ru&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>SSL: removed stale comments.</title>
<updated>2025-02-26T13:40:03+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2025-02-21T11:54:04+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=d16251969bf113272b577920940f020524d5fceb'/>
<id>d16251969bf113272b577920940f020524d5fceb</id>
<content type='text'>
It appears to be a relic from prototype locking removed in b0b7b5a35.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
It appears to be a relic from prototype locking removed in b0b7b5a35.
</pre>
</div>
</content>
</entry>
<entry>
<title>SSL: improved logging of saving sessions from upstream servers.</title>
<updated>2025-02-26T13:40:03+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2025-02-21T11:41:33+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=311c39037734df89b56325091e9435bc542308f4'/>
<id>311c39037734df89b56325091e9435bc542308f4</id>
<content type='text'>
This makes it easier to understand why sessions may not be saved
in shared memory due to size.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This makes it easier to understand why sessions may not be saved
in shared memory due to size.
</pre>
</div>
</content>
</entry>
<entry>
<title>SSL: using static storage for NGX_SSL_MAX_SESSION_SIZE buffers.</title>
<updated>2025-02-26T13:40:03+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2025-02-21T09:49:41+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=3d7304b527d1fb6eb697eb8719f286ba7b8e90de'/>
<id>3d7304b527d1fb6eb697eb8719f286ba7b8e90de</id>
<content type='text'>
All such transient buffers are converted to the single storage in BSS.

In preparation to raise the limit.
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
All such transient buffers are converted to the single storage in BSS.

In preparation to raise the limit.
</pre>
</div>
</content>
</entry>
<entry>
<title>Upstream: per-upstream resolver.</title>
<updated>2024-11-07T15:57:42+00:00</updated>
<author>
<name>Vladimir Homutov</name>
<email>vl@nginx.com</email>
</author>
<published>2019-10-18T13:33:15+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=ea4654550ab021b5576c03b708079e3ce3e5d9ed'/>
<id>ea4654550ab021b5576c03b708079e3ce3e5d9ed</id>
<content type='text'>
The "resolver" and "resolver_timeout" directives can now be specified
directly in the "upstream" block.</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The "resolver" and "resolver_timeout" directives can now be specified
directly in the "upstream" block.</pre>
</div>
</content>
</entry>
<entry>
<title>Upstream: construct upstream peers from DNS SRV records.</title>
<updated>2024-11-07T15:57:42+00:00</updated>
<author>
<name>Dmitry Volyntsev</name>
<email>xeioex@nginx.com</email>
</author>
<published>2016-03-17T15:42:31+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=9fe119b431c957824d7bed75fce47dfbda74ca33'/>
<id>9fe119b431c957824d7bed75fce47dfbda74ca33</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
<entry>
<title>Upstream: re-resolvable servers.</title>
<updated>2024-11-07T15:57:42+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@nginx.com</email>
</author>
<published>2014-02-15T11:12:34+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=db6870e06dde7ab249e9a41a0e0a76219f82dd8c'/>
<id>db6870e06dde7ab249e9a41a0e0a76219f82dd8c</id>
<content type='text'>
Specifying the upstream server by a hostname together with the
"resolve" parameter will make the hostname to be periodically
resolved, and upstream servers added/removed as necessary.

This requires a "resolver" at the "http" configuration block.

The "resolver_timeout" parameter also affects when the failed
DNS requests will be attempted again.  Responses with NXDOMAIN
will be attempted again in 10 seconds.

Upstream has a configuration generation number that is incremented each
time servers are added/removed to the primary/backup list.  This number
is remembered by the peer.init method, and if peer.get detects a change
in configuration, it returns NGX_BUSY.

Each server has a reference counter.  It is incremented by peer.get and
decremented by peer.free.  When a server is removed, it is removed from
the list of servers and is marked as "zombie".  The memory allocated by
a zombie peer is freed only when its reference count becomes zero.

Co-authored-by: Roman Arutyunyan &lt;arut@nginx.com&gt;
Co-authored-by: Sergey Kandaurov &lt;pluknet@nginx.com&gt;
Co-authored-by: Vladimir Homutov &lt;vl@nginx.com&gt;</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Specifying the upstream server by a hostname together with the
"resolve" parameter will make the hostname to be periodically
resolved, and upstream servers added/removed as necessary.

This requires a "resolver" at the "http" configuration block.

The "resolver_timeout" parameter also affects when the failed
DNS requests will be attempted again.  Responses with NXDOMAIN
will be attempted again in 10 seconds.

Upstream has a configuration generation number that is incremented each
time servers are added/removed to the primary/backup list.  This number
is remembered by the peer.init method, and if peer.get detects a change
in configuration, it returns NGX_BUSY.

Each server has a reference counter.  It is incremented by peer.get and
decremented by peer.free.  When a server is removed, it is removed from
the list of servers and is marked as "zombie".  The memory allocated by
a zombie peer is freed only when its reference count becomes zero.

Co-authored-by: Roman Arutyunyan &lt;arut@nginx.com&gt;
Co-authored-by: Sergey Kandaurov &lt;pluknet@nginx.com&gt;
Co-authored-by: Vladimir Homutov &lt;vl@nginx.com&gt;</pre>
</div>
</content>
</entry>
<entry>
<title>Upstream: excluded down servers from the next_upstream tries.</title>
<updated>2020-11-26T21:01:20+00:00</updated>
<author>
<name>Ruslan Ermilov</name>
<email>ru@nginx.com</email>
</author>
<published>2020-11-26T21:01:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=cfa669151e605410cfb57cc70b0e4023f4777602'/>
<id>cfa669151e605410cfb57cc70b0e4023f4777602</id>
<content type='text'>
Previously, the number of next_upstream tries included servers marked
as "down", resulting in "no live upstreams" with the code 502 instead
of the code derived from an attempt to connect to the last tried "up"
server (ticket #2096).
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously, the number of next_upstream tries included servers marked
as "down", resulting in "no live upstreams" with the code 502 instead
of the code derived from an attempt to connect to the last tried "up"
server (ticket #2096).
</pre>
</div>
</content>
</entry>
<entry>
<title>SSL: removed OpenSSL 0.9.7 compatibility.</title>
<updated>2016-04-11T12:46:36+00:00</updated>
<author>
<name>Sergey Kandaurov</name>
<email>pluknet@nginx.com</email>
</author>
<published>2016-04-11T12:46:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.sigsegv.uk/nginx.git/commit/?id=c17bc31d41a0372002115899a2c64e89aeca7e7d'/>
<id>c17bc31d41a0372002115899a2c64e89aeca7e7d</id>
<content type='text'>
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
</pre>
</div>
</content>
</entry>
</feed>
