-
Notifications
You must be signed in to change notification settings - Fork 0
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
Set Cache-Control: no-cache for responses with an ETag #141
Conversation
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.
LGTM - brackets on same line is inconsistent with rest of code base (nothing enforcing this).
Worth adding a test, a regression here would cause FE issues?
What test suite would that go in (i.e. do we have an integration suite in the .NET code, or do you mean e2e)? |
Ah, I ran the auto-formatter but it changed way more, let me re-run it just on those lines. |
3d69bc9
to
dc344c9
Compare
Integration tests are in https://github.com/dlcs/iiif-presentation/tree/main/src/IIIFPresentation/API.Tests/Integration - I think a test for this could be added to GET Manifest and/or Collection tests. Using existing integration test class will bootstrap db (and localstack if required) and configure |
Background: right now browsers will cache IIIF resources to disk for the caching period before checking if new content is available. That means we're never sending up an
If-None-Match
and getting a corresponding 304, so we end up with stale data in the browser. This change makes clients always send anIf-None-Match
before using the local cache.Related to #140