You are here

protected function Predis::getKey in Redis 8

Generate a redis key name for the current lock name.

Parameters

string $name: Lock name.

Return value

string The redis key for the given lock.

3 calls to Predis::getKey()
Predis::acquire in src/Lock/Predis.php
Acquires a lock.
Predis::lockMayBeAvailable in src/Lock/Predis.php
Checks if a lock is available for acquiring.
Predis::release in src/Lock/Predis.php
Releases the given lock.

File

src/Lock/Predis.php, line 40

Class

Predis
Predis lock backend implementation.

Namespace

Drupal\redis\Lock

Code

protected function getKey($name) {
  return $this
    ->getPrefix() . ':lock:' . $name;
}