Versions in this module Expand all Collapse all v0 v0.1.0 Aug 31, 2026 Changes in this version + var ErrMCPRuntimeUnavailable = errors.New("runtime is not running; run dataporch run") + type CommandRunner interface + Run func(context.Context, string, ...string) ([]byte, error) + func NewCommandRunner(command func(context.Context, string, ...string) *exec.Cmd) CommandRunner + type Dependencies struct + HealthChecker HealthChecker + InitializeSecrets func(config.Config) error + InvocationPath string + IsTerminal func(int) bool + LookupEnv config.LookupEnv + NewAdminClient func(string) (MCPTokenClient, error) + NewClient func(string) (ImportClient, error) + NewServiceManager func(config.Config) (ServiceManager, error) + ProtectedFileValidator ProtectedFileValidator + ReadConfirmation func(*os.File) (string, error) + ReadPassword func(int) ([]byte, error) + RunApplication func(context.Context, config.Config) error + RunMCPAdapter RunMCPAdapter + Stderr io.Writer + Stdin *os.File + Stdout io.Writer + UserHomeDir config.UserHomeDir + Version string + type EnvironmentVariable struct + Name string + Value string + type HealthChecker interface + Check func(context.Context, string) error + Wait func(context.Context, string) error + func NewHealthChecker() HealthChecker + type ImportClient interface + Import func(context.Context, connection.ImportRequest) (connection.ImportResult, error) + func NewUnixClient(socketPath string) (ImportClient, error) + type MCPTokenClient interface + CreateMCPToken func(context.Context) (string, mcptoken.Metadata, error) + MCPTokenStatus func(context.Context) (mcptoken.Status, error) + RevokeMCPToken func(context.Context) error + RotateMCPToken func(context.Context) (string, mcptoken.Metadata, error) + func NewMCPTokenClient(socketPath string) (MCPTokenClient, error) + type NativeState string + const NativeFailed + const NativeRunning + const NativeStopped + type NativeStatus struct + PID int + Registered bool + State NativeState + type ProtectedFileValidator func(string) error + type RunMCPAdapter func(context.Context, config.Config, io.Reader, io.Writer) error + type Runner struct + func New(dependencies Dependencies) (*Runner, error) + func (r *Runner) Execute(ctx context.Context, args []string) int + type ServiceDefinition struct + Arguments []string + Environment []EnvironmentVariable + Executable string + StderrPath string + StdoutPath string + type ServiceManager interface + DefinitionPath func() string + LogLocation func() string + Register func(context.Context, ServiceDefinition) error + Restart func(context.Context) error + Start func(context.Context) error + Status func(context.Context) (NativeStatus, error) + Stop func(context.Context) error + Unregister func(context.Context) error + func NewNativeServiceManager(goos, home string, uid int, runner CommandRunner) (ServiceManager, error)