|author||Petr Pchelko <firstname.lastname@example.org>||Thu Mar 01 11:34:57 2018 -0300|
|committer||Petr Pchelko <email@example.com>||Thu Mar 01 11:35:38 2018 -0300|
Specify that EventBus queue supports delayed jobs. Bug: T188540 Change-Id: Ib8a2df5c1b21bbd9a512654adf139f7dc9f229e0
This extension is part of a larger effort to create a general purpose event system, to reliably propagate state changes from one part of the infrastructure, to another. Since this approach relies upon hooks, it is not atomic (delivery of an event could fail after MediaWiki has committed the corresponding change), and so does not provide the reliability we're aiming for. Therefore, this extension should be considered an interim solution, until the requisite changes can be made to MediaWiki core.
To configure the URL of the EventBus service:
$wgEventServiceUrl = 'http://localhost:8085/v1/topics';
To configure the EventBus service request timeout:
$wgEventServiceTimeout = 5; // 5 second timeout
This extension also provides an RCFeedEngine and RCFeedFormatter implementation That will allow RCFeed configuration to post to the EventBus service in the
mediawiki.recentchange topic. To use, add the following to your
$wgRCFeeds['eventbus'] = array( 'formatter' => 'EventBusRCFeedFormatter', 'uri' => 'eventbus://localhost:8085/v1/events', ); $wgRCEngines = array( 'eventbus' => 'EventBusRCFeedEngine', );
uri with the
$wgEventServiceUrl, but with
eventbus:// instead of
Note that the protocol schema part of the
uri configured in
$wgRCFeeds starts with
$wgRCEngines config are mapped from protocol schemes. However,
EventServiceUrl which is used to configure EventBus configuration expects this to be a usual
http:// REST endpoint.
EventBusRCFeedEngine is aware of this discrepency, and replaces the
eventbus:// in the
http:// when configuring its EventBus instance.
EventBus is licensed under the GNU General Public License 2.0 or any later version. You may obtain a copy of this license at http://www.gnu.org/copyleft/gpl.html.