Comparing version 2.3.0 to 2.3.1
# Change Log | ||
## [2.3.1](https://github.com/mariadb-corporation/mariadb-connector-nodejs/tree/2.3.1) (19 Mar. 2020) | ||
[Full Changelog](https://github.com/mariadb-corporation/mariadb-connector-nodejs/compare/2.3.0...2.3.1) | ||
Corrective release of 2.3.0, changing new connection option `timeout` to `queryTimeout` to avoid any confusion. | ||
## [2.3.0](https://github.com/mariadb-corporation/mariadb-connector-nodejs/tree/2.3.0) (19 Mar. 2020) | ||
@@ -3,0 +8,0 @@ [Full Changelog](https://github.com/mariadb-corporation/mariadb-connector-nodejs/compare/2.2.0...2.3.0) |
@@ -0,0 +0,0 @@ 'use strict'; |
@@ -0,0 +0,0 @@ 'use strict'; |
@@ -92,4 +92,2 @@ 'use strict'; | ||
this.opts = connOpts; | ||
// we only need add timeout if needed | ||
this.opts.timeout = 0; | ||
return; | ||
@@ -96,0 +94,0 @@ } |
@@ -55,3 +55,3 @@ 'use strict'; | ||
this.connectTimeout = opts.connectTimeout === undefined ? 10000 : opts.connectTimeout; | ||
this.timeout = opts.timeout === undefined ? 0 : opts.timeout; | ||
this.queryTimeout = opts.queryTimeout === undefined ? 0 : opts.queryTimeout; | ||
this.socketTimeout = opts.socketTimeout === undefined ? 0 : opts.socketTimeout; | ||
@@ -179,3 +179,3 @@ this.database = opts.database; | ||
if (opts.debugLen) opts.debugLen = parseInt(opts.debugLen); | ||
if (opts.timeout) opts.timeout = parseInt(opts.timeout); | ||
if (opts.queryTimeout) opts.queryTimeout = parseInt(opts.queryTimeout); | ||
if (opts.foundRows) opts.foundRows = opts.foundRows == 'true'; | ||
@@ -182,0 +182,0 @@ if (opts.maxAllowedPacket && !isNaN(Number.parseInt(opts.maxAllowedPacket))) |
@@ -814,3 +814,3 @@ 'use strict'; | ||
const _executeSessionTimeout = () => { | ||
if (opts.timeout) { | ||
if (opts.queryTimeout) { | ||
if (info.isMariaDB() && info.hasMinVersion(10, 1, 2)) { | ||
@@ -821,3 +821,3 @@ return new Promise(function(resolve, reject) { | ||
Errors.createError( | ||
'Error setting session timeout: ' + initialErr.message, | ||
'Error setting session queryTimeout: ' + initialErr.message, | ||
true, | ||
@@ -836,3 +836,3 @@ info, | ||
opts, | ||
'SET max_statement_time=' + opts.timeout / 1000, | ||
'SET max_statement_time=' + opts.queryTimeout / 1000, | ||
null | ||
@@ -846,3 +846,4 @@ ); | ||
Errors.createError( | ||
'Can only use timeout for MariaDB server after 10.1.1. timeout value: ' + opts.timeout, | ||
'Can only use queryTimeout for MariaDB server after 10.1.1. queryTimeout value: ' + | ||
opts.queryTimeout, | ||
false, | ||
@@ -849,0 +850,0 @@ info, |
@@ -0,0 +0,0 @@ 'use strict'; |
@@ -0,0 +0,0 @@ 'use strict'; |
{ | ||
"name": "mariadb", | ||
"version": "2.3.0", | ||
"version": "2.3.1", | ||
"description": "fast mariadb/mysql connector.", | ||
@@ -5,0 +5,0 @@ "main": "promise.js", |
@@ -0,0 +0,0 @@ /* eslint-disable @typescript-eslint/no-explicit-any */ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Deprecated
MaintenanceThe maintainer of the package marked it as deprecated. This could indicate that a single version should not be used, or that the package is no longer maintained and any new vulnerabilities will not be fixed.
Found 1 instance in 1 package
0
501971
13252