Bump the miniumum Node.js version required to 8.16
This commit is contained in:
parent
3e9b9e6216
commit
e3d1a69848
|
@ -7,7 +7,7 @@
|
|||
- Refactored the node-oracledb implementation to use
|
||||
[N-API](https://nodejs.org/api/n-api.html) in place of
|
||||
[NAN](https://github.com/nodejs/nan).
|
||||
- Node.js 8.12, or higher, is required by this version of node-oracledb. Note Node.js 8.16, 11.12 and 12 contain an important performance fix.
|
||||
- Node.js 8.16 or Node.js 10.16, or higher, is required by this version of node-oracledb. Node.js 8.16, 10.16, 11.12 and 12 contain an important N-API performance fix.
|
||||
- N-API allows node-oracledb binaries to be portable between Node.js versions on a given operating system, subject to N-API compatibility.
|
||||
- Oracle Client libraries are still required at runtime.
|
||||
- The string representation of classes has changed to `[Object Object]` as a consequence of using N-API.
|
||||
|
|
16
INSTALL.md
16
INSTALL.md
|
@ -54,12 +54,12 @@ The [*node-oracledb*][1] add-on for Node.js powers high performance Oracle Datab
|
|||
The steps below create a Node.js installation for testing. Adjust the
|
||||
steps for your environment.
|
||||
|
||||
This node-oracledb release has been tested with Node.js 8, 10 and 11
|
||||
on 64-bit Oracle Linux, Windows and macOS. Note Node.js 8.12 or later
|
||||
is required. The add-on can also build on some 32-bit Linux, 32-bit
|
||||
Windows, Solaris and AIX environments, but these architectures have
|
||||
not been fully tested. Older versions of node-oracledb may work with
|
||||
older versions of Node.js.
|
||||
This node-oracledb release has been tested with Node.js 8, 10 and 12
|
||||
on 64-bit Oracle Linux, Windows and macOS. Note Node.js 8.16, Node.js
|
||||
10.16, or later is required. The add-on can also build on some 32-bit
|
||||
Linux, 32-bit Windows, Solaris and AIX environments, but these
|
||||
architectures have not been fully tested. Older versions of
|
||||
node-oracledb may work with older versions of Node.js.
|
||||
|
||||
Node-oracledb is an [add-on](https://nodejs.org/api/addons.html)
|
||||
available as C source code. Pre-built binaries are available
|
||||
|
@ -72,8 +72,8 @@ guaranteed to be available or usable in your environment.
|
|||
|
||||
Node-oracledn 4.0 was refactored to use [N-API][53] version 2. On
|
||||
each operating system, a node-oracledb binary will work with a number
|
||||
of Node.js versions from Node.js 8.12 onwards, dependent on N-API
|
||||
compatibility.
|
||||
of Node.js versions from Node.js 8.16 and Node.js 10.16 onwards,
|
||||
dependent on N-API compatibility.
|
||||
|
||||
#### <a name="mig31"></a> 1.1 Changes in node-oracledb version 3.1
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
The node-oracledb add-on for Node.js powers high performance Oracle
|
||||
Database applications.
|
||||
|
||||
Use node-oracledb 4.0 to connect Node.js 8.12, 10 and 11 to Oracle Database.
|
||||
Use node-oracledb 4.0 to connect Node.js 8.16, 10.16, 12, or later, to Oracle Database.
|
||||
Older version of node-oracledb may work with older versions of Node.js
|
||||
|
||||
Node-oracledb supports basic and advanced features of Oracle Database
|
||||
|
|
|
@ -21,12 +21,17 @@
|
|||
|
||||
const nodbUtil = require('./util.js');
|
||||
|
||||
// This version of node-oracledb works with Node.js 8.12 or later.
|
||||
// The test stops hard-to-interpret runtime errors and crashes with
|
||||
// older Node.js versions.
|
||||
// This version of node-oracledb works with Node.js 8.16, 10.16 or
|
||||
// later. The test stops hard-to-interpret runtime errors and crashes
|
||||
// with older Node.js versions. Also Node.js 8.16 and 10.16 (and
|
||||
// 12.0) contain an important N-API performance regression fix. If
|
||||
// you're using the obsolete Node.js 9 or 11 versions, you're on your
|
||||
// own regarding performance and functionality
|
||||
let vs = process.version.substring(1).split(".").map(Number);
|
||||
if (vs[0] < 8 || (vs[0] === 8 && vs[1] < 12)) {
|
||||
throw new Error(nodbUtil.getErrorMessage('NJS-069', nodbUtil.PACKAGE_JSON_VERSION, "8.12"));
|
||||
if (vs[0] < 8 || (vs[0] === 8 && vs[1] < 16)) {
|
||||
throw new Error(nodbUtil.getErrorMessage('NJS-069', nodbUtil.PACKAGE_JSON_VERSION, "8.16"));
|
||||
} else if ((vs[0] === 10 && vs[1] < 16)) {
|
||||
throw new Error(nodbUtil.getErrorMessage('NJS-069', nodbUtil.PACKAGE_JSON_VERSION, "10.16"));
|
||||
}
|
||||
|
||||
const AqDeqOptions = require('./aqDeqOptions.js');
|
||||
|
|
|
@ -120,11 +120,18 @@ function done(err) {
|
|||
}
|
||||
}
|
||||
|
||||
// Check there is a usable binary file for the node-oracledb module
|
||||
// Check for a usable binary file for the node-oracledb module.
|
||||
// Node.js 8.16 and 10.16 (and 12.0) contain an important N-API
|
||||
// performance regression fix. If you're using the obsolete Node.js 9
|
||||
// or 11 versions, install will work but you're on your own regarding
|
||||
// performance and functionality.
|
||||
|
||||
function checkAvailable(cb) {
|
||||
let vs = process.version.substring(1).split(".").map(Number);
|
||||
if (vs[0] < 8 || (vs[0] === 8 && vs[1] < 12)) {
|
||||
cb(new Error(nodbUtil.getErrorMessage('NJS-069', nodbUtil.PACKAGE_JSON_VERSION, "8.12")));
|
||||
if (vs[0] < 8 || (vs[0] === 8 && vs[1] < 16)) {
|
||||
cb(new Error(nodbUtil.getErrorMessage('NJS-069', nodbUtil.PACKAGE_JSON_VERSION, "8.16")));
|
||||
} else if (vs[0] === 10 && vs[1] < 16) {
|
||||
cb(new Error(nodbUtil.getErrorMessage('NJS-069', nodbUtil.PACKAGE_JSON_VERSION, "10.16")));
|
||||
} else {
|
||||
try {
|
||||
fs.statSync(nodbUtil.RELEASE_DIR + '/' + nodbUtil.BINARY_FILE);
|
||||
|
|
Loading…
Reference in New Issue