Skip to content

feat(mcp): modular router with feature flags and runtime toolset selection#656

Merged
joshrotenberg merged 2 commits intomainfrom
feat/mcp-modular-router
Feb 6, 2026
Merged

feat(mcp): modular router with feature flags and runtime toolset selection#656
joshrotenberg merged 2 commits intomainfrom
feat/mcp-modular-router

Conversation

@joshrotenberg
Copy link
Collaborator

Summary

  • Split the monolithic build_router() into modular sub-routers using McpRouter::merge, where each tool domain (cloud, enterprise, database, app) owns its own router() and instructions() functions
  • Add compile-time feature flags (cloud, enterprise, database) to gate optional dependencies (redis-cloud, redis-enterprise, redis), allowing minimal builds with --no-default-features
  • Add runtime --tools CLI flag to enable/disable toolsets per invocation (e.g., --tools cloud,database)
  • Introduce an "app" toolset that bundles profile tools, resources, and prompts into a single category, supporting use cases where admin instances expose profile management while developer instances do not

Test plan

  • cargo clippy -p redisctl-mcp --all-features -- -D warnings passes clean
  • cargo check -p redisctl-mcp --no-default-features compiles clean
  • Individual feature combos (--features cloud, --features enterprise, --features database) all compile
  • cargo test -p redisctl-mcp --all-features passes (66 tests: 17 lib + 7 binary + 14 cloud integration + 27 enterprise integration + 1 doctest)
  • cargo fmt --check passes
  • --help output shows --tools flag with all four toolset options

…ction

Split the monolithic build_router() into modular sub-routers using
McpRouter::merge. Each tool domain (cloud, enterprise, database, app)
now owns its own router() and instructions() functions.

Add compile-time feature flags (cloud, enterprise, database) to gate
optional dependencies, and a runtime --tools CLI flag to enable/disable
toolsets per invocation.

The "app" toolset bundles profile tools, resources, and prompts into a
single category that can be excluded from developer-facing instances
while remaining available in admin instances.
Update tower-mcp from 0.3.4 to 0.4.0 and bump workspace MSRV to 1.90.
Also update time from 0.3.44 to 0.3.47 to resolve RUSTSEC-2026-0009.
@joshrotenberg joshrotenberg merged commit 45fad9c into main Feb 6, 2026
19 checks passed
@joshrotenberg joshrotenberg deleted the feat/mcp-modular-router branch February 6, 2026 19:54
@joshrotenberg joshrotenberg mentioned this pull request Feb 6, 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.

1 participant