This commit is contained in:
2020-09-04 18:54:12 +08:00
parent 04ed73b902
commit 85f2d93a9c
+3
View File
@@ -215,6 +215,9 @@ class Connection extends Pool
private function nowClient($coroutineName, $config)
{
$client = $this->createConnect($config['cds'], $config['username'], $config['password']);
if ($this->hasLength($coroutineName)) {
return $this->getByChannel($coroutineName, $config);
}
$this->success('create db client -> ' . $config['cds'] . ':' . $this->hasLength($coroutineName));
if (isset(Context::getContext('begin_' . $coroutineName)[Coroutine::getCid()])) {
$number = Context::getContext('begin_' . $coroutineName)[Coroutine::getCid()];