public function ContentHubImportQueueWorker::__construct in Acquia Content Hub 8.2
ContentHubExportQueueWorker constructor.
Parameters
\Symfony\Component\EventDispatcher\EventDispatcherInterface $dispatcher: Dispatcher.
\Drupal\acquia_contenthub\ContentHubCommonActions $common: The common actions object.
\Drupal\acquia_contenthub\Client\ClientFactory $factory: The client factory.
\Drupal\acquia_contenthub_subscriber\SubscriberTracker $tracker: The Subscriber Tracker.
\Drupal\Core\Logger\LoggerChannelFactoryInterface $logger_factory: The logger factory.
\Drupal\Core\Config\ConfigFactoryInterface $config_factory: The config factory.
array $configuration: The plugin configuration.
string $plugin_id: The plugin id.
mixed $plugin_definition: The plugin definition.
Throws
\Exception
Overrides PluginBase::__construct
File
- modules/
acquia_contenthub_subscriber/ src/ Plugin/ QueueWorker/ ContentHubImportQueueWorker.php, line 99
Class
- ContentHubImportQueueWorker
- Queue worker for importing entities.
Namespace
Drupal\acquia_contenthub_subscriber\Plugin\QueueWorkerCode
public function __construct(EventDispatcherInterface $dispatcher, ContentHubCommonActions $common, ClientFactory $factory, SubscriberTracker $tracker, LoggerChannelFactoryInterface $logger_factory, ConfigFactoryInterface $config_factory, array $configuration, $plugin_id, $plugin_definition) {
$this->common = $common;
if (!empty($this->common
->getUpdateDbStatus())) {
throw new \Exception("Site has pending database updates. Apply these updates before importing content.");
}
$this->dispatcher = $dispatcher;
$this->factory = $factory;
$this->tracker = $tracker;
$this->achLoggerChannel = $logger_factory
->get('acquia_contenthub_subscriber');
$this->configFactory = $config_factory;
parent::__construct($configuration, $plugin_id, $plugin_definition);
}