queryScalar( sprintf("SELECT GET_LOCK('%s', %d)", md5($id), 0) ); $result = $lock != "0"; } return $result; } /** * Releases the lock named by the string $id * Supports only Mysql * * @param string $id Lock Name. * @return bool Returns true if lock was released. */ public static function unlock($id) { $connection = static::getConnection(); if ($connection instanceof MysqlCommonConnection) { $connection->queryExecute( sprintf("DO RELEASE_LOCK('%s')", md5($id)) ); } return true; } /** * Gets a new connection for the lock mechanism * @return \Bitrix\Main\DB\Connection */ private static function getConnection() { $pool = Application::getInstance()->getConnectionPool(); $connection = $pool->getConnection(static::CONNECTION_NAME); if (!$connection) { $connection = $pool->cloneConnection( $pool::DEFAULT_CONNECTION_NAME, static::CONNECTION_NAME ); } return $connection; } }
[Error] 
Class 'Bitrix\Main\Composite\Internals\Locker' not found (0)
/home/bitrix/www/bitrix/modules/main/lib/composite/engine.php:475
#0: Bitrix\Main\Composite\Engine::processPageContent(string)
	/home/bitrix/www/bitrix/modules/main/lib/composite/engine.php:422
#1: Bitrix\Main\Composite\Engine::endBuffering(string, string)
	/home/bitrix/www/bitrix/modules/main/classes/general/main.php:3195
#2: CAllMain->EndBufferContent(string)
	/home/bitrix/www/bitrix/modules/main/classes/general/main.php:3139
#3: CAllMain->EndBufferContentMan()
	/home/bitrix/www/bitrix/modules/main/include/epilog_after.php:36
#4: require(string)
	/home/bitrix/www/bitrix/modules/main/include/epilog.php:4
#5: require_once(string)
	/home/bitrix/www/bitrix/footer.php:4
#6: require(string)
	/home/bitrix/www/info/index.php:13