Merge lp://staging/~fgallina/rnr-server/fix-vary-headers-for-api-endpoints into lp://staging/rnr-server
Proposed by
Fabián Ezequiel Gallina
Status: | Merged |
---|---|
Approved by: | Fabián Ezequiel Gallina |
Approved revision: | 252 |
Merged at revision: | 251 |
Proposed branch: | lp://staging/~fgallina/rnr-server/fix-vary-headers-for-api-endpoints |
Merge into: | lp://staging/rnr-server |
Diff against target: |
435 lines (+252/-27) 7 files modified
src/clickreviews/api/urls.py (+3/-2) src/clickreviews/tests/test_handlers.py (+7/-0) src/reviewsapp/api/decorators.py (+42/-0) src/reviewsapp/api/urls.py (+20/-7) src/reviewsapp/tests/test_decorators.py (+116/-1) src/reviewsapp/tests/test_handlers.py (+51/-0) src/reviewsapp/tests/test_rnrclient.py (+13/-17) |
To merge this branch: | bzr merge lp://staging/~fgallina/rnr-server/fix-vary-headers-for-api-endpoints |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Ricardo Kirkner (community) | Approve | ||
Review via email:
|
Commit message
Fix vary headers for unauthenticated endpoints
Previously, Vary headers were completely removed for these without
taking in consideration the Accept header (nor the Accept-Encoding in
the case for review-stats) sent by the client, therefore incorrect
content was returned for clients expecting different encodings or
serialization than what was cached.
To post a comment you must log in.
LGTM overall.
General question: this service is base completely on anonymous users, right? Otherwise, why don't we vary on Cookie or Authentication too?
Also, why do we vary on Accept for some things and on Accept, Accept-Encoding on others?