-
-
Notifications
You must be signed in to change notification settings - Fork 247
/
EventBus.php
41 lines (32 loc) · 870 Bytes
/
EventBus.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
use MediaWiki\Extension\EventBus\Adapters\JobQueue\JobQueueEventBus;
use Wikimedia\EventRelayer\EventRelayerNull;
$wgEnableEventBus = 'TYPE_ALL';
if ( $cwPrivate ) {
$wgEnableEventBus = 'TYPE_JOB|TYPE_EVENT';
}
if ( $wi->dbname === 'loginwiki' || $wi->dbname === 'loginwikibeta' ) {
$wgEnableEventBus = 'TYPE_JOB|TYPE_PURGE';
}
$wgEventServiceDefault = 'eventgate';
$wgEventServices = [
'eventgate' => [
'url' => 'http://10.0.18.147:8192/v1/events',
'timeout' => 62,
],
];
$wgEventRelayerConfig = [
'default' => [
'class' => EventRelayerNull::class,
],
];
$wgJobTypeConf['default'] = [
'class' => JobQueueEventBus::class,
'readOnlyReason' => false
];
$wgEventBusEnableRunJobAPI =
wfHostname() === 'mwtask151' ||
wfHostname() === 'mwtask161' ||
wfHostname() === 'mwtask171' ||
wfHostname() === 'mwtask181' ||
wfHostname() === 'test151';