Make the scheduler Dag cache size and TTL configurable - #71816
Draft
jason810496 wants to merge 1 commit into
Draft
Make the scheduler Dag cache size and TTL configurable#71816jason810496 wants to merge 1 commit into
jason810496 wants to merge 1 commit into
Conversation
This was referenced Aug 19, 2026
jason810496
force-pushed
the
feat/scheduler-dag-cache-config
branch
6 times, most recently
from
August 21, 2026 11:21
ffd5332 to
47dda94
Compare
A fixed 512-entry cache cannot fit every deployment: larger active working sets churn while memory-constrained schedulers may need a lower cap. Exposing size and TTL controls lets operators trade memory for refetch and deserialization cost while preserving the current defaults.
jason810496
force-pushed
the
feat/scheduler-dag-cache-config
branch
from
August 21, 2026 12:19
47dda94 to
e2f7da7
Compare
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.
feat/dagbag-cache-metric-namespace...feat/scheduler-dag-cache-configWhy
The scheduler's cache bound landed in #71704 as a fixed constant. Deployments whose active Dag-version working set exceeds that limit cannot raise it, while memory-constrained deployments cannot lower it or choose time-based eviction.
How
The API server and scheduler read and validate their size and TTL pairs through one helper. Each component constructs
CachedDBDagBagfor every configuration. When both values are 0, the configured cache uses a plain unbounded dict and performs no eviction.What
[scheduler] dag_cache_size, defaulting to the existing LRU limit of 512 versions.[scheduler] dag_cache_ttl, defaulting to 0 with no time-based eviction.Was generative AI tooling used to co-author this PR?