Last modified: 2014-03-14 14:14:37 UTC

Wikimedia Bugzilla is closed!

Wikimedia has migrated from Bugzilla to Phabricator. Bug reports should be created and updated in Wikimedia Phabricator instead. Please create an account in Phabricator and add your Bugzilla email address to it.
Wikimedia Bugzilla is read-only. If you try to edit or create any bug report in Bugzilla you will be shown an intentional error message.
In order to access the Phabricator task corresponding to a Bugzilla report, just remove "static-" from its URL.
You could still run searches in Bugzilla or access your list of votes but bug reports will obviously not be up-to-date in Bugzilla.
Bug 47529 - MediaWiki should check ETags
MediaWiki should check ETags
Status: PATCH_TO_REVIEW
Product: MediaWiki
Classification: Unclassified
General/Unknown (Other open bugs)
1.22.0
All All
: Normal enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks: 31639
  Show dependency treegraph
 
Reported: 2013-04-23 05:49 UTC by Tyler Romeo
Modified: 2014-03-14 14:14 UTC (History)
3 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Tyler Romeo 2013-04-23 05:49:45 UTC
Currently MediaWiki checks the If-Modified-Since header and sends a 304 response if, indeed, the resource has not been modified since. However, no such check is done for ETags, even despite the fact that the ETag header can be enabled with the $wgUseETag configuration variable.

MediaWiki should check the If-None-Match header and respond appropriately.
Comment 1 Gerrit Notification Bot 2013-04-23 17:29:18 UTC
Related URL: https://gerrit.wikimedia.org/r/60440 (Gerrit Change I02d25e8bc6bd2231fb813f7c9f7118d8a7539b11)
Comment 2 Derk-Jan Hartman 2013-04-23 17:30:56 UTC
I looked at this before, found my old patch and cleaned it up a tad, comments welcome.

For reference:
http://www.w3.org/Protocols/rfc2616/rfc2616-sec14.html#sec14.26
http://www.w3.org/Protocols/rfc2616/rfc2616-sec13.html#sec13.3.3
Comment 3 Tim Starling 2013-05-15 00:00:05 UTC
What is the point in doing this? It's not required by the spec. Does it have some performance advantage?
Comment 4 Tyler Romeo 2013-05-15 03:17:42 UTC
Changing to enhancement.

(In reply to comment #3)
> What is the point in doing this? It's not required by the spec. Does it have
> some performance advantage?

Not AFAIK. Although one thing it does allow is multiple cached versions of the page, i.e., if the browser has multiple cached versions it can send the ETag of each one, and if any of them matches the server will respond with 304. If-Modified-Since doesn't support this since it is just given one date value.
Comment 5 Tim Starling 2013-05-16 22:17:24 UTC
(In reply to comment #4)
> Changing to enhancement.
> 
> (In reply to comment #3)
> > What is the point in doing this? It's not required by the spec. Does it have
> > some performance advantage?
> 
> Not AFAIK. Although one thing it does allow is multiple cached versions of
> the page, i.e., if the browser has multiple cached versions it can send the 
> ETag of each one, and if any of them matches the server will respond with 304.
> If-Modified-Since doesn't support this since it is just given one date value.

Is there any browser that does that?
Comment 6 Tyler Romeo 2013-05-16 22:25:44 UTC
(In reply to comment #5)
> Is there any browser that does that?

I don't know, but is there any harm in supporting it? I'm not saying this is high priority or anything, but nonetheless it's something we can do.
Comment 7 Tim Starling 2013-05-16 22:52:31 UTC
It's a fairly complex change to review. It's easy to imagine ways in which adding ETag support could break things. The code is difficult to test due to the  lack of client support, and could easily be broken by future updates to caching semantics in other parts of MediaWiki. In exchange for time spent reviewing it, and the inevitable time which will be required to maintain it in the future, I would like there to be some kind of benefit.
Comment 8 Derk-Jan Hartman 2013-07-01 14:14:36 UTC
Path abandoned: https://gerrit.wikimedia.org/r/#/c/60440/
Comment 9 Andre Klapper 2014-03-14 14:14:37 UTC
Potential rationale in bug 32364

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links