cache.config -> cache.yaml - #13456
Open
bneradt wants to merge 1 commit into
Open
Conversation
bneradt
marked this pull request as draft
July 30, 2026 02:00
bneradt
force-pushed
the
cache-yaml-first-match
branch
from
July 30, 2026 02:25
08ede5a to
cc239f8
Compare
bneradt
marked this pull request as ready for review
July 30, 2026 02:26
cache.config needs to move to cache.yaml, with a supported migration path for existing deployments. cache.yaml becomes the default format, while cache.config remains available when explicitly selected. This adds a shared cache parser and marshaller used by traffic_server and traffic_ctl. The new `traffic_ctl config convert cache` command converts legacy files to cache.yaml or writes the result to stdout. This also addresses apache#7701 by giving cache.yaml ordered, first-match semantics, so broader rules no longer compound actions after a specific match. The legacy cache.config parser retains its additive behavior. Fixes: apache#7701
bneradt
force-pushed
the
cache-yaml-first-match
branch
from
July 30, 2026 03:03
cc239f8 to
ce8a0e7
Compare
10 tasks
Contributor
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 42 out of 42 changed files in this pull request and generated no new comments.
Comments suppressed due to low confidence (3)
doc/developer-guide/cache-architecture/architecture.en.rst:481
- This statement is too absolute: cache pinning is driven by the cache rule configuration selected by proxy.config.cache.control.filename. During migration, pinning can still be configured via legacy cache.config when explicitly selected, so the docs should not imply cache.yaml is the only option.
Objects can only be pinned via :file:`cache.yaml` and while
:ts:cv:`proxy.config.cache.permit.pinning` is set to non-zero (it is zero by
doc/developer-guide/cache-architecture/architecture.en.rst:105
- The sentence mixes plural subject with singular verb ("are derived" ... "is recomputed") and it reads as if only cache.yaml can drive cache layout. ATS can still be configured to use legacy cache.config via proxy.config.cache.control.filename, so this paragraph should refer to the cache rule configuration generally and fix the grammar.
This issue also appears on line 480 of the same file.
The layout and structure of the cache spans, the cache volumes, and the cache
stripes that compose them are derived entirely from :file:`storage.yaml` and
:file:`cache.yaml` and is recomputed from scratch when the
:program:`traffic_server` is started. Therefore, any change to those files can
(and almost always will) invalidate the existing cache in its entirety.
doc/developer-guide/cache-architecture/data-structures.en.rst:101
- CacheControlResult is used for both cache.yaml rules and legacy cache.config entries (depending on proxy.config.cache.control.filename). The description should avoid implying it only applies to cache.yaml.
Holds the actions and match state from a rule in :file:`cache.yaml`.
cmcfarlen
self-requested a review
August 3, 2026 22:50
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.
cache.config needs to move to cache.yaml, with a supported migration
path for existing deployments. cache.yaml becomes the default format,
while cache.config remains available when explicitly selected.
This adds a shared cache parser and marshaller used by traffic_server
and traffic_ctl. The new
traffic_ctl config convert cachecommandconverts legacy files to cache.yaml or writes the result to stdout.
This also addresses #7701 by giving cache.yaml ordered, first-match
semantics, so broader rules no longer compound actions after a specific
match. The legacy cache.config parser retains its additive behavior.
Fixes: #7701