예제 #1
0
 /**
  * Shut down the mutex client.
  *
  * Be sure to release all locks you acquired before,
  * so other clients will be able to acquire them.
  *
  * @return Promise
  */
 public function shutdown() : Promise
 {
     cancel($this->watcher);
     $promises = [$this->std->close()];
     foreach ($this->busyConnections as $connection) {
         $promises[] = $connection->close();
     }
     foreach ($this->readyConnections as list($time, $connection)) {
         $promises[] = $connection->close();
     }
     return all($promises);
 }
예제 #2
0
파일: RedisCache.php 프로젝트: amphp/cache
 /**
  * {@inheritdoc}
  */
 public function del($key)
 {
     return $this->client->del($key);
 }