MCPcopy
hub / github.com/docker/docker-agent / RemoteRuntime

Struct RemoteRuntime

pkg/runtime/remote_runtime.go:31–52  ·  view source on GitHub ↗

RemoteRuntime implements the Runtime interface using a remote client. It works with any client that implements the RemoteClient interface, including both HTTP (Client) and Connect-RPC (ConnectRPCClient) clients.

Source from the content-addressed store, hash-verified

29// It works with any client that implements the RemoteClient interface,
30// including both HTTP (Client) and Connect-RPC (ConnectRPCClient) clients.
31type RemoteRuntime struct {
32 client RemoteClient
33 currentAgent string
34 agentFilename string
35 sessionID string
36 team *team.Team
37 pendingOAuthElicitation *ElicitationRequestEvent
38
39 // pendingModelOverride is the model ref to apply to the current agent
40 // on the next [RemoteRuntime.RunStream] call. It is set by
41 // [RemoteRuntime.SetAgentModel] and consumed once the override has
42 // been forwarded to the server, which persists it server-side as the
43 // session's per-agent override.
44 pendingMu sync.Mutex
45 pendingModelOverride string
46
47 // resolvedDefault caches the team's default agent name fetched from the
48 // server after a successful lookup, so [CurrentAgentName] stays an O(1)
49 // field read when no specific agent has been selected.
50 resolvedDefault string
51 resolvedDefaultMu sync.Mutex
52}
53
54// RemoteRuntimeOption is a function for configuring the RemoteRuntime
55type RemoteRuntimeOption func(*RemoteRuntime)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected