Page MenuHomePhabricator

Create SettingsSource
Closed, ResolvedPublic

Description

Interface draft:

SettingsSource {
    public function load(): array;
    public function getHashKey(): string;
}

Example implementations:

new SettingsFileSource( 'something.json', new JsonReader() );
new SettingsArraySource( [ ... ] );

Example usage:

SettingsBuilder::load( SettingsSource $source );
NOTE: this is part of prototyping a solution for T292402

Event Timeline

dduvall changed the task status from Open to In Progress.Nov 10 2021, 8:11 PM
dduvall triaged this task as Medium priority.

Change 738278 had a related patch set uploaded (by Dduvall; author: Dduvall):

[mediawiki/core@master] Refactor settings readers into sources and formats

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

Change 738278 merged by jenkins-bot:

[mediawiki/core@master] Introduced settings sources and formats

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

dduvall moved this task from Doing to Done on the MediaWiki-SettingsLoader board.