We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent e70402b commit dc5b25dCopy full SHA for dc5b25d
1 file changed
libs/Swoole/Async/MySQL.php
@@ -316,7 +316,8 @@ protected function doQuery($sql, callable $callback)
316
if ($mysqli->errno == 2013 or $mysqli->errno == 2006 or (isset($mysqli->_errno) and $mysqli->_errno == 2006))
317
{
318
$mysqli->close();
319
- $r = $mysqli->connect();
+ $config = $this->config;
320
+ $r = $mysqli->connect($config['host'], $config['user'], $config['password'], $config['database'], $config['port']);
321
if ($r === true)
322
323
continue;
@@ -351,7 +352,7 @@ function isFree() {
351
352
return (!$this->work_pool && count($this->wait_queue) == 0) ? true : false;
353
}
354
- function getConnectionNum() {
355
+ function getionNum() {
356
return $this->connection_num;
357
358
0 commit comments