aggregator

package
v0.3.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jun 8, 2026 License: Apache-2.0 Imports: 9 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type APIAdapter

type APIAdapter struct {
	// contains filtered or unexported fields
}

APIAdapter adapts the AggregatorService to implement api.AggregatorHandler

func NewAPIAdapter

func NewAPIAdapter(s *AggregatorService) *APIAdapter

NewAPIAdapter creates a new aggregator API adapter

func (*APIAdapter) CallTool

func (a *APIAdapter) CallTool(ctx context.Context, toolName string, args map[string]interface{}) (*api.CallToolResult, error)

CallTool calls a tool and returns the result in API format

func (*APIAdapter) CallToolInternal

func (a *APIAdapter) CallToolInternal(ctx context.Context, toolName string, args map[string]interface{}) (*mcp.CallToolResult, error)

CallToolInternal calls a tool and returns the raw MCP result

func (*APIAdapter) GetAvailableTools

func (a *APIAdapter) GetAvailableTools() []string

GetAvailableTools returns all available tools

func (*APIAdapter) GetEndpoint

func (a *APIAdapter) GetEndpoint() string

GetEndpoint returns the aggregator's SSE endpoint URL

func (*APIAdapter) GetPort

func (a *APIAdapter) GetPort() int

GetPort returns the aggregator port

func (*APIAdapter) GetServiceData

func (a *APIAdapter) GetServiceData() map[string]interface{}

GetServiceData returns aggregator service data

func (*APIAdapter) IsToolAvailable

func (a *APIAdapter) IsToolAvailable(toolName string) bool

IsToolAvailable checks if a tool is available

func (*APIAdapter) MissingToolsForSession added in v0.1.222

func (a *APIAdapter) MissingToolsForSession(ctx context.Context, toolNames []string) []string

MissingToolsForSession returns the subset of toolNames that is unavailable for the calling session, resolving SSO family tools against the session's accessible tool set (CapabilityStore) so availability is not order-dependent on a prior list_tools call. When the aggregator is unavailable, all requested tools are reported missing.

func (*APIAdapter) Register

func (a *APIAdapter) Register()

Register registers this adapter with the API package

func (*APIAdapter) RegisterServerPendingAuth

func (a *APIAdapter) RegisterServerPendingAuth(registration api.PendingAuthRegistration) error

RegisterServerPendingAuth registers a server that requires OAuth authentication.

func (*APIAdapter) UpdateCapabilities

func (a *APIAdapter) UpdateCapabilities()

UpdateCapabilities updates the aggregator's capabilities

type AggregatorService

type AggregatorService struct {
	*services.BaseService
	// contains filtered or unexported fields
}

AggregatorService implements the Service interface for the MCP aggregator This is a thin wrapper around AggregatorManager that handles only lifecycle management

func NewAggregatorService

func NewAggregatorService(
	config aggregator.AggregatorConfig,
	orchestratorAPI api.OrchestratorAPI,
	serviceRegistry api.ServiceRegistryHandler,
) *AggregatorService

NewAggregatorService creates a new aggregator service

func (*AggregatorService) GetEndpoint

func (s *AggregatorService) GetEndpoint() string

GetEndpoint returns the aggregator's SSE endpoint URL

func (*AggregatorService) GetManager

GetManager returns the underlying aggregator manager for advanced operations

func (*AggregatorService) GetServiceData

func (s *AggregatorService) GetServiceData() map[string]interface{}

GetServiceData implements ServiceDataProvider

func (*AggregatorService) ManualRefresh

func (s *AggregatorService) ManualRefresh(ctx context.Context) error

ManualRefresh manually triggers a refresh of healthy MCP server registrations This can be useful for debugging or forced updates

func (*AggregatorService) Restart

func (s *AggregatorService) Restart(ctx context.Context) error

Restart restarts the aggregator service

func (*AggregatorService) Start

func (s *AggregatorService) Start(ctx context.Context) error

Start starts the aggregator service

func (*AggregatorService) Stop

func (s *AggregatorService) Stop(ctx context.Context) error

Stop stops the aggregator service

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL