Page MenuHomePhabricator

Change Dispatching should not stumble over mowiki redirecting to rowiki
Closed, ResolvedPublicPRODUCTION ERROR

Description

Error
normalized_message
[{reqId}] {exception_url}   MWException: No client wiki with site ID mowiki configured! Please check $wgWBRepoSettings['localClientDatabases'].
exception.trace
from /srv/mediawiki/php-1.38.0-wmf.2/extensions/Wikibase/repo/includes/ChangeModification/DispatchChangesJob.php(238)
#0 /srv/mediawiki/php-1.38.0-wmf.2/extensions/Wikibase/repo/includes/ChangeModification/DispatchChangesJob.php(158): Wikibase\Repo\ChangeModification\DispatchChangesJob->filterClientWikis(array, array, NULL)
#1 /srv/mediawiki/php-1.38.0-wmf.2/extensions/EventBus/includes/JobExecutor.php(79): Wikibase\Repo\ChangeModification\DispatchChangesJob->run()
#2 /srv/mediawiki/rpc/RunSingleJob.php(76): MediaWiki\Extension\EventBus\JobExecutor->execute(array)
#3 {main}
Impact
Notes

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript

Change 725964 had a related patch set uploaded (by Michael Große; author: Michael Große):

[mediawiki/extensions/Wikibase@master] Don't fail job if subscribed wiki is unknown

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

Change 725923 had a related patch set uploaded (by Ladsgroup; author: Michael Große):

[mediawiki/extensions/Wikibase@wmf/1.38.0-wmf.2] Don't fail job if subscribed wiki is unknown

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

Change 725964 merged by jenkins-bot:

[mediawiki/extensions/Wikibase@master] Don't fail job if subscribed wiki is unknown

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

So when and how do these redirects end up happening?
Should they happen?
And do we miss anything by only logging? or do these things still get dispatched?

[...]
And do we miss anything by only logging? or do these things still get dispatched?

The old system did not dispatch to those database names that point to somewhere else, so I think it should be fine if we don't do that either.

Also, I would expect the wiki to which is being redirected to have subscribed to all relevant entities with its own name, so there should not be any loss of information there either.

So subscriptions just still exist in the db from before these wikis names changed?
Perhaps we should have a ticket for making a script and cleaning these up?

So subscriptions just still exist in the db from before these wikis names changed?
Perhaps we should have a ticket for making a script and cleaning these up?

Yes, renamed subscriptions and closed wikis (see the one-time cleanup in T292440) and other leftovers like a subscription from testcommonswiki.

Probably, the script will select distinct wikinames from the subscriptions table and diff those with localClientDatabases. Then all subscriptions that are not in localClientDatabases can be deleted.

Change 725923 merged by jenkins-bot:

[mediawiki/extensions/Wikibase@wmf/1.38.0-wmf.2] Don't fail job if subscribed wiki is unknown

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

Mentioned in SAL (#wikimedia-operations) [2021-10-06T09:13:37Z] <ladsgroup@deploy1002> Synchronized php-1.38.0-wmf.2/extensions/Wikibase/repo/includes/ChangeModification/DispatchChangesJob.php: Backport: [[gerrit:725923|Don't fail job if subscribed wiki is unknown (T292446 T292440)]] (duration: 01m 15s)

mowiki is a deleted wiki, which is no longer recognised or served anywhere from the MW side. See also https://noc.wikimedia.org/conf/highlight.php?file=dblists/deleted.dblist.

huwikinews is a closed wiki, which are fully functional and publicly served with existing pages that may also be active Wikidata clients. The only thing about closed wikis from an infra perspective, is that people cannot register new accounts and that (most) people are unable to make edits there.

I don't know exactly what the impact of removing subscriptions is at T292440#7398803, but my gut sense is that closed wikis should not be treated differently from open wikis for most purposes. It might be okay to not send them change propagations, but that could potentially cause problems. E.g. closed wikis do still use parser cache, and Commons, and they can still receive purges and the ocasional edit from a global bot or interface editor.

Continuing to see these in wmf.3 for mowiki and testcommonswiki.

1count  2histo  3first  4last   5exception              6message
55      ▅▆▃▅▅▆▆ 0953    1917    MW..................    .3 e/W/r/i/C/DispatchChangesJob:238  No client wiki with site ID mowiki configur
15      _____▇▁ 1758    1829    MW..................    .3 e/W/r/i/C/DispatchChangesJob:238  No client wiki with site ID testcommonswiki

huwikinews is a closed wiki, which are fully functional and publicly served with existing pages that may also be active Wikidata clients. The only thing about closed wikis from an infra perspective, is that people cannot register new accounts and that (most) people are unable to make edits there.

I don't know exactly what the impact of removing subscriptions is at T292440#7398803, but my gut sense is that closed wikis should not be treated differently from open wikis for most purposes. It might be okay to not send them change propagations, but that could potentially cause problems. E.g. closed wikis do still use parser cache, and Commons, and they can still receive purges and the ocasional edit from a global bot or interface editor.

We've not been dispatching to closed wikise since 2015. I think this commit introduced it: e5bc1066511d6324b1caa4c2a52e4498c76ca527. Whether that's a good idea or not, I do not know. Probably @Lydia_Pintscher's call.

mowiki is a deleted wiki, which is no longer recognised or served anywhere from the MW side. See also https://noc.wikimedia.org/conf/highlight.php?file=dblists/deleted.dblist.

Continuing to see these in wmf.3 for mowiki and testcommonswiki.

1count  2histo  3first  4last   5exception              6message
55      ▅▆▃▅▅▆▆ 0953    1917    MW..................    .3 e/W/r/i/C/DispatchChangesJob:238  No client wiki with site ID mowiki configur
15      _____▇▁ 1758    1829    MW..................    .3 e/W/r/i/C/DispatchChangesJob:238  No client wiki with site ID testcommonswiki

@Ladsgroup just removed entries for those two wikis from the wb_changes_subscriptions table, so the errors related to them should stop now. Probably, we can also further downgrade that from an "error" level message to a "warning" or "notice" level one.

We've not been dispatching to closed wikise since 2015. I think this commit introduced it: e5bc1066511d6324b1caa4c2a52e4498c76ca527. Whether that's a good idea or not, I do not know. Probably @Lydia_Pintscher's call.

In the grand scheme of things I don't think it matters either way tbh. So keeping it as is is fine from my side.

Michael claimed this task.
Michael moved this task from Backlog to Done on the Wikibase change dispatching scripts to jobs board.

This should be done with 725964: Don't fail job if subscribed wiki is unknown being deployed. Please reopen it if this exception still occurs.