-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathext_localconf.php
More file actions
27 lines (22 loc) · 1005 Bytes
/
ext_localconf.php
File metadata and controls
27 lines (22 loc) · 1005 Bytes
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
<?php
if (!defined('TYPO3_MODE')) {
die('Access denied.');
}
$config = unserialize($_EXTCONF);
\MOC\MocMessageQueue\Queue\BeanstalkQueue::$server = $config['beanstalk_server'];
\MOC\MocMessageQueue\Queue\BeanstalkQueue::$tube = $config['beanstalk_tube'];
if ($config['message_queue_implementation'] === 'Beanstalk' && $config['disable_pheanstalk_import'] !== "1") {
$pheanstalkClassRoot = \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::extPath($_EXTKEY) . '/Classes';
require_once($pheanstalkClassRoot . '/Pheanstalk/ClassLoader.php');
Pheanstalk_ClassLoader::register($pheanstalkClassRoot);
}
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['extbase']['commandControllers'][] = 'Moc\MocMessageQueue\Command\QueueWorkerCommandController';
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTypoScriptSetup('
config.tx_extbase {
objects {
MOC\MocMessageQueue\Queue\QueueInterface {
className = MOC\\MocMessageQueue\\Queue\\' . $config['message_queue_implementation']. 'Queue
}
}
}
');