oracledb 6.5.1 → 6.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/build/Release/oracledb-6.6.0-darwin-arm64.node +0 -0
- package/build/Release/oracledb-6.6.0-darwin-arm64.node-buildinfo.txt +1 -0
- package/build/Release/oracledb-6.6.0-darwin-x64.node +0 -0
- package/build/Release/oracledb-6.6.0-darwin-x64.node-buildinfo.txt +1 -0
- package/build/Release/oracledb-6.6.0-js-buildinfo.txt +1 -0
- package/build/Release/oracledb-6.6.0-linux-arm64.node +0 -0
- package/build/Release/oracledb-6.6.0-linux-arm64.node-buildinfo.txt +1 -0
- package/build/Release/oracledb-6.6.0-linux-x64.node +0 -0
- package/build/Release/oracledb-6.6.0-linux-x64.node-buildinfo.txt +1 -0
- package/build/Release/oracledb-6.6.0-win32-x64.node +0 -0
- package/build/Release/oracledb-6.6.0-win32-x64.node-buildinfo.txt +1 -0
- package/examples/README.md +2 -0
- package/lib/configProviders/azure.js +167 -0
- package/lib/configProviders/base.js +99 -0
- package/lib/configProviders/ociobject.js +203 -0
- package/lib/connection.js +28 -12
- package/lib/constants.js +1 -0
- package/lib/errors.js +56 -1
- package/lib/impl/datahandlers/constants.js +3 -1
- package/lib/impl/datahandlers/vector.js +24 -9
- package/lib/impl/lob.js +27 -0
- package/lib/impl/resultset.js +26 -1
- package/lib/lob.js +52 -1
- package/lib/oracledb.js +54 -0
- package/lib/thin/connection.js +232 -16
- package/lib/thin/dbObject.js +4 -0
- package/lib/thin/lob.js +193 -1
- package/lib/thin/pool.js +15 -0
- package/lib/thin/protocol/capabilities.js +2 -0
- package/lib/thin/protocol/constants.js +29 -1
- package/lib/thin/protocol/messages/index.js +5 -1
- package/lib/thin/protocol/messages/lobOp.js +17 -5
- package/lib/thin/protocol/messages/transactionChangeState.js +99 -0
- package/lib/thin/protocol/messages/transactionSwitch.js +139 -0
- package/lib/thin/protocol/messages/withData.js +26 -6
- package/lib/thin/sqlnet/networkSession.js +2 -1
- package/lib/thin/sqlnet/paramParser.js +87 -50
- package/lib/thin/sqlnet/sessionAtts.js +13 -1
- package/lib/transformer.js +1 -2
- package/lib/types.js +1 -1
- package/lib/util.js +34 -2
- package/lib/version.js +2 -2
- package/package.json +1 -1
- package/build/Release/oracledb-6.5.1-darwin-x64.node +0 -0
- package/build/Release/oracledb-6.5.1-darwin-x64.node-buildinfo.txt +0 -1
- package/build/Release/oracledb-6.5.1-js-buildinfo.txt +0 -1
- package/build/Release/oracledb-6.5.1-linux-arm64.node +0 -0
- package/build/Release/oracledb-6.5.1-linux-arm64.node-buildinfo.txt +0 -1
- package/build/Release/oracledb-6.5.1-linux-x64.node +0 -0
- package/build/Release/oracledb-6.5.1-linux-x64.node-buildinfo.txt +0 -1
- package/build/Release/oracledb-6.5.1-win32-x64.node +0 -0
- package/build/Release/oracledb-6.5.1-win32-x64.node-buildinfo.txt +0 -1
|
@@ -77,6 +77,9 @@ class SessionAtts {
|
|
|
77
77
|
if (typeof params.walletPassword === 'string') {
|
|
78
78
|
this.nt.walletPassword = params.walletPassword;
|
|
79
79
|
}
|
|
80
|
+
if (typeof params.walletContent === 'string') {
|
|
81
|
+
this.nt.wallet = params.walletContent;
|
|
82
|
+
}
|
|
80
83
|
if (params.expireTime > 0) {
|
|
81
84
|
this.nt.expireTime = params.expireTime * 1000 * 60;
|
|
82
85
|
}
|
|
@@ -135,6 +138,15 @@ class SessionAtts {
|
|
|
135
138
|
});
|
|
136
139
|
}
|
|
137
140
|
|
|
141
|
+
/**
|
|
142
|
+
* Clear wallet
|
|
143
|
+
*/
|
|
144
|
+
clearWallet() {
|
|
145
|
+
if (this.nt.wallet && Buffer.isBuffer(this.nt.wallet))
|
|
146
|
+
this.nt.wallet.fill(0);
|
|
147
|
+
this.nt.wallet = null;
|
|
148
|
+
}
|
|
149
|
+
|
|
138
150
|
/**
|
|
139
151
|
* Prepare attributes for connection, Generate Connection ID and read Wallet file
|
|
140
152
|
*
|
|
@@ -151,7 +163,7 @@ class SessionAtts {
|
|
|
151
163
|
}
|
|
152
164
|
this.nt.connectionId = this.connectionId;
|
|
153
165
|
|
|
154
|
-
if (protocol && (protocol.toUpperCase() == "TCPS" && this.nt.walletFile)) {
|
|
166
|
+
if (protocol && (protocol.toUpperCase() == "TCPS" && !this.nt.wallet && this.nt.walletFile)) {
|
|
155
167
|
this.nt.wallet = await this.readWalletFile();
|
|
156
168
|
}
|
|
157
169
|
|
package/lib/transformer.js
CHANGED
|
@@ -228,8 +228,7 @@ function transformValueIn(info, value, options) {
|
|
|
228
228
|
return value._impl;
|
|
229
229
|
|
|
230
230
|
// handle vectors
|
|
231
|
-
} else if (value
|
|
232
|
-
value instanceof Int8Array) {
|
|
231
|
+
} else if (nodbUtil.isVectorValue(value)) {
|
|
233
232
|
checkType(info, options, types.DB_TYPE_VECTOR);
|
|
234
233
|
return value;
|
|
235
234
|
} else if (info.type === types.DB_TYPE_VECTOR && Array.isArray(value)) {
|
package/lib/types.js
CHANGED
|
@@ -112,7 +112,7 @@ function getTypeByOraTypeNum(oraTypeNum, csfrm) {
|
|
|
112
112
|
|
|
113
113
|
const DB_TYPE_BFILE = new DbType(2020,
|
|
114
114
|
"DB_TYPE_BFILE", "BFILE",
|
|
115
|
-
{ oraTypeNum: 114, bufferSizeFactor:
|
|
115
|
+
{ oraTypeNum: 114, bufferSizeFactor: 4000 });
|
|
116
116
|
const DB_TYPE_BINARY_DOUBLE = new DbType(2008,
|
|
117
117
|
"DB_TYPE_BINARY_DOUBLE", "BINARY_DOUBLE",
|
|
118
118
|
{ oraTypeNum: 101, bufferSizeFactor: 8 });
|
package/lib/util.js
CHANGED
|
@@ -277,6 +277,36 @@ function isXid(value) {
|
|
|
277
277
|
typeof value.branchQualifier === 'string'));
|
|
278
278
|
}
|
|
279
279
|
|
|
280
|
+
function normalizeXid(value) {
|
|
281
|
+
let normalizedXid;
|
|
282
|
+
if (Buffer.isBuffer(value.globalTransactionId) &&
|
|
283
|
+
Buffer.isBuffer(value.branchQualifier)) {
|
|
284
|
+
normalizedXid = value;
|
|
285
|
+
} else {
|
|
286
|
+
normalizedXid = {
|
|
287
|
+
formatId: value.formatId,
|
|
288
|
+
globalTransactionId: value.globalTransactionId,
|
|
289
|
+
branchQualifier: value.branchQualifier
|
|
290
|
+
};
|
|
291
|
+
if (typeof value.globalTransactionId === 'string') {
|
|
292
|
+
normalizedXid.globalTransactionId = Buffer.from(value.globalTransactionId);
|
|
293
|
+
}
|
|
294
|
+
if (typeof value.branchQualifier === 'string') {
|
|
295
|
+
normalizedXid.branchQualifier = Buffer.from(value.branchQualifier);
|
|
296
|
+
}
|
|
297
|
+
}
|
|
298
|
+
if (normalizedXid.globalTransactionId.length > 64) {
|
|
299
|
+
errors.throwErr(errors.ERR_INVALID_TRANSACTION_SIZE,
|
|
300
|
+
normalizedXid.globalTransactionId.length);
|
|
301
|
+
}
|
|
302
|
+
if (normalizedXid.branchQualifier.length > 64) {
|
|
303
|
+
errors.throwErr(errors.ERR_INVALID_BRANCH_SIZE,
|
|
304
|
+
normalizedXid.branchQualifier.length);
|
|
305
|
+
}
|
|
306
|
+
|
|
307
|
+
return normalizedXid;
|
|
308
|
+
}
|
|
309
|
+
|
|
280
310
|
function verifySodaDoc(content) {
|
|
281
311
|
if (isSodaDocument(content))
|
|
282
312
|
return content._impl;
|
|
@@ -362,8 +392,9 @@ function addTypeProperties(obj, attrName) {
|
|
|
362
392
|
// -----------------------------------------------------------------------------
|
|
363
393
|
function isVectorValue(value) {
|
|
364
394
|
return (value instanceof Float32Array ||
|
|
365
|
-
|
|
366
|
-
|
|
395
|
+
value instanceof Float64Array ||
|
|
396
|
+
value instanceof Int8Array || (Object.getPrototypeOf(value)
|
|
397
|
+
=== Uint8Array.prototype));
|
|
367
398
|
}
|
|
368
399
|
|
|
369
400
|
//-----------------------------------------------------------------------------
|
|
@@ -403,6 +434,7 @@ module.exports = {
|
|
|
403
434
|
isTokenValid,
|
|
404
435
|
isVectorValue,
|
|
405
436
|
isXid,
|
|
437
|
+
normalizeXid,
|
|
406
438
|
makeDate,
|
|
407
439
|
preventConcurrent,
|
|
408
440
|
serialize,
|
package/lib/version.js
CHANGED
package/package.json
CHANGED
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
oracledb-6.5.1-darwin-x64.node v20.11.1 572ce8bae4965b47d3554fa08a0d131acb4dc70b 077b92ae23b597c7854563e2ab4506966aa5fe40 Fri, 17 May 2024 14:57:54 GMT
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
572ce8bae4965b47d3554fa08a0d131acb4dc70b
|
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
oracledb-6.5.1-linux-arm64.node v18.19.1 572ce8bae4965b47d3554fa08a0d131acb4dc70b 077b92ae23b597c7854563e2ab4506966aa5fe40 Fri, 17 May 2024 15:07:07 GMT
|
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
oracledb-6.5.1-linux-x64.node v16.20.2 572ce8bae4965b47d3554fa08a0d131acb4dc70b 077b92ae23b597c7854563e2ab4506966aa5fe40 Fri, 17 May 2024 15:08:37 GMT
|
|
Binary file
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
oracledb-6.5.1-win32-x64.node v18.16.0 572ce8bae4965b47d3554fa08a0d131acb4dc70b 077b92ae23b597c7854563e2ab4506966aa5fe40 Fri, 17 May 2024 15:09:11 GMT
|