Skip to content

fix(schema): add timeout fields to embedded JSON schema#6908

Merged
lpcox merged 3 commits into
mainfrom
fix/schema-timeout-fields
Jun 2, 2026
Merged

fix(schema): add timeout fields to embedded JSON schema#6908
lpcox merged 3 commits into
mainfrom
fix/schema-timeout-fields

Conversation

@lpcox
Copy link
Copy Markdown
Collaborator

@lpcox lpcox commented Jun 2, 2026

Add connectTimeout, connect_timeout, toolTimeout, and tool_timeout to the HTTP server schema definition, and toolTimeout/tool_timeout to the stdio server schema. These fields are already supported by the config loader but were missing from the embedded schema, causing validation to reject configs that use legacy snake_case timeout fields.

Failing test fixed: TestLoadFromStdin_HTTPServerWithLegacySnakeCaseTimeoutFields

Add connectTimeout, connect_timeout, toolTimeout, and tool_timeout
to the httpServerConfig schema definition. Add toolTimeout and
tool_timeout to stdioServerConfig. These fields are already supported
by the config loader but were missing from the schema, causing
validation failures for configs using legacy snake_case timeout fields.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings June 2, 2026 18:21
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates the embedded MCP Gateway JSON Schema to recognize timeout fields that are already supported by the stdin config loader, preventing schema validation from rejecting otherwise-valid configurations (notably legacy snake_case timeout keys).

Changes:

  • Add connectTimeout/connect_timeout and toolTimeout/tool_timeout to the HTTP server schema definition.
  • Add toolTimeout/tool_timeout to the stdio server schema definition.
  • Reformat several schema arrays for readability/consistency.
Show a summary per file
File Description
internal/config/schema/mcp-gateway-config.schema.json Adds missing timeout fields (including legacy aliases) to the embedded schema so schema-validation matches supported stdin config fields.

Copilot's findings

Tip

Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

  • Files reviewed: 1/1 changed files
  • Comments generated: 2

Comment thread internal/config/schema/mcp-gateway-config.schema.json
Comment thread internal/config/schema/mcp-gateway-config.schema.json
lpcox and others added 2 commits June 2, 2026 15:49
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
@lpcox lpcox merged commit 218ef63 into main Jun 2, 2026
3 checks passed
@lpcox lpcox deleted the fix/schema-timeout-fields branch June 2, 2026 22:59
@github-actions github-actions Bot mentioned this pull request Jun 5, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants