Open
Conversation
8e36505 to
603a90b
Compare
Member
Author
|
Draft until fastly/Viceroy#591 is in a Viceroy release. |
a429a0d to
df886c4
Compare
2d4022e to
45fd824
Compare
cee-dub
reviewed
Apr 7, 2026
Collaborator
cee-dub
left a comment
There was a problem hiding this comment.
Partial review, in case you want to address anything before I get done with the rest.
| if err != nil { | ||
| return false, fmt.Errorf("get state: %w", err) | ||
|
|
||
| return 0, fmt.Errorf("get state: %w", err) |
Collaborator
There was a problem hiding this comment.
nit: Would be a little clearer to define a CacheLookupState const for 0.
cee-dub
reviewed
Apr 7, 2026
| // Substitute stale-if-error response; let anyone else in the collapse know as | ||
| // well. | ||
| fastly.HTTPCacheTransactionChooseStale(cacheHandle) | ||
| resp, foundErr := httpCacheGetFoundResponse(cacheHandle, req, backend, true, false) |
Collaborator
There was a problem hiding this comment.
A question for my understanding: this is not a hit, since it is serving a stale response?
Member
Author
There was a problem hiding this comment.
I guess that makes sense? I was just translating the Rust code here :/
…idate, staleError -> staleIfError
Member
Author
|
PTAL |
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.
No description provided.