Locks the cache for a given Request.
Request $request A Request instance:
Boolean|string true if the lock is acquired, the path to the current lock otherwise
Overrides StoreInterface::lock
public function lock(Request $request) {
if (false !== ($lock = @fopen($path = $this
->getPath($this
->getCacheKey($request) . '.lck'), 'x'))) {
fclose($lock);
$this->locks[] = $path;
return true;
}
return $path;
}