magento2
magento2 copied to clipboard
Update use cache control immutable for static file
Description (*)
Update Cache-Control header to static file (assets, media) As explained in the Mozilla documentation: ``When a user reloads the browser, the browser will send conditional requests for validating to the origin server. But it's not necessary to revalidate those kinds of static resources even when a user reloads the browser, because they're never modified. immutable tells a cache that the response is immutable while it's fresh and avoids those kinds of unnecessary conditional requests to the server.` Inspire by: https://github.com/serversideup/docker-php/pull/487 https://www.keycdn.com/blog/cache-control-immutable
Related Pull Requests
Fixed Issues (if relevant)
- Fixes magento/magento2#<issue_number>
Manual testing scenarios (*)
- Check cache control header static file (js, css, image,...)
Questions or comments
Contribution checklist (*)
- [ ] Pull request has a meaningful description of its purpose
- [ ] All commits are accompanied by meaningful commit messages
- [ ] All new or changed code is covered with unit/integration tests (if applicable)
- [ ] README.md files for modified modules are updated and included in the pull request if any README.md predefined sections require an update
- [ ] All automated tests passed successfully (all builds are green)
Resolved issues:
- [x] resolves magento/magento2#39486: Update use cache control immutable for static site