-
Notifications
You must be signed in to change notification settings - Fork 167
Fix regression on s3 fetch caches #291
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
Conversation
|
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
e874e36
to
0381057
Compare
Thanks! Is this related to a recent latency increase others and myself have been seeing? |
Most probably yes! It couldn't find any fetch cache in S3 because the prefix never matched the structure of a fetch cache path (the path was missing This problem was particularly noticeable in dynamic routes (no ISR) because it's as if there were no fetch cache at all. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It couldn't find any fetch cache in S3 because the prefix never matched the structure of a fetch cache path (the path was missing __fetch and had an extra . at the end)
This problem was particularly noticeable in dynamic routes (no ISR) because it's as if there were no fetch cache at all.
Good catch and thanks for the PR.
Unfortunately this PR will become useless with #295. Not sure when we'll merge #295, if we wait for 2.2.6
, we should merge this one for sure
Nice! I actually did today a bigger refactor than this PR, quite similar to yours, while trying to understand/optimise the requests after seeing how not great to fetch performances are between a Lambda and S3 (btw I posted a question on discord about this to see if other people have seen the same thing: https://discord.com/channels/983865673656705025/1027265626085019769/1165983372590460939). I'll close this PR then and hope yours is merged soon! |
This aims to fix a regression from #252.
Following that PR, it became impossible to list a key of type "fetch" as the prefix in listS3Object always added a "dot" at the end which is only useful for non-fetch objects.