embabel-agent
embabel-agent copied to clipboard
Allow selective configuration of MCP servers when using @EnableAgents annotation
Allow selective configuration of MCP servers when using @EnableAgents annotation
Description
Currently, when using @EnableAgents(mcpServers = {McpServers.DOCKER}), the framework automatically spins up multiple MCP servers (github, google-maps, etc.) that may not be needed for a specific application context. This creates unnecessary resource overhead and potential security surface area.
Current Behavior
-
@EnableAgentswithMcpServers.DOCKERenables all available MCP servers by default - No mechanism exists to disable unwanted servers
- Configuration only allows adding additional servers via
embabel.agent.platform.tools.includes
Desired Behavior
Provide configuration options to:
- Exclude specific servers: Allow developers to disable unwanted MCP servers
- Include-only mode: Allow specifying only the required servers instead of defaulting to all
- Maintain backward compatibility: Existing configurations should continue working
Business Value
- Reduced resource consumption for applications that only need specific MCP capabilities
- Improved security posture by minimizing exposed services
- Better alignment with Domain Driven Design principles of explicit bounded context configuration
- Enhanced developer experience through granular control
Acceptance Criteria
- [ ] Developers can exclude specific MCP servers from the default set
- [ ] Developers can specify an include-only list of required servers
- [ ] Existing applications using current configuration continue to work unchanged
- [ ] Configuration follows Spring Framework conventions for consistency
Additional Context
As noted by @springrod, currently there is no way to disable servers you don't need, although they will not be exposed to actions unless explicitly requested. The framework should make the entire MCP server selection configurable.
@jamesward, your contributions are welcome.