Create a URL rewrite to handle the /data/ path for canonical URLs for machine readable page content
Open, NormalPublic

Description

For all Wikimedia sites, add the following rewrite:

RewriteRule /data/(.*)/(.*)$ /wiki/Special:PageData/$1/$2 [QSA]

See T161527: RFC: Canonical data URLs for machine readable page content for the rationale.

daniel created this task.Apr 26 2017, 4:45 PM

The patch is merged but not deployed so I think we should wait a little. But given how the RFC implemented and here, I think we need to change the code base to accept slot too (even thought it ignores it for now). Let me clarify: right now, Special:PageData/foo/bar goes to page foo and ignores bar, it should go to bar and ignores foo.

@Ladsgroup I agree that the rewrite should only be done once Special:PageData is live.

The fix for the foo/bar problem is now also merged. Thanks for noticing, I completely missed that, even though I wrote the spec :)

daniel triaged this task as Normal priority.Jun 13 2017, 5:03 PM

Change 360887 had a related patch set uploaded (by Ladsgroup; owner: Amir Sarabadani):
[operations/puppet@production] Add /data/ Redirect for commons

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

Change 360891 had a related patch set uploaded (by Ladsgroup; owner: Amir Sarabadani):
[operations/puppet@production] Add /data/ url redirect in beta cluster (Wikipedia only)

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

Mentioned in SAL (#wikimedia-releng) [2017-06-22T19:02:18Z] <Amir1> cherry-picking gerrit:360891/1 (T163922)

I cherry-picked the patch in beta cluster and it works just fine: https://en.wikipedia.beta.wmflabs.org/data/main/Albert_Einstein

Change 360891 merged by Filippo Giunchedi:
[operations/puppet@production] Add /data/ url redirect in beta cluster (Wikipedia only)

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

daniel added a subscriber: Dereckson.

@Dereckson you marked this ticket as blocked on the ops boards - but I don't see what it's blocked on. How do we move forward?