logixia 1.3.0 → 1.4.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 +848 -7
- package/dist/.tsbuildinfo +1 -0
- package/dist/{index-iDTW2-eY.d.mts → index-Ium497V3.d.mts} +180 -2
- package/dist/index-Ium497V3.d.mts.map +1 -0
- package/dist/{index-CHIsdA9n.d.ts → index-t-ActikQ.d.ts} +180 -2
- package/dist/index-t-ActikQ.d.ts.map +1 -0
- package/dist/index.d.mts +458 -3
- package/dist/index.d.mts.map +1 -1
- package/dist/index.d.ts +458 -3
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +436 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +416 -3
- package/dist/index.mjs.map +1 -1
- package/dist/{logitron-logger.module-C0G8JGVf.d.ts → logitron-logger.module-9vOhKWDG.d.ts} +120 -6
- package/dist/logitron-logger.module-9vOhKWDG.d.ts.map +1 -0
- package/dist/{logitron-logger.module-2AzkadqZ.mjs → logitron-logger.module-C939PIEV.mjs} +331 -10
- package/dist/logitron-logger.module-C939PIEV.mjs.map +1 -0
- package/dist/{logitron-logger.module-BqNKp0Fs.js → logitron-logger.module-CCnX7GwK.js} +383 -8
- package/dist/logitron-logger.module-CCnX7GwK.js.map +1 -0
- package/dist/{logitron-logger.module-DQKaZTJL.d.mts → logitron-logger.module-SArymP6b.d.mts} +120 -6
- package/dist/logitron-logger.module-SArymP6b.d.mts.map +1 -0
- package/dist/middleware.d.mts +1 -1
- package/dist/middleware.d.ts +1 -1
- package/dist/nest.d.mts +2 -2
- package/dist/nest.d.ts +2 -2
- package/dist/nest.js +2 -2
- package/dist/nest.mjs +2 -2
- package/dist/{promise-DaiZ2BaH.js → promise-BI-3eI4n.js} +285 -128
- package/dist/promise-BI-3eI4n.js.map +1 -0
- package/dist/{promise-C4pQPcK4.mjs → promise-BrZcjavs.mjs} +285 -128
- package/dist/promise-BrZcjavs.mjs.map +1 -0
- package/dist/testing.d.mts +1 -1
- package/dist/testing.d.ts +1 -1
- package/dist/testing.js +7 -1
- package/dist/testing.js.map +1 -1
- package/dist/testing.mjs +7 -1
- package/dist/testing.mjs.map +1 -1
- package/dist/{transport.manager-5VVdqS3o.mjs → transport.manager-DR7TLXQT.mjs} +82 -4
- package/dist/transport.manager-DR7TLXQT.mjs.map +1 -0
- package/dist/{transport.manager-DCOm4uIQ.js → transport.manager-DVTM978M.js} +82 -4
- package/dist/transport.manager-DVTM978M.js.map +1 -0
- package/dist/transports.d.mts +61 -168
- package/dist/transports.d.mts.map +1 -1
- package/dist/transports.d.ts +61 -168
- package/dist/transports.d.ts.map +1 -1
- package/dist/transports.js +1 -1
- package/dist/transports.mjs +1 -1
- package/package.json +72 -9
- package/dist/index-CHIsdA9n.d.ts.map +0 -1
- package/dist/index-iDTW2-eY.d.mts.map +0 -1
- package/dist/logitron-logger.module-2AzkadqZ.mjs.map +0 -1
- package/dist/logitron-logger.module-BqNKp0Fs.js.map +0 -1
- package/dist/logitron-logger.module-C0G8JGVf.d.ts.map +0 -1
- package/dist/logitron-logger.module-DQKaZTJL.d.mts.map +0 -1
- package/dist/promise-C4pQPcK4.mjs.map +0 -1
- package/dist/promise-DaiZ2BaH.js.map +0 -1
- package/dist/transport.manager-5VVdqS3o.mjs.map +0 -1
- package/dist/transport.manager-DCOm4uIQ.js.map +0 -1
|
@@ -17635,7 +17635,7 @@ var require_text_row = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/pac
|
|
|
17635
17635
|
//#endregion
|
|
17636
17636
|
//#region node_modules/mysql2/lib/packets/index.js
|
|
17637
17637
|
var require_packets = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/packets/index.js": ((exports, module) => {
|
|
17638
|
-
const process$
|
|
17638
|
+
const process$5 = __require("process");
|
|
17639
17639
|
const ctorMap = {
|
|
17640
17640
|
AuthNextFactor: require_auth_next_factor(),
|
|
17641
17641
|
AuthSwitchRequest: require_auth_switch_request(),
|
|
@@ -17659,7 +17659,7 @@ var require_packets = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/pack
|
|
|
17659
17659
|
};
|
|
17660
17660
|
Object.entries(ctorMap).forEach(([name, ctor]) => {
|
|
17661
17661
|
module.exports[name] = ctor;
|
|
17662
|
-
if (process$
|
|
17662
|
+
if (process$5.env.NODE_DEBUG) {
|
|
17663
17663
|
if (ctor.prototype.toPacket) {
|
|
17664
17664
|
const old = ctor.prototype.toPacket;
|
|
17665
17665
|
ctor.prototype.toPacket = function() {
|
|
@@ -17794,7 +17794,10 @@ var require_sha256_password = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/
|
|
|
17794
17794
|
const STATE_FINAL$1 = -1;
|
|
17795
17795
|
function encrypt$1(password, scramble, key$1) {
|
|
17796
17796
|
const stage1 = xorRotating$1(Buffer.from(`${password}\0`, "utf8"), scramble);
|
|
17797
|
-
return crypto$1.publicEncrypt(
|
|
17797
|
+
return crypto$1.publicEncrypt({
|
|
17798
|
+
key: key$1,
|
|
17799
|
+
oaepHash: "sha1"
|
|
17800
|
+
}, stage1);
|
|
17798
17801
|
}
|
|
17799
17802
|
module.exports = (pluginOptions = {}) => ({ connection }) => {
|
|
17800
17803
|
let state = 0;
|
|
@@ -17851,6 +17854,7 @@ var require_caching_sha2_password = /* @__PURE__ */ __commonJS({ "node_modules/m
|
|
|
17851
17854
|
const stage1 = xorRotating(Buffer.from(`${password}\0`, "utf8"), scramble);
|
|
17852
17855
|
return crypto.publicEncrypt({
|
|
17853
17856
|
key: key$1,
|
|
17857
|
+
oaepHash: "sha1",
|
|
17854
17858
|
padding: crypto.constants.RSA_PKCS1_OAEP_PADDING
|
|
17855
17859
|
}, stage1);
|
|
17856
17860
|
}
|
|
@@ -19179,7 +19183,7 @@ var require_static_text_parser = /* @__PURE__ */ __commonJS({ "node_modules/mysq
|
|
|
19179
19183
|
//#endregion
|
|
19180
19184
|
//#region node_modules/mysql2/lib/commands/query.js
|
|
19181
19185
|
var require_query = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/commands/query.js": ((exports, module) => {
|
|
19182
|
-
const process$
|
|
19186
|
+
const process$4 = __require("process");
|
|
19183
19187
|
const Timers$1 = __require("timers");
|
|
19184
19188
|
const Readable$1 = __require("stream").Readable;
|
|
19185
19189
|
const Command$8 = require_command();
|
|
@@ -19239,10 +19243,10 @@ var require_query = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/comman
|
|
|
19239
19243
|
rows = this._rows;
|
|
19240
19244
|
fields$1 = this._fields;
|
|
19241
19245
|
}
|
|
19242
|
-
if (fields$1) process$
|
|
19246
|
+
if (fields$1) process$4.nextTick(() => {
|
|
19243
19247
|
this.onResult(null, rows, fields$1);
|
|
19244
19248
|
});
|
|
19245
|
-
else process$
|
|
19249
|
+
else process$4.nextTick(() => {
|
|
19246
19250
|
this.onResult(null, rows);
|
|
19247
19251
|
});
|
|
19248
19252
|
}
|
|
@@ -20232,7 +20236,7 @@ var require_commands = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/com
|
|
|
20232
20236
|
var require_package = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/package.json": ((exports, module) => {
|
|
20233
20237
|
module.exports = {
|
|
20234
20238
|
"name": "mysql2",
|
|
20235
|
-
"version": "3.
|
|
20239
|
+
"version": "3.20.0",
|
|
20236
20240
|
"description": "fast mysql driver. Implements core protocol, prepared statements, ssl and compression in native JS",
|
|
20237
20241
|
"main": "index.js",
|
|
20238
20242
|
"typings": "typings/mysql/index",
|
|
@@ -20240,15 +20244,9 @@ var require_package = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/package.
|
|
|
20240
20244
|
"scripts": {
|
|
20241
20245
|
"lint": "eslint . && prettier --check .",
|
|
20242
20246
|
"lint:fix": "eslint . --fix && prettier --write .",
|
|
20243
|
-
"test": "
|
|
20244
|
-
"test:
|
|
20245
|
-
"test:
|
|
20246
|
-
"test:bun": "npm run test:bun:parallel && npm run test:bun:global",
|
|
20247
|
-
"test:bun:parallel": "bun poku -c=\"poku.config.mjs\" test",
|
|
20248
|
-
"test:bun:global": "cross-env SUITE=global bun poku -c=\"poku.config.mjs\" test/global",
|
|
20249
|
-
"test:deno": "npm run test:deno:parallel && npm run test:deno:global",
|
|
20250
|
-
"test:deno:parallel": "deno run --allow-read --allow-env --allow-run npm:poku -c=\"poku.config.mjs\" test",
|
|
20251
|
-
"test:deno:global": "cross-env SUITE=global deno run --allow-read --allow-env --allow-run npm:poku -c=\"poku.config.mjs\" test/global",
|
|
20247
|
+
"test": "poku",
|
|
20248
|
+
"test:bun": "bun poku",
|
|
20249
|
+
"test:deno": "deno run -A npm:poku",
|
|
20252
20250
|
"test:docker:up": "docker compose -f test/docker-compose.yml up --abort-on-container-exit --remove-orphans",
|
|
20253
20251
|
"test:docker:down": "docker compose -f test/docker-compose.yml down",
|
|
20254
20252
|
"test:docker:node": "npm run test:docker:up -- node && npm run test:docker:down",
|
|
@@ -20256,6 +20254,7 @@ var require_package = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/package.
|
|
|
20256
20254
|
"test:docker:deno": "npm run test:docker:up -- deno && npm run test:docker:down",
|
|
20257
20255
|
"test:docker:coverage": "npm run test:docker:up -- coverage && npm run test:docker:down",
|
|
20258
20256
|
"test:coverage": "c8 npm test",
|
|
20257
|
+
"test:build": "rollup -c",
|
|
20259
20258
|
"typecheck": "cd \"test/tsc-build\" && tsc -p \"tsconfig.json\" && cd .. && tsc -p \"tsconfig.json\" --noEmit",
|
|
20260
20259
|
"benchmark": "node ./benchmarks/benchmark.js",
|
|
20261
20260
|
"wait-port": "wait-on"
|
|
@@ -20303,21 +20302,25 @@ var require_package = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/package.
|
|
|
20303
20302
|
"@eslint/js": "^9.39.2",
|
|
20304
20303
|
"@eslint/markdown": "^7.5.1",
|
|
20305
20304
|
"@ianvs/prettier-plugin-sort-imports": "^4.7.1",
|
|
20305
|
+
"@pokujs/multi-suite": "^1.0.0",
|
|
20306
|
+
"@rollup/plugin-commonjs": "^29.0.2",
|
|
20307
|
+
"@rollup/plugin-json": "^6.1.0",
|
|
20308
|
+
"@rollup/plugin-node-resolve": "^16.0.3",
|
|
20306
20309
|
"@types/node": "^25.3.0",
|
|
20307
20310
|
"@typescript-eslint/eslint-plugin": "^8.56.0",
|
|
20308
20311
|
"@typescript-eslint/parser": "^8.56.0",
|
|
20309
20312
|
"assert-diff": "^3.0.4",
|
|
20310
20313
|
"benchmark": "^2.1.4",
|
|
20311
20314
|
"c8": "^11.0.0",
|
|
20312
|
-
"cross-env": "^10.1.0",
|
|
20313
20315
|
"error-stack-parser": "^2.1.4",
|
|
20314
20316
|
"eslint-config-prettier": "^10.1.8",
|
|
20315
20317
|
"eslint-plugin-async-await": "^0.0.0",
|
|
20316
20318
|
"eslint-plugin-prettier": "^5.5.5",
|
|
20317
20319
|
"globals": "^17.3.0",
|
|
20318
|
-
"poku": "^4.
|
|
20320
|
+
"poku": "^4.1.0",
|
|
20319
20321
|
"portfinder": "^1.0.38",
|
|
20320
20322
|
"prettier": "^3.8.1",
|
|
20323
|
+
"rollup": "^4.59.0",
|
|
20321
20324
|
"tsx": "^4.21.0",
|
|
20322
20325
|
"typescript": "^5.9.3"
|
|
20323
20326
|
}
|
|
@@ -20705,6 +20708,59 @@ var require_connection_config = /* @__PURE__ */ __commonJS({ "node_modules/mysql
|
|
|
20705
20708
|
module.exports = ConnectionConfig$3;
|
|
20706
20709
|
}) });
|
|
20707
20710
|
|
|
20711
|
+
//#endregion
|
|
20712
|
+
//#region node_modules/mysql2/lib/tracing.js
|
|
20713
|
+
var require_tracing = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/tracing.js": ((exports, module) => {
|
|
20714
|
+
const process$3 = __require("process");
|
|
20715
|
+
const dc = (() => {
|
|
20716
|
+
try {
|
|
20717
|
+
return "getBuiltinModule" in process$3 ? process$3.getBuiltinModule("node:diagnostics_channel") : __require("node:diagnostics_channel");
|
|
20718
|
+
} catch {
|
|
20719
|
+
return;
|
|
20720
|
+
}
|
|
20721
|
+
})();
|
|
20722
|
+
const hasTracingChannel = typeof (dc === null || dc === void 0 ? void 0 : dc.tracingChannel) === "function";
|
|
20723
|
+
const queryChannel$1 = hasTracingChannel ? dc.tracingChannel("mysql2:query") : void 0;
|
|
20724
|
+
const executeChannel$1 = hasTracingChannel ? dc.tracingChannel("mysql2:execute") : void 0;
|
|
20725
|
+
const connectChannel$1 = hasTracingChannel ? dc.tracingChannel("mysql2:connect") : void 0;
|
|
20726
|
+
const poolConnectChannel$1 = hasTracingChannel ? dc.tracingChannel("mysql2:pool:connect") : void 0;
|
|
20727
|
+
function getServerContext$2(config) {
|
|
20728
|
+
if (config.socketPath) return {
|
|
20729
|
+
serverAddress: config.socketPath,
|
|
20730
|
+
serverPort: void 0
|
|
20731
|
+
};
|
|
20732
|
+
return {
|
|
20733
|
+
serverAddress: config.host || "localhost",
|
|
20734
|
+
serverPort: config.port || 3306
|
|
20735
|
+
};
|
|
20736
|
+
}
|
|
20737
|
+
function shouldTrace$1(channel) {
|
|
20738
|
+
var _channel$start;
|
|
20739
|
+
if (channel === void 0 || channel === null) return false;
|
|
20740
|
+
return channel.hasSubscribers ?? ((_channel$start = channel.start) === null || _channel$start === void 0 ? void 0 : _channel$start.hasSubscribers) ?? false;
|
|
20741
|
+
}
|
|
20742
|
+
function traceCallback$2(channel, fn, position, context, thisArg, ...args) {
|
|
20743
|
+
if (shouldTrace$1(channel)) return channel.traceCallback(fn, position, context(), thisArg, ...args);
|
|
20744
|
+
return fn.apply(thisArg, args);
|
|
20745
|
+
}
|
|
20746
|
+
function tracePromise$1(channel, fn, contextFactory) {
|
|
20747
|
+
if (shouldTrace$1(channel)) return channel.tracePromise(fn, contextFactory());
|
|
20748
|
+
return fn();
|
|
20749
|
+
}
|
|
20750
|
+
module.exports = {
|
|
20751
|
+
dc,
|
|
20752
|
+
hasTracingChannel,
|
|
20753
|
+
shouldTrace: shouldTrace$1,
|
|
20754
|
+
queryChannel: queryChannel$1,
|
|
20755
|
+
executeChannel: executeChannel$1,
|
|
20756
|
+
connectChannel: connectChannel$1,
|
|
20757
|
+
poolConnectChannel: poolConnectChannel$1,
|
|
20758
|
+
getServerContext: getServerContext$2,
|
|
20759
|
+
traceCallback: traceCallback$2,
|
|
20760
|
+
tracePromise: tracePromise$1
|
|
20761
|
+
};
|
|
20762
|
+
}) });
|
|
20763
|
+
|
|
20708
20764
|
//#endregion
|
|
20709
20765
|
//#region node_modules/named-placeholders/index.js
|
|
20710
20766
|
var require_named_placeholders = /* @__PURE__ */ __commonJS({ "node_modules/named-placeholders/index.js": ((exports, module) => {
|
|
@@ -20846,9 +20902,10 @@ var require_connection$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib
|
|
|
20846
20902
|
const Commands = require_commands();
|
|
20847
20903
|
const ConnectionConfig$2 = require_connection_config();
|
|
20848
20904
|
const CharsetToEncoding = require_charset_encodings();
|
|
20905
|
+
const { traceCallback: traceCallback$1, tracePromise, getServerContext: getServerContext$1, shouldTrace, queryChannel, executeChannel, connectChannel } = require_tracing();
|
|
20849
20906
|
let _connectionId = 0;
|
|
20850
20907
|
let convertNamedPlaceholders = null;
|
|
20851
|
-
var BaseConnection$
|
|
20908
|
+
var BaseConnection$3 = class BaseConnection$3 extends EventEmitter$5 {
|
|
20852
20909
|
constructor(opts) {
|
|
20853
20910
|
super();
|
|
20854
20911
|
this.config = opts.config;
|
|
@@ -20920,6 +20977,30 @@ var require_connection$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib
|
|
|
20920
20977
|
this._notifyError(err);
|
|
20921
20978
|
});
|
|
20922
20979
|
this.addCommand(handshakeCommand);
|
|
20980
|
+
if (shouldTrace(connectChannel)) {
|
|
20981
|
+
const config = this.config;
|
|
20982
|
+
tracePromise(connectChannel, () => new Promise((resolve, reject) => {
|
|
20983
|
+
let onConnect, onError;
|
|
20984
|
+
onConnect = (param) => {
|
|
20985
|
+
this.removeListener("error", onError);
|
|
20986
|
+
resolve(param);
|
|
20987
|
+
};
|
|
20988
|
+
onError = (err) => {
|
|
20989
|
+
this.removeListener("connect", onConnect);
|
|
20990
|
+
reject(err);
|
|
20991
|
+
};
|
|
20992
|
+
this.once("connect", onConnect);
|
|
20993
|
+
this.once("error", onError);
|
|
20994
|
+
}), () => {
|
|
20995
|
+
const server = getServerContext$1(config);
|
|
20996
|
+
return {
|
|
20997
|
+
database: config.database || "",
|
|
20998
|
+
serverAddress: server.serverAddress,
|
|
20999
|
+
serverPort: server.serverPort,
|
|
21000
|
+
user: config.user || ""
|
|
21001
|
+
};
|
|
21002
|
+
}).catch(() => {});
|
|
21003
|
+
}
|
|
20923
21004
|
}
|
|
20924
21005
|
this.serverEncoding = "utf8";
|
|
20925
21006
|
if (this.config.connectTimeout) {
|
|
@@ -21201,10 +21282,38 @@ var require_connection$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib
|
|
|
21201
21282
|
query(sql, values, cb) {
|
|
21202
21283
|
let cmdQuery;
|
|
21203
21284
|
if (sql.constructor === Commands.Query) cmdQuery = sql;
|
|
21204
|
-
else cmdQuery = BaseConnection$
|
|
21285
|
+
else cmdQuery = BaseConnection$3.createQuery(sql, values, cb, this.config);
|
|
21205
21286
|
this._resolveNamedPlaceholders(cmdQuery);
|
|
21206
21287
|
cmdQuery.sql = this.format(cmdQuery.sql, cmdQuery.values !== void 0 ? cmdQuery.values : []);
|
|
21207
|
-
|
|
21288
|
+
if (cmdQuery.onResult) traceCallback$1(queryChannel, (wrappedCb) => {
|
|
21289
|
+
cmdQuery.onResult = wrappedCb;
|
|
21290
|
+
this.addCommand(cmdQuery);
|
|
21291
|
+
}, 0, () => {
|
|
21292
|
+
const server = getServerContext$1(this.config);
|
|
21293
|
+
return {
|
|
21294
|
+
query: cmdQuery.sql,
|
|
21295
|
+
values: cmdQuery.values,
|
|
21296
|
+
database: this.config.database || "",
|
|
21297
|
+
serverAddress: server.serverAddress,
|
|
21298
|
+
serverPort: server.serverPort
|
|
21299
|
+
};
|
|
21300
|
+
}, null, cmdQuery.onResult);
|
|
21301
|
+
else if (shouldTrace(queryChannel)) tracePromise(queryChannel, () => new Promise((resolve, reject) => {
|
|
21302
|
+
cmdQuery.once("error", reject);
|
|
21303
|
+
cmdQuery.once("end", () => resolve());
|
|
21304
|
+
this.addCommand(cmdQuery);
|
|
21305
|
+
}), () => {
|
|
21306
|
+
const server = getServerContext$1(this.config);
|
|
21307
|
+
return {
|
|
21308
|
+
query: cmdQuery.sql,
|
|
21309
|
+
values: cmdQuery.values,
|
|
21310
|
+
database: this.config.database || "",
|
|
21311
|
+
serverAddress: server.serverAddress,
|
|
21312
|
+
serverPort: server.serverPort
|
|
21313
|
+
};
|
|
21314
|
+
}).catch(() => {});
|
|
21315
|
+
else this.addCommand(cmdQuery);
|
|
21316
|
+
return cmdQuery;
|
|
21208
21317
|
}
|
|
21209
21318
|
pause() {
|
|
21210
21319
|
this._paused = true;
|
|
@@ -21227,7 +21336,7 @@ var require_connection$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib
|
|
|
21227
21336
|
let options = {};
|
|
21228
21337
|
if (typeof sql === "object") options = sql;
|
|
21229
21338
|
else options.sql = sql;
|
|
21230
|
-
const key$1 = BaseConnection$
|
|
21339
|
+
const key$1 = BaseConnection$3.statementKey(options);
|
|
21231
21340
|
const stmt = this._statements.get(key$1);
|
|
21232
21341
|
if (stmt) {
|
|
21233
21342
|
this._statements.delete(key$1);
|
|
@@ -21264,20 +21373,55 @@ var require_connection$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib
|
|
|
21264
21373
|
});
|
|
21265
21374
|
}
|
|
21266
21375
|
const executeCommand = new Commands.Execute(options, cb);
|
|
21267
|
-
const
|
|
21268
|
-
|
|
21269
|
-
|
|
21270
|
-
|
|
21376
|
+
const prepareAndExecute = (errorCb) => {
|
|
21377
|
+
const prepareCommand = new Commands.Prepare(options, (err, stmt) => {
|
|
21378
|
+
if (err) {
|
|
21379
|
+
executeCommand.start = function() {
|
|
21380
|
+
return null;
|
|
21381
|
+
};
|
|
21382
|
+
errorCb(err);
|
|
21383
|
+
executeCommand.emit("end");
|
|
21384
|
+
return;
|
|
21385
|
+
}
|
|
21386
|
+
executeCommand.statement = stmt;
|
|
21387
|
+
});
|
|
21388
|
+
this.addCommand(prepareCommand);
|
|
21389
|
+
this.addCommand(executeCommand);
|
|
21390
|
+
};
|
|
21391
|
+
if (executeCommand.onResult) {
|
|
21392
|
+
const origExecCb = executeCommand.onResult;
|
|
21393
|
+
traceCallback$1(executeChannel, (wrappedCb) => {
|
|
21394
|
+
executeCommand.onResult = wrappedCb;
|
|
21395
|
+
prepareAndExecute(wrappedCb);
|
|
21396
|
+
}, 0, () => {
|
|
21397
|
+
const server = getServerContext$1(this.config);
|
|
21398
|
+
return {
|
|
21399
|
+
query: options.sql,
|
|
21400
|
+
values: options.values,
|
|
21401
|
+
database: this.config.database || "",
|
|
21402
|
+
serverAddress: server.serverAddress,
|
|
21403
|
+
serverPort: server.serverPort
|
|
21271
21404
|
};
|
|
21272
|
-
|
|
21273
|
-
|
|
21274
|
-
|
|
21275
|
-
|
|
21276
|
-
}
|
|
21277
|
-
executeCommand.
|
|
21405
|
+
}, null, origExecCb);
|
|
21406
|
+
} else if (shouldTrace(executeChannel)) tracePromise(executeChannel, () => new Promise((resolve, reject) => {
|
|
21407
|
+
prepareAndExecute((err) => {
|
|
21408
|
+
executeCommand.emit("error", err);
|
|
21409
|
+
});
|
|
21410
|
+
executeCommand.once("error", reject);
|
|
21411
|
+
executeCommand.once("end", () => resolve());
|
|
21412
|
+
}), () => {
|
|
21413
|
+
const server = getServerContext$1(this.config);
|
|
21414
|
+
return {
|
|
21415
|
+
query: options.sql,
|
|
21416
|
+
values: options.values,
|
|
21417
|
+
database: this.config.database || "",
|
|
21418
|
+
serverAddress: server.serverAddress,
|
|
21419
|
+
serverPort: server.serverPort
|
|
21420
|
+
};
|
|
21421
|
+
}).catch(() => {});
|
|
21422
|
+
else prepareAndExecute((err) => {
|
|
21423
|
+
executeCommand.emit("error", err);
|
|
21278
21424
|
});
|
|
21279
|
-
this.addCommand(prepareCommand);
|
|
21280
|
-
this.addCommand(executeCommand);
|
|
21281
21425
|
return executeCommand;
|
|
21282
21426
|
}
|
|
21283
21427
|
changeUser(options, callback) {
|
|
@@ -21451,59 +21595,7 @@ var require_connection$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib
|
|
|
21451
21595
|
return `${typeof options.nestTables}/${options.nestTables}/${options.rowsAsArray}${options.sql}`;
|
|
21452
21596
|
}
|
|
21453
21597
|
};
|
|
21454
|
-
module.exports = BaseConnection$
|
|
21455
|
-
}) });
|
|
21456
|
-
|
|
21457
|
-
//#endregion
|
|
21458
|
-
//#region node_modules/mysql2/lib/base/pool_connection.js
|
|
21459
|
-
var require_pool_connection$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/base/pool_connection.js": ((exports, module) => {
|
|
21460
|
-
const BaseConnection$3 = require_connection$2();
|
|
21461
|
-
var BasePoolConnection$2 = class extends BaseConnection$3 {
|
|
21462
|
-
constructor(pool, options) {
|
|
21463
|
-
super(options);
|
|
21464
|
-
this._pool = pool;
|
|
21465
|
-
this.lastActiveTime = Date.now();
|
|
21466
|
-
this.once("end", () => {
|
|
21467
|
-
this._removeFromPool();
|
|
21468
|
-
});
|
|
21469
|
-
this.once("error", () => {
|
|
21470
|
-
this._removeFromPool();
|
|
21471
|
-
});
|
|
21472
|
-
}
|
|
21473
|
-
release() {
|
|
21474
|
-
if (!this._pool || this._pool._closed) return;
|
|
21475
|
-
this.lastActiveTime = Date.now();
|
|
21476
|
-
this._pool.releaseConnection(this);
|
|
21477
|
-
}
|
|
21478
|
-
[Symbol.dispose]() {
|
|
21479
|
-
this.release();
|
|
21480
|
-
}
|
|
21481
|
-
end(callback) {
|
|
21482
|
-
if (this.config.gracefulEnd) {
|
|
21483
|
-
this._removeFromPool();
|
|
21484
|
-
super.end(callback);
|
|
21485
|
-
return;
|
|
21486
|
-
}
|
|
21487
|
-
const err = /* @__PURE__ */ new Error("Calling conn.end() to release a pooled connection is deprecated. In next version calling conn.end() will be restored to default conn.end() behavior. Use conn.release() instead.");
|
|
21488
|
-
this.emit("warn", err);
|
|
21489
|
-
console.warn(err.message);
|
|
21490
|
-
this.release();
|
|
21491
|
-
if (typeof callback === "function") callback();
|
|
21492
|
-
}
|
|
21493
|
-
destroy() {
|
|
21494
|
-
this._removeFromPool();
|
|
21495
|
-
super.destroy();
|
|
21496
|
-
}
|
|
21497
|
-
_removeFromPool() {
|
|
21498
|
-
if (!this._pool || this._pool._closed) return;
|
|
21499
|
-
const pool = this._pool;
|
|
21500
|
-
this._pool = null;
|
|
21501
|
-
pool._removeConnection(this);
|
|
21502
|
-
}
|
|
21503
|
-
};
|
|
21504
|
-
BasePoolConnection$2.statementKey = BaseConnection$3.statementKey;
|
|
21505
|
-
module.exports = BasePoolConnection$2;
|
|
21506
|
-
BasePoolConnection$2.prototype._realEnd = BaseConnection$3.prototype.end;
|
|
21598
|
+
module.exports = BaseConnection$3;
|
|
21507
21599
|
}) });
|
|
21508
21600
|
|
|
21509
21601
|
//#endregion
|
|
@@ -21746,17 +21838,28 @@ var require_connection$1 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib
|
|
|
21746
21838
|
module.exports = PromiseConnection$2;
|
|
21747
21839
|
}) });
|
|
21748
21840
|
|
|
21841
|
+
//#endregion
|
|
21842
|
+
//#region node_modules/mysql2/lib/connection.js
|
|
21843
|
+
var require_connection = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/connection.js": ((exports, module) => {
|
|
21844
|
+
const BaseConnection$1 = require_connection$2();
|
|
21845
|
+
var Connection$3 = class extends BaseConnection$1 {
|
|
21846
|
+
promise(promiseImpl) {
|
|
21847
|
+
return new (require_connection$1())(this, promiseImpl);
|
|
21848
|
+
}
|
|
21849
|
+
};
|
|
21850
|
+
module.exports = Connection$3;
|
|
21851
|
+
}) });
|
|
21852
|
+
|
|
21749
21853
|
//#endregion
|
|
21750
21854
|
//#region node_modules/mysql2/lib/promise/pool_connection.js
|
|
21751
21855
|
var require_pool_connection$1 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/promise/pool_connection.js": ((exports, module) => {
|
|
21752
21856
|
const PromiseConnection$1 = require_connection$1();
|
|
21753
|
-
const BasePoolConnection$1 = require_pool_connection$2();
|
|
21754
21857
|
var PromisePoolConnection$3 = class extends PromiseConnection$1 {
|
|
21755
21858
|
constructor(connection, promiseImpl) {
|
|
21756
21859
|
super(connection, promiseImpl);
|
|
21757
21860
|
}
|
|
21758
21861
|
destroy() {
|
|
21759
|
-
return
|
|
21862
|
+
return this.connection.destroy();
|
|
21760
21863
|
}
|
|
21761
21864
|
async [Symbol.asyncDispose]() {
|
|
21762
21865
|
this.release();
|
|
@@ -21768,13 +21871,59 @@ var require_pool_connection$1 = /* @__PURE__ */ __commonJS({ "node_modules/mysql
|
|
|
21768
21871
|
//#endregion
|
|
21769
21872
|
//#region node_modules/mysql2/lib/pool_connection.js
|
|
21770
21873
|
var require_pool_connection = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/pool_connection.js": ((exports, module) => {
|
|
21771
|
-
const
|
|
21772
|
-
var PoolConnection$1 = class extends
|
|
21874
|
+
const Connection$2 = require_connection();
|
|
21875
|
+
var PoolConnection$1 = class extends Connection$2 {
|
|
21876
|
+
constructor(pool, options) {
|
|
21877
|
+
super(options);
|
|
21878
|
+
this._pool = pool;
|
|
21879
|
+
this._released = false;
|
|
21880
|
+
this.lastActiveTime = Date.now();
|
|
21881
|
+
this.once("end", () => {
|
|
21882
|
+
this._removeFromPool();
|
|
21883
|
+
});
|
|
21884
|
+
this.once("error", () => {
|
|
21885
|
+
this._removeFromPool();
|
|
21886
|
+
});
|
|
21887
|
+
}
|
|
21888
|
+
release() {
|
|
21889
|
+
if (this._released) return;
|
|
21890
|
+
if (!this._pool || this._pool._closed) return;
|
|
21891
|
+
this._released = true;
|
|
21892
|
+
this.lastActiveTime = Date.now();
|
|
21893
|
+
this._pool.releaseConnection(this);
|
|
21894
|
+
}
|
|
21895
|
+
[Symbol.dispose]() {
|
|
21896
|
+
this.release();
|
|
21897
|
+
}
|
|
21898
|
+
end(callback) {
|
|
21899
|
+
if (this.config.gracefulEnd) {
|
|
21900
|
+
this._removeFromPool();
|
|
21901
|
+
super.end(callback);
|
|
21902
|
+
return;
|
|
21903
|
+
}
|
|
21904
|
+
const err = /* @__PURE__ */ new Error("Calling conn.end() to release a pooled connection is deprecated. In next version calling conn.end() will be restored to default conn.end() behavior. Use conn.release() instead.");
|
|
21905
|
+
this.emit("warn", err);
|
|
21906
|
+
console.warn(err.message);
|
|
21907
|
+
this.release();
|
|
21908
|
+
if (typeof callback === "function") callback();
|
|
21909
|
+
}
|
|
21910
|
+
destroy() {
|
|
21911
|
+
this._removeFromPool();
|
|
21912
|
+
super.destroy();
|
|
21913
|
+
}
|
|
21914
|
+
_removeFromPool() {
|
|
21915
|
+
if (!this._pool || this._pool._closed) return;
|
|
21916
|
+
const pool = this._pool;
|
|
21917
|
+
this._pool = null;
|
|
21918
|
+
pool._removeConnection(this);
|
|
21919
|
+
}
|
|
21773
21920
|
promise(promiseImpl) {
|
|
21774
21921
|
return new (require_pool_connection$1())(this, promiseImpl);
|
|
21775
21922
|
}
|
|
21776
21923
|
};
|
|
21924
|
+
PoolConnection$1.statementKey = Connection$2.statementKey;
|
|
21777
21925
|
module.exports = PoolConnection$1;
|
|
21926
|
+
PoolConnection$1.prototype._realEnd = Connection$2.prototype.end;
|
|
21778
21927
|
}) });
|
|
21779
21928
|
|
|
21780
21929
|
//#endregion
|
|
@@ -21785,8 +21934,9 @@ var require_pool$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/base/
|
|
|
21785
21934
|
const EventEmitter$3 = __require("events").EventEmitter;
|
|
21786
21935
|
const PoolConnection = require_pool_connection();
|
|
21787
21936
|
const Queue = require_denque();
|
|
21788
|
-
const BaseConnection
|
|
21937
|
+
const BaseConnection = require_connection$2();
|
|
21789
21938
|
const Errors = require_errors();
|
|
21939
|
+
const { traceCallback, getServerContext, poolConnectChannel } = require_tracing();
|
|
21790
21940
|
function isReadOnlyError(err) {
|
|
21791
21941
|
if (!err || !err.errno) return false;
|
|
21792
21942
|
return err.errno === Errors.ER_OPTION_PREVENTS_STATEMENT || err.errno === Errors.ER_CANT_EXECUTE_IN_READ_ONLY_TRANSACTION || err.errno === Errors.ER_READ_ONLY_MODE;
|
|
@@ -21810,28 +21960,42 @@ var require_pool$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/base/
|
|
|
21810
21960
|
if (this.config.maxIdle < this.config.connectionLimit) this._removeIdleTimeoutConnections();
|
|
21811
21961
|
}
|
|
21812
21962
|
getConnection(cb) {
|
|
21813
|
-
|
|
21814
|
-
|
|
21815
|
-
|
|
21816
|
-
|
|
21817
|
-
|
|
21818
|
-
return process$2.nextTick(() => cb(null, connection));
|
|
21819
|
-
}
|
|
21820
|
-
if (this.config.connectionLimit === 0 || this._allConnections.length < this.config.connectionLimit) {
|
|
21821
|
-
connection = new PoolConnection(this, { config: this.config.connectionConfig });
|
|
21822
|
-
this._allConnections.push(connection);
|
|
21823
|
-
return connection.connect((err) => {
|
|
21824
|
-
if (this._closed) return cb(/* @__PURE__ */ new Error("Pool is closed."));
|
|
21825
|
-
if (err) return cb(err);
|
|
21826
|
-
this.emit("connection", connection);
|
|
21963
|
+
const _getConnection = (cb$1) => {
|
|
21964
|
+
if (this._closed) return process$2.nextTick(() => cb$1(/* @__PURE__ */ new Error("Pool is closed.")));
|
|
21965
|
+
let connection;
|
|
21966
|
+
if (this._freeConnections.length > 0) {
|
|
21967
|
+
connection = this._freeConnections.pop();
|
|
21827
21968
|
this.emit("acquire", connection);
|
|
21828
|
-
return
|
|
21829
|
-
|
|
21830
|
-
|
|
21831
|
-
|
|
21832
|
-
|
|
21833
|
-
|
|
21834
|
-
|
|
21969
|
+
return process$2.nextTick(() => {
|
|
21970
|
+
connection._released = false;
|
|
21971
|
+
cb$1(null, connection);
|
|
21972
|
+
});
|
|
21973
|
+
}
|
|
21974
|
+
if (this.config.connectionLimit === 0 || this._allConnections.length < this.config.connectionLimit) {
|
|
21975
|
+
connection = new PoolConnection(this, { config: this.config.connectionConfig });
|
|
21976
|
+
this._allConnections.push(connection);
|
|
21977
|
+
return connection.connect((err) => {
|
|
21978
|
+
if (this._closed) return cb$1(/* @__PURE__ */ new Error("Pool is closed."));
|
|
21979
|
+
if (err) return cb$1(err);
|
|
21980
|
+
this.emit("connection", connection);
|
|
21981
|
+
this.emit("acquire", connection);
|
|
21982
|
+
return cb$1(null, connection);
|
|
21983
|
+
});
|
|
21984
|
+
}
|
|
21985
|
+
if (!this.config.waitForConnections) return process$2.nextTick(() => cb$1(/* @__PURE__ */ new Error("No connections available.")));
|
|
21986
|
+
if (this.config.queueLimit && this._connectionQueue.length >= this.config.queueLimit) return cb$1(/* @__PURE__ */ new Error("Queue limit reached."));
|
|
21987
|
+
this.emit("enqueue");
|
|
21988
|
+
return this._connectionQueue.push(cb$1);
|
|
21989
|
+
};
|
|
21990
|
+
const config = this.config.connectionConfig;
|
|
21991
|
+
traceCallback(poolConnectChannel, _getConnection, 0, () => {
|
|
21992
|
+
const server = getServerContext(config);
|
|
21993
|
+
return {
|
|
21994
|
+
database: config.database || "",
|
|
21995
|
+
serverAddress: server.serverAddress,
|
|
21996
|
+
serverPort: server.serverPort
|
|
21997
|
+
};
|
|
21998
|
+
}, null, cb);
|
|
21835
21999
|
}
|
|
21836
22000
|
releaseConnection(connection) {
|
|
21837
22001
|
let cb;
|
|
@@ -21842,7 +22006,10 @@ var require_pool$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/base/
|
|
|
21842
22006
|
}
|
|
21843
22007
|
} else if (this._connectionQueue.length) {
|
|
21844
22008
|
cb = this._connectionQueue.shift();
|
|
21845
|
-
process$2.nextTick(
|
|
22009
|
+
process$2.nextTick(() => {
|
|
22010
|
+
connection._released = false;
|
|
22011
|
+
cb(null, connection);
|
|
22012
|
+
});
|
|
21846
22013
|
} else {
|
|
21847
22014
|
this._freeConnections.push(connection);
|
|
21848
22015
|
this.emit("release", connection);
|
|
@@ -21878,7 +22045,7 @@ var require_pool$2 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/base/
|
|
|
21878
22045
|
}
|
|
21879
22046
|
}
|
|
21880
22047
|
query(sql, values, cb) {
|
|
21881
|
-
const cmdQuery = BaseConnection
|
|
22048
|
+
const cmdQuery = BaseConnection.createQuery(sql, values, cb, this.config.connectionConfig);
|
|
21882
22049
|
if (typeof cmdQuery.namedPlaceholders === "undefined") cmdQuery.namedPlaceholders = this.config.connectionConfig.namedPlaceholders;
|
|
21883
22050
|
this.getConnection((err, conn) => {
|
|
21884
22051
|
if (err) {
|
|
@@ -22075,18 +22242,6 @@ var require_pool_config = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/
|
|
|
22075
22242
|
module.exports = PoolConfig$2;
|
|
22076
22243
|
}) });
|
|
22077
22244
|
|
|
22078
|
-
//#endregion
|
|
22079
|
-
//#region node_modules/mysql2/lib/connection.js
|
|
22080
|
-
var require_connection = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/connection.js": ((exports, module) => {
|
|
22081
|
-
const BaseConnection = require_connection$2();
|
|
22082
|
-
var Connection$2 = class extends BaseConnection {
|
|
22083
|
-
promise(promiseImpl) {
|
|
22084
|
-
return new (require_connection$1())(this, promiseImpl);
|
|
22085
|
-
}
|
|
22086
|
-
};
|
|
22087
|
-
module.exports = Connection$2;
|
|
22088
|
-
}) });
|
|
22089
|
-
|
|
22090
22245
|
//#endregion
|
|
22091
22246
|
//#region node_modules/mysql2/lib/pool_cluster.js
|
|
22092
22247
|
var require_pool_cluster$1 = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/lib/pool_cluster.js": ((exports, module) => {
|
|
@@ -22562,6 +22717,8 @@ var require_promise = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/promise.
|
|
|
22562
22717
|
exports.escapeId = SqlString.escapeId;
|
|
22563
22718
|
exports.format = SqlString.format;
|
|
22564
22719
|
exports.raw = SqlString.raw;
|
|
22720
|
+
exports.Connection = PromiseConnection;
|
|
22721
|
+
exports.PoolConnection = PromisePoolConnection;
|
|
22565
22722
|
exports.PromisePool = PromisePool;
|
|
22566
22723
|
exports.PromiseConnection = PromiseConnection;
|
|
22567
22724
|
exports.PromisePoolConnection = PromisePoolConnection;
|
|
@@ -22580,4 +22737,4 @@ var require_promise = /* @__PURE__ */ __commonJS({ "node_modules/mysql2/promise.
|
|
|
22580
22737
|
export default require_promise();
|
|
22581
22738
|
|
|
22582
22739
|
export { };
|
|
22583
|
-
//# sourceMappingURL=promise-
|
|
22740
|
+
//# sourceMappingURL=promise-BrZcjavs.mjs.map
|