Page MenuHomePhabricator

Implement batch request of abstractwiki content fragments.
Closed, ResolvedPublic

Description

Description

Abstractwiki content fragments are requested in batch when:

  • page initialization,
  • changing the selected language for the preview.

Abstractwiki content fragments are requested one by one when:

  • adding a new fragment,
  • editing an existing fragment,
  • when clicking a "Retry" after a max retries warning or 503/500 error

When requesting fragments one-by-on we request them synchronously.
When requesting all fragments, we queue requests at the front-end side

Issues

  • We need to slow down requests very heavily, which means that even if the responses are cached, loading the page takes a very long time.

Proposal

  • We build a batch request, that returns all fragments for the page, only if they are cached.
  • The response need to be structured by fragment, and indexed properly so that they can be retried easily.
  • The batch request will only return the status, and will also create the necessary jobs to refresh all fragments that aren't cached.
  • The UI will either render the fragment received, or a [not ready, retry later] marker, which can be clicked to launch a retry after some time

Completion checklist

Event Timeline

gengh claimed this task.

Change #1302807 had a related patch set uploaded (by Genoveva Galarza; author: Genoveva Galarza):

[mediawiki/extensions/WikiLambda@master] [WIP] Request whole sections from Abstract Wikipedia preview

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

Change #1306162 had a related patch set uploaded (by Genoveva Galarza; author: Genoveva Galarza):

[mediawiki/extensions/WikiLambda@master] Use abstractwiki_fetch_section for whole section initialization in AW preview

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

Change #1306346 had a related patch set uploaded (by Jforrester; author: Jforrester):

[mediawiki/extensions/WikiLambda@master] abstract: Serve persisted fetch_section reads as GET

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

Change #1302807 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] Add new abstractwiki_fetch_section ActionAPI

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

Change #1306162 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] Use abstractwiki_fetch_section for whole section initialization in AW preview

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

Change #1306346 merged by jenkins-bot:

[mediawiki/extensions/WikiLambda@master] abstract: Serve persisted fetch_section reads as GET

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