4 require_once
'Modules/TestQuestionPool/classes/class.ilAssQuestionProcessLocker.php';
33 $this->lockFileHandles = array();
38 $this->
requestLock(self::PROCESS_NAME_TEST_START_LOCK_CHECK);
43 $this->
releaseLock(self::PROCESS_NAME_TEST_START_LOCK_CHECK);
48 $this->
requestLock(self::PROCESS_NAME_RANDOM_PASS_BUILD);
53 $this->
releaseLock(self::PROCESS_NAME_RANDOM_PASS_BUILD);
59 $this->lockFileHandles[$processName] = fopen($lockFilePath,
'w');
60 flock($this->lockFileHandles[$processName], LOCK_EX);
65 $path = $this->lockFileStorage->getPath();
66 return $path.
'/'.$processName.
'.lock';
71 flock($this->lockFileHandles[$processName], LOCK_UN);
72 fclose($this->lockFileHandles[$processName]);