mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-10-19 21:46:49 +00:00
d320007627
Three separate causes for the reconnect-per-tool-call pain: - no keep-alive on the standalone GET stream, so reverse proxies with idle timeouts (nginx default 60s) killed it between calls - send an SSE comment ping every 25s (MCP_SSE_KEEPALIVE, 0 = off) and count an open stream as session activity - the session TTL was hard-coded - MCP_SESSION_TTL (seconds, clamped to 24h) now works as the issue expected - every addon save invalidated ALL sessions: config-only saves, photo provider toggles and addons with no MCP surface included. Only a real enabled-flip of an MCP-relevant addon (or an actual collab-feature change) tears sessions down now.