Documentation
¶
Index ¶
- Variables
- type Config
- type Daemon
- type FlatFormatTransformer
- type LockFile
- type Service
- func (s *Service) AddServer(ctx context.Context, req *pb.AddServerRequest) (*pb.ServerResponse, error)
- func (s *Service) DisableServer(ctx context.Context, req *pb.DisableServerRequest) (*pb.ServerResponse, error)
- func (s *Service) EnableServer(ctx context.Context, req *pb.EnableServerRequest) (*pb.ServerResponse, error)
- func (s *Service) GetAutoSyncStatus(ctx context.Context, req *emptypb.Empty) (*pb.AutoSyncStatus, error)
- func (s *Service) GetConfig(ctx context.Context, req *emptypb.Empty) (*pb.Config, error)
- func (s *Service) GetProjectConfig(ctx context.Context, req *pb.GetProjectConfigRequest) (*pb.ProjectConfigResponse, error)
- func (s *Service) GetServer(ctx context.Context, req *pb.GetServerRequest) (*pb.ServerResponse, error)
- func (s *Service) GetStatus(ctx context.Context, req *emptypb.Empty) (*pb.DaemonStatus, error)
- func (s *Service) ListProjects(ctx context.Context, req *emptypb.Empty) (*pb.ListProjectsResponse, error)
- func (s *Service) ListServers(ctx context.Context, req *pb.ListServersRequest) (*pb.ListServersResponse, error)
- func (s *Service) ListServersCorrected(ctx context.Context, req *pb.ListServersRequest) (*pb.ListServersResponse, error)
- func (s *Service) LoadConfig(ctx context.Context, req *pb.LoadConfigRequest) (*emptypb.Empty, error)
- func (s *Service) RegisterProject(ctx context.Context, req *pb.RegisterProjectRequest) (*emptypb.Empty, error)
- func (s *Service) RemoveServer(ctx context.Context, req *pb.RemoveServerRequest) (*emptypb.Empty, error)
- func (s *Service) SaveConfig(ctx context.Context, req *emptypb.Empty) (*emptypb.Empty, error)
- func (s *Service) ScanForProjects(ctx context.Context, req *pb.ScanForProjectsRequest) (*pb.ScanForProjectsResponse, error)
- func (s *Service) SetConfig(ctx context.Context, req *pb.Config) (*emptypb.Empty, error)
- func (s *Service) Shutdown(ctx context.Context, req *emptypb.Empty) (*emptypb.Empty, error)
- func (s *Service) StartAutoSync(ctx context.Context, req *pb.AutoSyncConfig) (*emptypb.Empty, error)
- func (s *Service) StopAutoSync(ctx context.Context, req *emptypb.Empty) (*emptypb.Empty, error)
- func (s *Service) SyncTo(ctx context.Context, req *pb.SyncToRequest) (*pb.SyncResult, error)
- func (s *Service) SyncToMultiple(ctx context.Context, req *pb.SyncToMultipleRequest) (*pb.MultiSyncResult, error)
- func (s *Service) UpdateServer(ctx context.Context, req *pb.UpdateServerRequest) (*pb.ServerResponse, error)
- type VersionInfo
- type ZedFormatTransformer
Constants ¶
This section is empty.
Variables ¶
var ( Version = "dev" GitCommit = "unknown" BuildDate = "unknown" )
Version info (set by ldflags during build)
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// Storage
StoragePath string `json:"storage_path,omitempty"`
// Network
SocketPath string `json:"socket_path,omitempty"`
Port int `json:"port,omitempty"`
// Logging
LogLevel string `json:"log_level,omitempty"`
LogFile string `json:"log_file,omitempty"`
// Behavior
IdleTimeout time.Duration `json:"idle_timeout,omitempty"`
EnableSystemd bool `json:"enable_systemd,omitempty"`
// Security
AllowedClients []string `json:"allowed_clients,omitempty"`
}
Config holds daemon configuration
func (*Config) LoadFromFile ¶
LoadFromFile loads config from JSON file
func (*Config) SaveToFile ¶
SaveToFile saves config to JSON file
func (*Config) SetDefaults ¶
func (c *Config) SetDefaults()
SetDefaults sets default values for config
type Daemon ¶
type Daemon struct {
// contains filtered or unexported fields
}
Daemon represents the agent-master daemon
type FlatFormatTransformer ¶ added in v0.1.10
type FlatFormatTransformer struct{}
FlatFormatTransformer transforms config to flat format (mcpServers at root)
func (*FlatFormatTransformer) Format ¶ added in v0.1.10
func (f *FlatFormatTransformer) Format() string
type LockFile ¶
type LockFile struct {
// contains filtered or unexported fields
}
LockFile provides file-based locking using flock
func NewLockFile ¶
NewLockFile creates a new lock file instance
func (*LockFile) TryAcquire ¶
TryAcquire attempts to acquire an exclusive lock
type Service ¶
type Service struct {
pb.UnimplementedAgentMasterDaemonServer
// contains filtered or unexported fields
}
Service implements the gRPC service
func (*Service) AddServer ¶
func (s *Service) AddServer(ctx context.Context, req *pb.AddServerRequest) (*pb.ServerResponse, error)
func (*Service) DisableServer ¶
func (s *Service) DisableServer(ctx context.Context, req *pb.DisableServerRequest) (*pb.ServerResponse, error)
func (*Service) EnableServer ¶
func (s *Service) EnableServer(ctx context.Context, req *pb.EnableServerRequest) (*pb.ServerResponse, error)
Enable/Disable server methods (using proper engine methods)
func (*Service) GetAutoSyncStatus ¶
func (*Service) GetProjectConfig ¶ added in v0.1.10
func (s *Service) GetProjectConfig(ctx context.Context, req *pb.GetProjectConfigRequest) (*pb.ProjectConfigResponse, error)
func (*Service) GetServer ¶
func (s *Service) GetServer(ctx context.Context, req *pb.GetServerRequest) (*pb.ServerResponse, error)
func (*Service) ListProjects ¶ added in v0.1.10
func (*Service) ListServers ¶
func (s *Service) ListServers(ctx context.Context, req *pb.ListServersRequest) (*pb.ListServersResponse, error)
ListServers is implemented in service_fixes.go as ListServersCorrected
func (*Service) ListServersCorrected ¶
func (s *Service) ListServersCorrected(ctx context.Context, req *pb.ListServersRequest) (*pb.ListServersResponse, error)
Fixed ListServers to match actual field names
func (*Service) LoadConfig ¶ added in v0.1.8
func (*Service) RegisterProject ¶ added in v0.1.10
func (*Service) RemoveServer ¶
func (*Service) SaveConfig ¶ added in v0.1.8
func (*Service) ScanForProjects ¶ added in v0.1.10
func (s *Service) ScanForProjects(ctx context.Context, req *pb.ScanForProjectsRequest) (*pb.ScanForProjectsResponse, error)
Project management methods
func (*Service) StartAutoSync ¶
func (*Service) StopAutoSync ¶
func (*Service) SyncTo ¶
func (s *Service) SyncTo(ctx context.Context, req *pb.SyncToRequest) (*pb.SyncResult, error)
func (*Service) SyncToMultiple ¶
func (s *Service) SyncToMultiple(ctx context.Context, req *pb.SyncToMultipleRequest) (*pb.MultiSyncResult, error)
func (*Service) UpdateServer ¶
func (s *Service) UpdateServer(ctx context.Context, req *pb.UpdateServerRequest) (*pb.ServerResponse, error)
type VersionInfo ¶ added in v0.1.10
GetVersionInfo returns version information as a struct
func GetVersionInfo ¶ added in v0.1.10
func GetVersionInfo() VersionInfo
GetVersionInfo returns the current version information
type ZedFormatTransformer ¶ added in v0.1.10
type ZedFormatTransformer struct{}
ZedFormatTransformer transforms config to Zed's format (under context_servers)
func (*ZedFormatTransformer) Format ¶ added in v0.1.10
func (z *ZedFormatTransformer) Format() string