Page MenuHomePhabricator

Migrate wl_notificationtimestamp updates to the job queue
Closed, ResolvedPublic

Description

Right now these updates happen very fequently, post-send, spamming the log. The log can be silenced here, but this really isn't the kind of thing that needs to be using something as heavy weight as the core DBs.

I suggest starting to move them to the main stash, e.g., when a user views a page (or presses "mark all read"):
a) A main stash entry updated for the user (reflect recent views and reset-all actions)
b) A job enqueued that will propagate the changes to the DB

...important reads of the wl_notificationtimestamp (per-user) can merge the data from the both on read.

Eventually, the DB use could later be removed, but that's another task...and more complex.

Event Timeline

aaron triaged this task as Medium priority.Mar 3 2018, 12:46 AM
aaron created this task.

Change 416198 had a related patch set uploaded (by Aaron Schulz; owner: Aaron Schulz):
[mediawiki/core@master] [WIP] Stash WatchedItem changes so that the jobs can run async again

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

aaron removed aaron as the assignee of this task.Jul 2 2018, 11:09 AM

Change 416198 merged by jenkins-bot:
[mediawiki/core@master] Stash WatchedItem changes so that the jobs run from the queue

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

Report on WP:VP/T:

Today is Thursday. And now when I visit a link from my watchlist, and then go back to the watchlist, the green bullet stays green instead of turning blue. This problem occurs even for deleted redlinked pages.

Might be related to this change ?

aaron claimed this task.

Report on WP:VP/T:

Today is Thursday. And now when I visit a link from my watchlist, and then go back to the watchlist, the green bullet stays green instead of turning blue. This problem occurs even for deleted redlinked pages.

Might be related to this change ?

See https://gerrit.wikimedia.org/r/#/c/mediawiki/core/+/496563/ .