nginx/src
Vladimir Homutov 104734f218 Upstream: added sticky sessions support for upstreams.
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->sid, and to select the server, given it's SID.

- other balancing modules are allowed to set the pc->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 <ru@nginx.com>
Co-authored-by: Roman Arutyunyan <arut@nginx.com>
Co-authored-by: Maxim Dounin <mdounin@mdounin.ru>
2026-03-09 11:08:30 -06:00
..
core Resolver: fixed off-by-one read in ngx_resolver_copy(). 2026-02-23 22:12:32 +04:00
event Upstream: added sticky sessions support for upstreams. 2026-03-09 11:08:30 -06:00
http Upstream: added sticky sessions support for upstreams. 2026-03-09 11:08:30 -06:00
mail Mail: fixed type overflow in IMAP literal length parser. 2026-03-04 12:08:09 +04:00
misc
os Win32: fixed C4319 warning with MSVC 2022 x86. 2025-12-24 11:41:43 -07:00
stream Add basic ECH shared-mode via OpenSSL. 2025-12-01 16:33:40 +04:00