Page MenuHomePhabricator

Ensure Wikifeeds requests intended for AQS 1.0 are correctly sent to AQS 2.0
Closed, ResolvedPublic5 Estimated Story Points

Description

Description

After the Pageview Service migrated from AQS 1.0 to 2.0 we noticed that there remained requests going to AQS 1.0. There are two origins for these requests, this ticket concerns the requests coming from Wikifeeds.

Wikifeeds requests pageviews here and will require addition of an extra configuration option to specify using the rest-gateway for these requests as opposed to restbase (which is used elsewhere).

The relevant config is here.

Acceptance Criteria

  • It is possible to separately configure requests bound for AQS vs requests bound for restbase

Required

  • Unit/Integration tests
  • Documentation
  • Passed QA

Event Timeline

WDoranWMF created this task.

Change 969933 had a related patch set uploaded (by Phuedx; author: Phuedx):

[mediawiki/services/wikifeeds@master] WIP: Request pageviews from API Gateway

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

☝️ WIP because:

  1. I've incorrectly said API Gateway when I should have said REST Gateway…
  2. I need help setting the production value for the new configuration variable – what's the base URI for the pageviews endpoint(s) on the REST Gateway?
  3. There's an integration test that's failing on both the master branch and my work branch and it involves a magic number

☝️ WIP because:

  1. I've incorrectly said API Gateway when I should have said REST Gateway…
  2. I need help setting the production value for the new configuration variable – what's the base URI for the pageviews endpoint(s) on the REST Gateway?
  3. There's an integration test that's failing on both the master branch and my work branch and it involves a magic number

Update: 1 and 2 are done. 3 is ongoing.

VirginiaPoundstone lowered the priority of this task from High to Low.Oct 31 2023, 12:18 PM

Change 969933 merged by jenkins-bot:

[mediawiki/services/wikifeeds@master] Make pageviews API requests via REST Gateway

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

Change 971407 had a related patch set uploaded (by Hnowlan; author: Hnowlan):

[operations/deployment-charts@master] wikifeeds: bump image

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

Minor hitch with our change - currently the rest-gateway requires the Host header to be set as wikimedia.org to avoid cache pollution. However, wikifeeds uses analytics.wikimedia.org. I'd like to relax the host header requirement, but enforce this via the URL path instead - so instead using wikimedia.org instead of analytics.wikimedia.org in the URLs requesting pageviews data. Where does this value come from in wikifeeds? I cant see it in the repo or the helm chart

Minor hitch with our change - currently the rest-gateway requires the Host header to be set as wikimedia.org to avoid cache pollution. However, wikifeeds uses analytics.wikimedia.org. I'd like to relax the host header requirement, but enforce this via the URL path instead - so instead using wikimedia.org instead of analytics.wikimedia.org in the URLs requesting pageviews data. Where does this value come from in wikifeeds? I cant see it in the repo or the helm chart

Never mind, this is incorrect reading on my part!

Change 971456 had a related patch set uploaded (by Hnowlan; author: Hnowlan):

[operations/deployment-charts@master] rest-gateway: change how AQS URLs enforce wikimedia.org domain

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

Change 971456 merged by jenkins-bot:

[operations/deployment-charts@master] rest-gateway: change how AQS URLs enforce wikimedia.org domain

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

Change 971407 merged by jenkins-bot:

[operations/deployment-charts@master] wikifeeds: add rest-gateway config and bump image

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

Change 972362 had a related patch set uploaded (by Hnowlan; author: Hnowlan):

[operations/deployment-charts@master] wikifeeds: configure log level

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

Change 972362 merged by jenkins-bot:

[operations/deployment-charts@master] wikifeeds: configure log level

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

Change 972427 had a related patch set uploaded (by Hnowlan; author: Hnowlan):

[operations/deployment-charts@master] rest-gateway: respond on service mesh hostname:port

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

Change 972427 merged by jenkins-bot:

[operations/deployment-charts@master] rest-gateway: respond on service mesh hostname:port

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

☝️ Reflecting reality…

I think we're all good here - can't fully verify until we return public traffic to page-analytics, but we can probably resolve and reopen if needs be.