MCPcopy Index your code
hub / github.com/containerd/containerd / RemoveContainer

Method RemoveContainer

integration/nri_test.go:1084–1094  ·  view source on GitHub ↗
(ctx context.Context, pod *api.PodSandbox, ctr *api.Container)

Source from the content-addressed store, hash-verified

1082}
1083
1084func (m *mockPlugin) RemoveContainer(ctx context.Context, pod *api.PodSandbox, ctr *api.Container) error {
1085 if !m.inNamespace(pod.Namespace) {
1086 return nil
1087 }
1088
1089 m.Log("RemoveContainer %s/%s/%s", pod.Namespace, pod.Name, ctr.Name)
1090 delete(m.pods, pod.Id)
1091 delete(m.ctrs, ctr.Id)
1092 m.q.Add(ContainerEvent(ctr, RemoveContainer))
1093 return nil
1094}
1095
1096func (m *mockPlugin) Wait(e *Event, deadline <-chan time.Time) error {
1097 _, err := m.q.Wait(e, deadline)

Callers

nothing calls this directly

Calls 4

inNamespaceMethod · 0.95
LogMethod · 0.95
ContainerEventFunction · 0.85
AddMethod · 0.65

Tested by

no test coverage detected