docs: document MCP_GATEWAY_SHUTDOWN_TIMEOUT environment variable#7683
Merged
Conversation
…RIABLES.md and AGENTS.md
Copilot
AI
changed the title
[WIP] Fix missing documentation for MCP_GATEWAY_SHUTDOWN_TIMEOUT
docs: document MCP_GATEWAY_SHUTDOWN_TIMEOUT environment variable
Jun 17, 2026
Contributor
There was a problem hiding this comment.
Pull request overview
This PR documents the previously implemented MCP_GATEWAY_SHUTDOWN_TIMEOUT environment variable so operators can discover and tune the gateway’s graceful shutdown behavior (the env var provides the default for --shutdown-timeout, which is used by the shared HTTP server lifecycle code).
Changes:
- Added
MCP_GATEWAY_SHUTDOWN_TIMEOUTto the environment variables reference with default5sand Go-duration examples. - Added the same variable to
AGENTS.mdto keep the operator/agent quick reference in sync.
Show a summary per file
| File | Description |
|---|---|
| docs/ENVIRONMENT_VARIABLES.md | Adds the missing MCP_GATEWAY_SHUTDOWN_TIMEOUT entry to the main env var reference table near other timeout settings. |
| AGENTS.md | Adds a corresponding bullet under Environment Variables to keep AGENTS.md consistent with the docs reference. |
Copilot's findings
Tip
Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
- Files reviewed: 2/2 changed files
- Comments generated: 0
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MCP_GATEWAY_SHUTDOWN_TIMEOUTwas implemented ininternal/cmd/flags_serve.go(controls--shutdown-timeout, default5s) but absent from all documentation, making it undiscoverable for operators needing to tune graceful shutdown for long-running tool calls.Changes
docs/ENVIRONMENT_VARIABLES.md— Added row to the "Optional (Non-Containerized Mode)" table, grouped with other timeout variables betweenMCP_GATEWAY_SESSION_TIMEOUTandMCP_GATEWAY_TOOL_TIMEOUTAGENTS.md— Added bullet entry in the Environment Variables section at the same relative position