Page MenuHomePhabricator

Add LastModified header support to Proton codebase
Closed, ResolvedPublic

Description

The Proton's /pdf endpoint does not return etag nor last-modified headers. For caching purposes, all services should return at least one - last-modified or etag header.

The etag caching doesn't fully apply for proton the way it applies to other services - as cache expiration is set to 600 seconds both for client and varnish. Once the cache expires at the client, it also expires on varnish.

  • Acceptance criteria
  • Proton renders return the LastModified header
  • If MediaWiki/any other instance do not return the LastModified, Proton will use the current system time and return it as LastModified.

Event Timeline

Change 937166 had a related patch set uploaded (by Pmiazga; author: Pmiazga):

[mediawiki/services/chromium-render@master] Add ETag support to /pdf endpoint

https://gerrit.wikimedia.org/r/937166

pmiazga changed the task status from Open to In Progress.Jul 11 2023, 6:54 PM

Change 937166 merged by jenkins-bot:

[mediawiki/services/chromium-render@master] Add ETag support to /pdf endpoint

https://gerrit.wikimedia.org/r/937166

Change 940377 had a related patch set uploaded (by Pmiazga; author: Pmiazga):

[mediawiki/services/chromium-render@master] Instead of building the etag, passtrough the last-modified header

https://gerrit.wikimedia.org/r/940377

Yesterday I confirmed with @Vgutierrez and @daniel that instead of building/creating the etag, we can just passthrough the LastModified - which btw is a better way. I'm going to update this phab ticket to reflect the current state.

pmiazga renamed this task from Add ETag support to Proton codebase to Add LastModified header support to Proton codebase.Jul 21 2023, 3:30 PM
pmiazga updated the task description. (Show Details)

Change 940377 merged by jenkins-bot:

[mediawiki/services/chromium-render@master] Instead of building the etag, passtrough the last-modified header

https://gerrit.wikimedia.org/r/940377

DAlangi_WMF subscribed.

Thanks for making this happen PMiazga. 🎉