ServerProxyManager can act on behalf of multiple [ServerProxier]s. It aggregates all server resources (currently just tools) across all MCP servers for the purpose of injection into bridged requests and invocation.
| 20 | // It aggregates all server resources (currently just tools) across all MCP servers |
| 21 | // for the purpose of injection into bridged requests and invocation. |
| 22 | type ServerProxyManager struct { |
| 23 | proxiers map[string]ServerProxier |
| 24 | tracer trace.Tracer |
| 25 | |
| 26 | // Protects access to the tools map. |
| 27 | toolsMu sync.RWMutex |
| 28 | tools map[string]*Tool |
| 29 | } |
| 30 | |
| 31 | func NewServerProxyManager(proxiers map[string]ServerProxier, tracer trace.Tracer) *ServerProxyManager { |
| 32 | return &ServerProxyManager{ |
nothing calls this directly
no outgoing calls
no test coverage detected