Метод runUnderLock
Сигнатура метода
private function runUnderLock(string $operation, ManagedAgentIdentity $identity, int $lockTimeoutSeconds, callable $body): SystemAiAgentLifecycleResult
Возвращает:
SystemAiAgentLifecycleResult
Описание
Takes the named lock of the identity, opens the operation scope of the registry and runs one bounded pass. The lock is released and the scope is closed in the same finally block, so neither of them can outlive the pass. An unexpected failure of the pass itself is answered as an infrastructure failure: every path that may leave a side effect behind compensates on its own before it returns.
Параметры
4| Имя | Тип | По умолчанию | Флаги |
|---|---|---|---|
$operation
|
string
|
—
|
—
|
$identity
|
ManagedAgentIdentity
|
—
|
—
|
$lockTimeoutSeconds
|
int
|
—
|
—
|
$body
|
callable
|
—
|
—
|
Расположение
Исходный файл метода в Bitrix Framework
Путь к исходному файлу
Source
~/bitrix/modulesbizproc/lib/Internal/AiAgent/Lifecycle/Service/SystemAiAgentLifecycleService.php
Расположение метода в файле
Строки
370–449