MCPcopy Index your code
hub / github.com/docker/docker-agent / New

Function New

pkg/runtime/runtime.go:561–563  ·  view source on GitHub ↗

New creates a runtime ready to drive an agent loop. It is a thin alias for [NewLocalRuntime] returning the [Runtime] interface, kept for source compatibility with callers written before persistence became an [EventObserver]. Persistence is auto-registered against the configured (or default in-memory

(ctx context.Context, agents *team.Team, opts ...Opt)

Source from the content-addressed store, hash-verified

559// [WithSessionStore] to override and [WithEventObserver] to layer
560// additional observers (telemetry, audit, ...).
561func New(ctx context.Context, agents *team.Team, opts ...Opt) (Runtime, error) {
562 return NewLocalRuntime(ctx, agents, opts...)
563}
564
565// NewLocalRuntime creates a new LocalRuntime without the persistence wrapper.
566// This is useful for testing or when persistence is handled externally.

Callers 15

GetMethod · 0.92
runDockerAgentFunction · 0.92
CreateToolHandlerFunction · 0.92
runtimeForSessionMethod · 0.92
newRuntimeMethod · 0.92
runNewCommandMethod · 0.92
createSessionSpawnerMethod · 0.92
runFunction · 0.92
runFunction · 0.92
runFunction · 0.92

Calls 1

NewLocalRuntimeFunction · 0.85