Merged
Conversation
Signed-off-by: chlins <chlins.zhang@gmail.com>
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #4042 +/- ##
==========================================
+ Coverage 34.40% 34.41% +0.01%
==========================================
Files 343 343
Lines 40211 40211
==========================================
+ Hits 13835 13840 +5
+ Misses 25459 25455 -4
+ Partials 917 916 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces changes to the garbage collection (GC) system across multiple files to add support for
context.Context. The updates ensure that GC operations are context-aware, allowing for better control and cancellation of long-running tasks. Below are the most important changes grouped by theme.Core GC System Updates:
GCinterface inpkg/gc/gc.goto includecontext.Contextas a parameter for methods likeRun,RunAll,Start, and their implementations. This ensures all GC operations are context-aware. [1] [2] [3]Runnerinterface inpkg/gc/task.goto includecontext.Contextin theRunGCmethod.Integration with GC Consumers:
RunGCmethods inmanager/gc/audit.go,manager/gc/job.go, andmanager/manager.goto acceptcontext.Contextas a parameter. [1] [2] [3]HostManagerinterfaces and implementations inscheduler/resource/persistentcache/host_manager.goandscheduler/resource/standard/host_manager.goto passcontext.Contextduring GC operations. [1] [2] [3] [4]Mock and Test Updates:
pkg/gc/gc_mock.go,pkg/gc/runner_mock.go,scheduler/resource/persistentcache/host_manager_mock.go, andscheduler/resource/standard/host_manager_mock.goto includecontext.Contextin mockedRunGCand related methods. [1] [2] [3] [4]pkg/gc/gc_test.go,scheduler/resource/persistentcache/host_manager_test.go, andscheduler/resource/standard/host_manager_test.goto passcontext.Background()to GC-related methods. [1] [2] [3]These changes improve the flexibility and robustness of the GC system by enabling context propagation, which is critical for modern concurrent applications.
Description
Related Issue
Motivation and Context
Screenshots (if appropriate)
Types of changes
Checklist