MCPcopy
hub / github.com/containerd/containerd / Status

Method Status

core/sandbox/proxy/controller.go:175–195  ·  view source on GitHub ↗
(ctx context.Context, sandboxID string, verbose bool)

Source from the content-addressed store, hash-verified

173}
174
175func (s *remoteSandboxController) Status(ctx context.Context, sandboxID string, verbose bool) (sandbox.ControllerStatus, error) {
176 resp, err := s.client.Status(ctx, &api.ControllerStatusRequest{
177 SandboxID: sandboxID,
178 Verbose: verbose,
179 Sandboxer: s.sandboxerName,
180 })
181 if err != nil {
182 return sandbox.ControllerStatus{}, errgrpc.ToNative(err)
183 }
184 return sandbox.ControllerStatus{
185 SandboxID: sandboxID,
186 Pid: resp.GetPid(),
187 State: resp.GetState(),
188 Info: resp.GetInfo(),
189 CreatedAt: resp.GetCreatedAt().AsTime(),
190 ExitedAt: resp.GetExitedAt().AsTime(),
191 Extra: resp.GetExtra(),
192 Address: resp.GetAddress(),
193 Version: resp.GetVersion(),
194 }, nil
195}
196
197func (s *remoteSandboxController) Metrics(ctx context.Context, sandboxID string) (*types.Metric, error) {
198 resp, err := s.client.Metrics(ctx, &api.ControllerMetricsRequest{

Callers

nothing calls this directly

Calls 9

StatusMethod · 0.65
GetPidMethod · 0.65
GetStateMethod · 0.45
GetInfoMethod · 0.45
GetCreatedAtMethod · 0.45
GetExitedAtMethod · 0.45
GetExtraMethod · 0.45
GetAddressMethod · 0.45
GetVersionMethod · 0.45

Tested by

no test coverage detected