Page MenuHomePhabricator

Community configuration: Define behaviour for external titles and wikipage-based configuration store
Closed, DeclinedPublic

Description

Community configuration 1.0 supports storing wiki-configuration as external titles. So far, the sole usecase for this is mw:MediaWiki:NewcomerTopicsOres.json, which is used to centrally configure certain aspects for Growth features and ORES topics. Currently, WikiPageConfigStore throws an LogicException whenever an external title is used with it.

As part of this task, we need to:

  • decide how we want Community configuration 2.0 to operate with regards to external wikipage titles, such as mw:MediaWiki:NewcomerTopicsOres.json,
  • if we decide to accept external configuration titles as valid ones, fill a new task to implement that newly defined behaviour,
  • if we decide to not accept external configuration titles, decide (and if required, fill a task) how to handle the mw:MediaWiki:NewcomerTopicsOres.json use-case.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
Sgs raised the priority of this task from High to Needs Triage.Mar 5 2024, 5:04 PM
Sgs triaged this task as Medium priority.Mar 14 2024, 6:30 PM

This popped during my work at T364717: GrowthExperiments: Make use of Suggested edits config in Community configuration, which includes loading data from https://www.mediawiki.org/wiki/MediaWiki:NewcomerTopicsOres.json (so, remotely).

To be able to (in the future) remove Community configuration 1.0 code from GrowthExperiments, and fully rely on the CommunityConfiguration extension, CommunityConfiguration should be able to handle external titles.

The only drawback for external config is that it (obviously) cannot be edited, as the URL can point anywhere (not necessarily to a MediaWiki page). With @Cyndymediawiksim's fix for T361123: Make it possible to declare a Community configuration provider that does not display on the dashboard, such cases can be excluded from the dashboard by setting the skipDashboardListing option to true.

What would be the reasoning for config like https://www.mediawiki.org/wiki/MediaWiki:NewcomerTopicsOres.json being suitable for CommunityConfiguration in the first place?
To me that looks very technical (needs detailed knowledge about Ores internals) and would maybe be better suited for classic PHP-based configuration.

Further, using loading configuration from someplace other than the current wiki seems antithetical to the overall goal that we're trying to achieve with community configuration. This is not something that one local on-wiki community can form an opinion about and then change, this needs agreement among many communities. Not sure if community configuration is the right tool for that. (This is a product question.)

Finally, I'm not sure if accessing external files to load configuration is a good idea in terms of performance, security and stability.

So, my intuitive suggestion for dealing with GE's mw:MediaWiki:NewcomerTopicsOres.json would be to downgrade it into php configuration (=> LocalSettings.php locally, or CommonSettings.php in wikimedia). That being said, I do not know what the reasons and motivations were for creating it this way originally.

What would be the reasoning for config like https://www.mediawiki.org/wiki/MediaWiki:NewcomerTopicsOres.json being suitable for CommunityConfiguration in the first place?
To me that looks very technical (needs detailed knowledge about Ores internals) and would maybe be better suited for classic PHP-based configuration.

Hmm... Good question. We were originally using morelike, which needed a couple of articles as seeds, and back then it was stored on-wiki (example is https://cs.wikipedia.org/wiki/MediaWiki:NewcomerTopics.json, which was later deleted; content is at P62371). Later, we switched to ORES topics, and since we already had it stored on-wiki, we switched to the central wiki. That being said, I can see the arguments for moving https://www.mediawiki.org/wiki/MediaWiki:NewcomerTopicsOres.json to the server config.

Further, using loading configuration from someplace other than the current wiki seems antithetical to the overall goal that we're trying to achieve with community configuration. This is not something that one local on-wiki community can form an opinion about and then change, this needs agreement among many communities. Not sure if community configuration is the right tool for that. (This is a product question.)

Not necessarily. For example, spam blacklist has two components: many domains are blocked globally from meta (and loaded via HTTP). If spam blacklist was to move to CommunityConfiguration, the HTTP store would make a lot of sense.

Finally, I'm not sure if accessing external files to load configuration is a good idea in terms of performance, security and stability.

FWIW, we're already doing it in CC1.0 (in production), for quite a while. There are also other extensions with that pattern, such as SpamBlacklist. So, likely not a significant issue?

So, my intuitive suggestion for dealing with GE's mw:MediaWiki:NewcomerTopicsOres.json would be to downgrade it into php configuration (=> LocalSettings.php locally, or CommonSettings.php in wikimedia). That being said, I do not know what the reasons and motivations were for creating it this way originally.

Makes sense. I have no problem with that approach if @Sgs and @Cyndymediawiksim do not have any objections.

Change #1031010 had a related patch set uploaded (by Urbanecm; author: Urbanecm):

[mediawiki/extensions/CommunityConfiguration@master] [PoC] Create HttpStore

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

Change #1031010 abandoned by Urbanecm:

[mediawiki/extensions/CommunityConfiguration@master] [PoC] Create HttpStore

Reason:

likely not needed at this point

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

Heads-up: I filled T367576: Ensure ORES topics are not loaded through legacy CommunityConfiguration code for the MediaWiki:NewcomerTopicsOres.json migration.

Regarding the remote store, let's decline this task, since we currently do not need the remote store for anything and considering decision-type tasks should not be opened for a very long time. If that need ever comes back up, we can always reopen and continue discussing this.