From 1b45c4382b5d130e053fe28bde6a8bdaad02d6c4 Mon Sep 17 00:00:00 2001 From: Koichi ITO Date: Sat, 4 Apr 2026 06:31:25 +0900 Subject: [PATCH] [Doc] Note sticky session requirement for multi-instance deployments ## Motivation and Context PR #290 documented that `StreamableHTTPTransport` requires a single-process server. However, when running multiple server instances behind a load balancer, requests for the same session must be routed to the same instance since session state is stored in memory. This adds a note about using sticky sessions (session affinity) based on the `Mcp-Session-Id` header. ## How Has This Been Tested? Documentation-only change. ## Breaking Changes None. --- README.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/README.md b/README.md index 6da1928..7ae59f8 100644 --- a/README.md +++ b/README.md @@ -138,6 +138,11 @@ end > so it must run in a single process. Use a single-process server (e.g., Puma with `workers 0`). > Multi-process configurations (Unicorn, or Puma with `workers > 0`) fork separate processes that > do not share memory, which breaks session management and SSE connections. +> +> When running multiple server instances behind a load balancer, configure your load balancer to use +> sticky sessions (session affinity) so that requests with the same `Mcp-Session-Id` header are always +> routed to the same instance. +> > Stateless mode (`stateless: true`) does not use sessions and works with any server configuration. ### Configuration