You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have done my best to include a minimal, self-contained set of instructions for consistently reproducing the issue.
App Id
d7rx5b5im0en3
Region
eu-central-1
Amplify Console feature
Not applicable
Describe the bug
I'm using Next.js with Incremental Site Regeneration (ISR) on Amplify. I noticed that when accessing a page that isn't built yet I'm getting a 404 error and this error is cached by CloudFront with the Cache-Control header public, max-age=0, s-maxage=2678400, must-revalidate.
I also tried overriding this Cache-Control headers, but that didn't work.
Expected behavior
CloudFront shouldn't cache 404 or any other errors.
Reproduction steps
Deploy a Next.js app with ISR on Amplify.
Try to access an ISR route – like "/news/awesome-post" that isn't built but is already created in the CMS.
Check the headers in the dev tools of your browser.
This issue is now closed. Comments on closed issues are hard for our team to see.
If you need more assistance, please open a new issue that references this one.
Before opening, please confirm:
App Id
d7rx5b5im0en3
Region
eu-central-1
Amplify Console feature
Not applicable
Describe the bug
I'm using Next.js with Incremental Site Regeneration (ISR) on Amplify. I noticed that when accessing a page that isn't built yet I'm getting a 404 error and this error is cached by CloudFront with the Cache-Control header
public, max-age=0, s-maxage=2678400, must-revalidate
.I also tried overriding this Cache-Control headers, but that didn't work.
Expected behavior
CloudFront shouldn't cache 404 or any other errors.
Reproduction steps
Build Settings
Additional information
customHTTP.yml:
The text was updated successfully, but these errors were encountered: