Unverified Commit df465cca authored by Sergei Morozov's avatar Sergei Morozov Committed by GitHub

Merge pull request #4142 from siimsoni/msyqli_opt_read_timeout

Add support for MYSQLI_OPT_READ_TIMEOUT
parents 0a4630aa c4325fd7
...@@ -11,7 +11,6 @@ use Doctrine\DBAL\Driver\ServerInfoAwareConnection; ...@@ -11,7 +11,6 @@ use Doctrine\DBAL\Driver\ServerInfoAwareConnection;
use Doctrine\DBAL\ParameterType; use Doctrine\DBAL\ParameterType;
use mysqli; use mysqli;
use function defined;
use function floor; use function floor;
use function func_get_args; use function func_get_args;
use function in_array; use function in_array;
...@@ -28,6 +27,7 @@ use function stripos; ...@@ -28,6 +27,7 @@ use function stripos;
use const MYSQLI_INIT_COMMAND; use const MYSQLI_INIT_COMMAND;
use const MYSQLI_OPT_CONNECT_TIMEOUT; use const MYSQLI_OPT_CONNECT_TIMEOUT;
use const MYSQLI_OPT_LOCAL_INFILE; use const MYSQLI_OPT_LOCAL_INFILE;
use const MYSQLI_OPT_READ_TIMEOUT;
use const MYSQLI_READ_DEFAULT_FILE; use const MYSQLI_READ_DEFAULT_FILE;
use const MYSQLI_READ_DEFAULT_GROUP; use const MYSQLI_READ_DEFAULT_GROUP;
use const MYSQLI_SERVER_PUBLIC_KEY; use const MYSQLI_SERVER_PUBLIC_KEY;
...@@ -245,15 +245,13 @@ class MysqliConnection implements ConnectionInterface, PingableConnection, Serve ...@@ -245,15 +245,13 @@ class MysqliConnection implements ConnectionInterface, PingableConnection, Serve
$supportedDriverOptions = [ $supportedDriverOptions = [
MYSQLI_OPT_CONNECT_TIMEOUT, MYSQLI_OPT_CONNECT_TIMEOUT,
MYSQLI_OPT_LOCAL_INFILE, MYSQLI_OPT_LOCAL_INFILE,
MYSQLI_OPT_READ_TIMEOUT,
MYSQLI_INIT_COMMAND, MYSQLI_INIT_COMMAND,
MYSQLI_READ_DEFAULT_FILE, MYSQLI_READ_DEFAULT_FILE,
MYSQLI_READ_DEFAULT_GROUP, MYSQLI_READ_DEFAULT_GROUP,
MYSQLI_SERVER_PUBLIC_KEY,
]; ];
if (defined('MYSQLI_SERVER_PUBLIC_KEY')) {
$supportedDriverOptions[] = MYSQLI_SERVER_PUBLIC_KEY;
}
$exceptionMsg = "%s option '%s' with value '%s'"; $exceptionMsg = "%s option '%s' with value '%s'";
foreach ($driverOptions as $option => $value) { foreach ($driverOptions as $option => $value) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment