Merge pull request #9903 from abel-von/add-update-resource-only

sandbox: Add Update API for sandbox controller
This commit is contained in:
Fu Wei
2024-07-01 15:16:21 +00:00
committed by GitHub
20 changed files with 1216 additions and 752 deletions

View File

@@ -156,6 +156,14 @@ func (c *Controller) Wait(ctx context.Context, sandboxID string) (sandbox.ExitSt
}
func (c *Controller) Update(
ctx context.Context,
sandboxID string,
sandbox sandbox.Sandbox,
fields ...string) error {
return nil
}
func (c *Controller) waitSandboxExit(ctx context.Context, p *types.PodSandbox, exitCh <-chan containerd.ExitStatus) error {
select {
case e := <-exitCh:

View File

@@ -105,6 +105,14 @@ func (f fakeSandboxController) Metrics(ctx context.Context, sandboxID string) (*
return &types.Metric{}, errdefs.ErrNotImplemented
}
func (f *fakeSandboxController) Update(
ctx context.Context,
sandboxID string,
sandbox sandbox.Sandbox,
fields ...string) error {
return errdefs.ErrNotImplemented
}
type fakeRuntimeService struct {
ocispecs map[string]*oci.Spec
}