Метод resolveOwnedTemplateId

private

Сигнатура метода

private function resolveOwnedTemplateId(int $instanceId, ManagedResourceCleanupBudget $budget): ?int

Возвращает: ?int

Описание

Template id of the copy the instance owns, or null while the instance is gone. One portion hands this participant up to {@see self::RECONCILE_BATCH_LIMIT} rows of the same instance, and the copy of an instance does not change while that instance is being removed, therefore the row is read once and the answer serves the whole portion instead of costing one identical query per resource. An absent instance is remembered as well, so that it does not keep the query per resource of its own. The budget is charged for the read alone: a remembered answer performed no query, and charging it would spend rows the deletion of the very same pass needs to converge.

Параметры

2
Имя Тип По умолчанию Флаги
$instanceId int —
—
$budget ManagedResourceCleanupBudget —
—

Расположение

Исходный файл метода в Bitrix Framework

Путь к исходному файлу Source
~/bitrix/modulesbizproc/lib/Internal/AiAgent/Lifecycle/Cleanup/ScheduleCleanup.php
Расположение метода в файле
Строки 233–246

Исходный код

PHP