Skip to content

feat(mcp,plugins): MCP startup retry backoff, tool timeout override, plugin disable enforcement#4568

Merged
bug-ops merged 2 commits into
mainfrom
claude-code-parity-mcp-plugins
May 28, 2026
Merged

feat(mcp,plugins): MCP startup retry backoff, tool timeout override, plugin disable enforcement#4568
bug-ops merged 2 commits into
mainfrom
claude-code-parity-mcp-plugins

Conversation

@bug-ops
Copy link
Copy Markdown
Owner

@bug-ops bug-ops commented May 28, 2026

Summary

Claude Code parity gaps from #4039 and #4004: three features implemented across zeph-mcp and zeph-plugins.

MCP startup retry backoff (zeph-mcp, zeph-config)

  • McpConfig.startup_retry_backoff_ms: u64 (default 1000 ms) configures exponential backoff between connection attempts
  • connect_retry_backoff(attempt, base_ms) uses caller-supplied base instead of hardcoded 500 ms
  • Config migration step 50 adds commented keys to existing configs

MCP per-call tool timeout override (zeph-mcp, zeph-config)

  • McpClient::call_tool_with_timeout(name, args, timeout) — new method with caller-supplied Duration
  • McpConfig.tool_timeout_secs: Option<u64> (default None) — only overrides per-server timeout when explicitly set; existing per-server timeouts are respected when this is absent
  • validate_tool_timeout_secs deserializer rejects values > 3600 s
  • with_tool_timeout_secs(0) clamped to 1 to prevent instant timeouts

Plugin disable dependency enforcement (zeph-plugins)

  • DisableResult { forced_over_dependents: Vec<String> } returned on success
  • disable(name, force: bool)force=false refuses with DependencyRequired when enabled plugins depend on target; force=true proceeds with WARN log
  • enable_recursive emits tracing::warn! when a transitive dependency re-enables an explicitly-disabled plugin

Test plan

  • cargo +nightly fmt --check — clean
  • cargo clippy --workspace -- -D warnings — clean
  • RUSTFLAGS="-D warnings" cargo check --workspace --all-targets --features desktop,ide,server,chat,pdf,scheduler --locked — clean
  • cargo nextest run --workspace --lib --bins — 10163/10163 passed
  • New test call_tool_uses_tool_timeout_branch_when_configured covers the Some(tool_timeout_secs) dispatch path
  • 3 new plugin disable --force tests

Breaking change

PluginManager::disable(name)disable(name, force: bool) — pass force: false to preserve prior behavior. Documented in CHANGELOG.md.

Closes #4039, #4004

…de, and plugin disable enforcement

MCP startup retry backoff (zeph-mcp, zeph-config):
- `McpConfig.startup_retry_backoff_ms: u64` (default 1000 ms) configures
  exponential backoff between connection attempts
- `connect_retry_backoff(attempt, base_ms)` uses caller-supplied base
  instead of hardcoded 500 ms
- `retry_loop` accepts `retry_backoff_base_ms` wired from `spawn_non_oauth_connections`
- Config migration step 50 adds commented keys to existing configs

MCP per-call tool timeout override (zeph-mcp, zeph-config):
- `McpClient::call_tool_with_timeout(name, args, timeout)` — new method
  with caller-supplied duration; `call_tool` delegates to it for backward compat
- `McpConfig.tool_timeout_secs: Option<u64>` (default None) — only overrides
  per-server timeout when explicitly set; existing per-server timeouts respected
- `validate_tool_timeout_secs` deserializer rejects values > 3600 s
- `with_tool_timeout_secs` clamps 0 to 1 to prevent instant timeouts
- Bootstrap wires both new fields into `McpManager`

Plugin disable dependency enforcement (zeph-plugins):
- `DisableResult { forced_over_dependents: Vec<String> }` — returned on success
- `disable(name, force: bool)` — `force=false` refuses with `DependencyRequired`
  when enabled plugins depend on target; `force=true` proceeds with WARN log

BREAKING: `PluginManager::disable(name)` → `disable(name, force: bool)`;
pass `force: false` to preserve prior behavior.

Closes #4039, #4004
@github-actions github-actions Bot added documentation Improvements or additions to documentation rust Rust code changes core zeph-core crate config Configuration file changes enhancement New feature or request size/XL Extra large PR (500+ lines) labels May 28, 2026
@bug-ops bug-ops enabled auto-merge (squash) May 28, 2026 21:33
@bug-ops bug-ops merged commit 1241568 into main May 28, 2026
32 checks passed
@bug-ops bug-ops deleted the claude-code-parity-mcp-plugins branch May 28, 2026 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

config Configuration file changes core zeph-core crate documentation Improvements or additions to documentation enhancement New feature or request rust Rust code changes size/XL Extra large PR (500+ lines)

Projects

None yet

1 participant