- Модуль: seo
- Путь к файлу: ~/bitrix/modules/seo/lib/retargeting/internals/queue.php
- Класс: BitrixSeoRetargetingInternalsQueueTable
- Вызов: QueueTable::addQueueAgent
static function addQueueAgent($type)
{
if (isset(static::$isAgentAdded[$type]))
{
return;
}
$agent = new CAgent();
if ($type)
{
$agentName = static::getProcessQueueAgentName($type);
$agentsDb = $agent->GetList(array("ID" => "DESC"), array(
"MODULE_ID" => self::MODULE_ID,
"NAME" => $agentName,
));
if (!$agentsDb->Fetch())
{
$interval = ($type == 'yandex' ? 900 : 30); // yandex queues must be processed rarely
$agent->AddAgent($agentName, self::MODULE_ID, "N", $interval, null, "Y", "");
}
}
static::$isAgentAdded[$type] = true;
}