server: sandbox_remove: add comment on sandbox not found empty response

Signed-off-by: Antonio Murdaca <runcom@redhat.com>
This commit is contained in:
Antonio Murdaca 2017-05-22 16:38:10 +02:00
parent d099e3a988
commit 5f53416611
No known key found for this signature in database
GPG key ID: B2BEAD150DE936B9

View file

@ -21,6 +21,10 @@ func (s *Server) RemovePodSandbox(ctx context.Context, req *pb.RemovePodSandboxR
return nil, err
}
// If the sandbox isn't found we just return an empty response to adhere
// the the CRI interface which expects to not error out in not found
// cases.
resp := &pb.RemovePodSandboxResponse{}
logrus.Warnf("could not get sandbox %s, it's probably been removed already: %v", req.PodSandboxId, err)
return resp, nil