改名
This commit is contained in:
@@ -40,7 +40,6 @@ class Redis extends Pool
|
|||||||
if (Context::hasContext($coroutineName)) {
|
if (Context::hasContext($coroutineName)) {
|
||||||
return Context::getContext($coroutineName);
|
return Context::getContext($coroutineName);
|
||||||
} else if (!$this->hasItem($coroutineName)) {
|
} else if (!$this->hasItem($coroutineName)) {
|
||||||
$this->success('create redis client -> ' . $config['host'] . ':' . $this->size($coroutineName));
|
|
||||||
return $this->saveClient($coroutineName, $this->createConnect($config));
|
return $this->saveClient($coroutineName, $this->createConnect($config));
|
||||||
}
|
}
|
||||||
return $this->getByChannel($coroutineName, $config);
|
return $this->getByChannel($coroutineName, $config);
|
||||||
@@ -55,9 +54,7 @@ class Redis extends Pool
|
|||||||
*/
|
*/
|
||||||
public function getByChannel($coroutineName, $config)
|
public function getByChannel($coroutineName, $config)
|
||||||
{
|
{
|
||||||
$this->info('redis client has :' . $this->size($coroutineName));
|
|
||||||
if (!$this->hasItem($coroutineName)) {
|
if (!$this->hasItem($coroutineName)) {
|
||||||
$this->success('create redis client -> ' . $config['host'] . ':' . $this->size($coroutineName));
|
|
||||||
return $this->saveClient($coroutineName, $this->createConnect($config));
|
return $this->saveClient($coroutineName, $this->createConnect($config));
|
||||||
}
|
}
|
||||||
[$time, $client] = $this->get($coroutineName);
|
[$time, $client] = $this->get($coroutineName);
|
||||||
|
|||||||
Reference in New Issue
Block a user