Skip to content

Add cleanup package for context management during cleanup#7861

Merged
fuweid merged 2 commits intocontainerd:mainfrom
dmcgowan:cleanup-context
Jan 5, 2023
Merged

Add cleanup package for context management during cleanup#7861
fuweid merged 2 commits intocontainerd:mainfrom
dmcgowan:cleanup-context

Conversation

@dmcgowan
Copy link
Copy Markdown
Member

Provides a couple helpers functions that provide a background context for running cleanup jobs while preserving the original context values. These new contexts will not inherit any errors or cancellations from the original context.

@k8s-ci-robot
Copy link
Copy Markdown

Skipping CI for Draft Pull Request.
If you want CI signal for your change, please convert it to an actual PR.
You can still manually trigger a test run with /test all

Comment thread pkg/cleanup/context.go
@dmcgowan
Copy link
Copy Markdown
Member Author

I added a test for pkg/cleanup

@dmcgowan dmcgowan marked this pull request as ready for review December 29, 2022 04:00
@AkihiroSuda
Copy link
Copy Markdown
Member

Needs rebase

Provides a couple helper functions that provide a background context for
running cleanup jobs while preserving the original context values.
The new contexts will not inherit the errors or cancellations.

Signed-off-by: Derek McGowan <[email protected]>
Comment thread rootfs/diff.go Outdated
Comment thread rootfs/diff.go Outdated
Use the cleanup context to re-use values from the original context

Signed-off-by: Derek McGowan <[email protected]>
Copy link
Copy Markdown
Member

@fuweid fuweid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM on green

@fuweid fuweid merged commit 5fc7272 into containerd:main Jan 5, 2023
@thaJeztah thaJeztah added cherry-picked/1.6.x PR commits are cherry-picked into release/1.6 branch and removed cherry-pick/1.6.x labels Jul 14, 2023
@dmcgowan dmcgowan deleted the cleanup-context branch April 20, 2024 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cherry-picked/1.6.x PR commits are cherry-picked into release/1.6 branch

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

6 participants