Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(cache): invalidate wrongly cached handler entities #1857

Merged
merged 4 commits into from
Oct 26, 2023
Merged

Conversation

pi0
Copy link
Member

@pi0 pi0 commented Oct 26, 2023

πŸ”— Linked issue

#1850

❓ Type of change

  • πŸ“– Documentation (updates to the documentation, readme, or JSdoc annotations)
  • 🐞 Bug fix (a non-breaking change that fixes an issue)
  • πŸ‘Œ Enhancement (improving an existing functionality like performance)
  • ✨ New feature (a non-breaking change that adds functionality)
  • 🧹 Chore (updates to the build process or auxiliary tools and libraries)
  • ⚠️ Breaking change (fix or feature that would cause existing functionality to change)

πŸ“š Description

A regression from v2.7.0 cached the etag and last-modified headers of cached handler entities to become undefined.

#1855 fixes the issue but if any production deployment used faulty behavior of 2.7.0, they could keep invalid entities in the cache until maxAge reaches.

This PR adds a core hotfix for this unfortunate incident and will be reverted after a while.

πŸ“ Checklist

  • I have linked an issue or discussion.
  • I have updated the documentation accordingly.

@pi0 pi0 mentioned this pull request Oct 26, 2023
@codecov
Copy link

codecov bot commented Oct 26, 2023

Codecov Report

Merging #1857 (ec3f0ee) into main (b0ec181) will decrease coverage by 0.10%.
The diff coverage is 0.00%.

@@            Coverage Diff             @@
##             main    #1857      +/-   ##
==========================================
- Coverage   52.34%   52.24%   -0.10%     
==========================================
  Files         170      170              
  Lines       11780    11787       +7     
  Branches      907      903       -4     
==========================================
- Hits         6166     6158       -8     
- Misses       5518     5532      +14     
- Partials       96       97       +1     
Files Coverage Ξ”
src/runtime/cache.ts 0.00% <0.00%> (ΓΈ)

... and 2 files with indirect coverage changes

@pi0 pi0 merged commit 55d60b8 into main Oct 26, 2023
8 of 9 checks passed
@pi0 pi0 deleted the fix/cache-undefined branch October 26, 2023 22:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant