@sentio/runtime 4.2.1 → 4.2.2-rc.1
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/dist/esm-CSGQo6hb.js +1773 -0
- package/dist/{esm-Ajeyb2yg.js.map → esm-CSGQo6hb.js.map} +1 -1
- package/dist/execAsync-DiFDE921.js +14 -0
- package/dist/{execAsync-Cu4Uyhzv.js.map → execAsync-DiFDE921.js.map} +1 -1
- package/dist/getMachineId-bsd-57c_YWfQ.js +30 -0
- package/dist/{getMachineId-bsd-DMCgGTrk.js.map → getMachineId-bsd-57c_YWfQ.js.map} +1 -1
- package/dist/getMachineId-darwin-dyf00K_U.js +27 -0
- package/dist/{getMachineId-darwin-Dy0upv7d.js.map → getMachineId-darwin-dyf00K_U.js.map} +1 -1
- package/dist/getMachineId-linux-p9niCx07.js +23 -0
- package/dist/{getMachineId-linux-1gt-JynE.js.map → getMachineId-linux-p9niCx07.js.map} +1 -1
- package/dist/getMachineId-unsupported-hKbFGxhH.js +18 -0
- package/dist/{getMachineId-unsupported-aqcKyF65.js.map → getMachineId-unsupported-hKbFGxhH.js.map} +1 -1
- package/dist/getMachineId-win-Bn6Q0xbV.js +29 -0
- package/dist/{getMachineId-win-BOJrF7mQ.js.map → getMachineId-win-Bn6Q0xbV.js.map} +1 -1
- package/dist/index.js +67 -1
- package/dist/index.js.map +1 -1
- package/dist/plugin-CteRSWq4.js +6925 -0
- package/dist/{plugin-BZBEYadJ.js.map → plugin-CteRSWq4.js.map} +1 -1
- package/dist/processor-runner.js +57665 -134
- package/dist/processor-runner.js.map +1 -1
- package/dist/service-v3-fWCR8MDp.js +12230 -0
- package/dist/{service-v3-3iFcydRx.js.map → service-v3-fWCR8MDp.js.map} +1 -1
- package/package.json +1 -1
- package/dist/esm-Ajeyb2yg.js +0 -2
- package/dist/execAsync-Cu4Uyhzv.js +0 -2
- package/dist/getMachineId-bsd-DMCgGTrk.js +0 -2
- package/dist/getMachineId-darwin-Dy0upv7d.js +0 -3
- package/dist/getMachineId-linux-1gt-JynE.js +0 -2
- package/dist/getMachineId-unsupported-aqcKyF65.js +0 -2
- package/dist/getMachineId-win-BOJrF7mQ.js +0 -2
- package/dist/plugin-BZBEYadJ.js +0 -3
- package/dist/service-v3-3iFcydRx.js +0 -11
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { d as __commonJSMin, m as __require } from "./esm-CSGQo6hb.js";
|
|
2
|
+
|
|
3
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/execAsync.js
|
|
4
|
+
var require_execAsync = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.execAsync = void 0;
|
|
7
|
+
const child_process = __require("child_process");
|
|
8
|
+
const util = __require("util");
|
|
9
|
+
exports.execAsync = util.promisify(child_process.exec);
|
|
10
|
+
}));
|
|
11
|
+
|
|
12
|
+
//#endregion
|
|
13
|
+
export { require_execAsync as t };
|
|
14
|
+
//# sourceMappingURL=execAsync-DiFDE921.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"execAsync-
|
|
1
|
+
{"version":3,"file":"execAsync-DiFDE921.js","names":[],"sources":["../../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/execAsync.js"],"sourcesContent":["\"use strict\";\n/*\n * Copyright The OpenTelemetry Authors\n * SPDX-License-Identifier: Apache-2.0\n */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.execAsync = void 0;\nconst child_process = require(\"child_process\");\nconst util = require(\"util\");\nexports.execAsync = util.promisify(child_process.exec);\n//# sourceMappingURL=execAsync.js.map"],"x_google_ignoreList":[0],"mappings":";;;;CAKA,OAAO,eAAe,SAAS,cAAc,EAAE,OAAO,KAAK,CAAC;CAC5D,QAAQ,YAAY,KAAK;CACzB,MAAM,0BAAwB,eAAe;CAC7C,MAAM,iBAAe,MAAM;CAC3B,QAAQ,YAAY,KAAK,UAAU,cAAc,IAAI"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { d as __commonJSMin, h as __toCommonJS, m as __require, n as init_esm, t as esm_exports } from "./esm-CSGQo6hb.js";
|
|
2
|
+
import { t as require_execAsync } from "./execAsync-DiFDE921.js";
|
|
3
|
+
|
|
4
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-bsd.js
|
|
5
|
+
var require_getMachineId_bsd = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.getMachineId = void 0;
|
|
8
|
+
const fs_1 = __require("fs");
|
|
9
|
+
const execAsync_1 = require_execAsync();
|
|
10
|
+
const api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
11
|
+
async function getMachineId() {
|
|
12
|
+
try {
|
|
13
|
+
return (await fs_1.promises.readFile("/etc/hostid", { encoding: "utf8" })).trim();
|
|
14
|
+
} catch (e) {
|
|
15
|
+
api_1.diag.debug(`error reading machine id: ${e}`);
|
|
16
|
+
}
|
|
17
|
+
try {
|
|
18
|
+
return (await (0, execAsync_1.execAsync)("kenv -q smbios.system.uuid")).stdout.trim();
|
|
19
|
+
} catch (e) {
|
|
20
|
+
api_1.diag.debug(`error reading machine id: ${e}`);
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
exports.getMachineId = getMachineId;
|
|
24
|
+
}));
|
|
25
|
+
|
|
26
|
+
//#endregion
|
|
27
|
+
export default require_getMachineId_bsd();
|
|
28
|
+
|
|
29
|
+
export { };
|
|
30
|
+
//# sourceMappingURL=getMachineId-bsd-57c_YWfQ.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getMachineId-bsd-
|
|
1
|
+
{"version":3,"file":"getMachineId-bsd-57c_YWfQ.js","names":[],"sources":["../../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-bsd.js"],"sourcesContent":["\"use strict\";\n/*\n * Copyright The OpenTelemetry Authors\n * SPDX-License-Identifier: Apache-2.0\n */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getMachineId = void 0;\nconst fs_1 = require(\"fs\");\nconst execAsync_1 = require(\"./execAsync\");\nconst api_1 = require(\"@opentelemetry/api\");\nasync function getMachineId() {\n try {\n const result = await fs_1.promises.readFile('/etc/hostid', { encoding: 'utf8' });\n return result.trim();\n }\n catch (e) {\n api_1.diag.debug(`error reading machine id: ${e}`);\n }\n try {\n const result = await (0, execAsync_1.execAsync)('kenv -q smbios.system.uuid');\n return result.stdout.trim();\n }\n catch (e) {\n api_1.diag.debug(`error reading machine id: ${e}`);\n }\n return undefined;\n}\nexports.getMachineId = getMachineId;\n//# sourceMappingURL=getMachineId-bsd.js.map"],"x_google_ignoreList":[0],"mappings":";;;;;CAKA,OAAO,eAAe,SAAS,cAAc,EAAE,OAAO,KAAK,CAAC;CAC5D,QAAQ,eAAe,KAAK;CAC5B,MAAM,iBAAe,IAAI;CACzB,MAAM;CACN,MAAM;CACN,eAAe,eAAe;EAC1B,IAAI;GAEA,QAAO,MADc,KAAK,SAAS,SAAS,eAAe,EAAE,UAAU,OAAO,CAAC,EAClE,CAAC,KAAK;EACvB,SACO,GAAG;GACN,MAAM,KAAK,MAAM,6BAA6B,GAAG;EACrD;EACA,IAAI;GAEA,QAAO,OADe,GAAG,YAAY,UAAS,CAAE,4BAA4B,EAC/D,CAAC,OAAO,KAAK;EAC9B,SACO,GAAG;GACN,MAAM,KAAK,MAAM,6BAA6B,GAAG;EACrD;CAEJ;CACA,QAAQ,eAAe"}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { d as __commonJSMin, h as __toCommonJS, n as init_esm, t as esm_exports } from "./esm-CSGQo6hb.js";
|
|
2
|
+
import { t as require_execAsync } from "./execAsync-DiFDE921.js";
|
|
3
|
+
|
|
4
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-darwin.js
|
|
5
|
+
var require_getMachineId_darwin = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.getMachineId = void 0;
|
|
8
|
+
const execAsync_1 = require_execAsync();
|
|
9
|
+
const api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
10
|
+
async function getMachineId() {
|
|
11
|
+
try {
|
|
12
|
+
const idLine = (await (0, execAsync_1.execAsync)("ioreg -rd1 -c \"IOPlatformExpertDevice\"")).stdout.split("\n").find((line) => line.includes("IOPlatformUUID"));
|
|
13
|
+
if (!idLine) return;
|
|
14
|
+
const parts = idLine.split("\" = \"");
|
|
15
|
+
if (parts.length === 2) return parts[1].slice(0, -1);
|
|
16
|
+
} catch (e) {
|
|
17
|
+
api_1.diag.debug(`error reading machine id: ${e}`);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
exports.getMachineId = getMachineId;
|
|
21
|
+
}));
|
|
22
|
+
|
|
23
|
+
//#endregion
|
|
24
|
+
export default require_getMachineId_darwin();
|
|
25
|
+
|
|
26
|
+
export { };
|
|
27
|
+
//# sourceMappingURL=getMachineId-darwin-dyf00K_U.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getMachineId-darwin-
|
|
1
|
+
{"version":3,"file":"getMachineId-darwin-dyf00K_U.js","names":[],"sources":["../../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-darwin.js"],"sourcesContent":["\"use strict\";\n/*\n * Copyright The OpenTelemetry Authors\n * SPDX-License-Identifier: Apache-2.0\n */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getMachineId = void 0;\nconst execAsync_1 = require(\"./execAsync\");\nconst api_1 = require(\"@opentelemetry/api\");\nasync function getMachineId() {\n try {\n const result = await (0, execAsync_1.execAsync)('ioreg -rd1 -c \"IOPlatformExpertDevice\"');\n const idLine = result.stdout\n .split('\\n')\n .find(line => line.includes('IOPlatformUUID'));\n if (!idLine) {\n return undefined;\n }\n const parts = idLine.split('\" = \"');\n if (parts.length === 2) {\n return parts[1].slice(0, -1);\n }\n }\n catch (e) {\n api_1.diag.debug(`error reading machine id: ${e}`);\n }\n return undefined;\n}\nexports.getMachineId = getMachineId;\n//# sourceMappingURL=getMachineId-darwin.js.map"],"x_google_ignoreList":[0],"mappings":";;;;;CAKA,OAAO,eAAe,SAAS,cAAc,EAAE,OAAO,KAAK,CAAC;CAC5D,QAAQ,eAAe,KAAK;CAC5B,MAAM;CACN,MAAM;CACN,eAAe,eAAe;EAC1B,IAAI;GAEA,MAAM,UAAS,OADO,GAAG,YAAY,UAAS,CAAE,0CAAwC,EACnE,CAAC,OACjB,MAAM,IAAI,CAAC,CACX,MAAK,SAAQ,KAAK,SAAS,gBAAgB,CAAC;GACjD,IAAI,CAAC,QACD;GAEJ,MAAM,QAAQ,OAAO,MAAM,SAAO;GAClC,IAAI,MAAM,WAAW,GACjB,OAAO,MAAM,EAAE,CAAC,MAAM,GAAG,EAAE;EAEnC,SACO,GAAG;GACN,MAAM,KAAK,MAAM,6BAA6B,GAAG;EACrD;CAEJ;CACA,QAAQ,eAAe"}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { d as __commonJSMin, h as __toCommonJS, m as __require, n as init_esm, t as esm_exports } from "./esm-CSGQo6hb.js";
|
|
2
|
+
|
|
3
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-linux.js
|
|
4
|
+
var require_getMachineId_linux = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getMachineId = void 0;
|
|
7
|
+
const fs_1 = __require("fs");
|
|
8
|
+
const api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
9
|
+
async function getMachineId() {
|
|
10
|
+
for (const path of ["/etc/machine-id", "/var/lib/dbus/machine-id"]) try {
|
|
11
|
+
return (await fs_1.promises.readFile(path, { encoding: "utf8" })).trim();
|
|
12
|
+
} catch (e) {
|
|
13
|
+
api_1.diag.debug(`error reading machine id: ${e}`);
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
exports.getMachineId = getMachineId;
|
|
17
|
+
}));
|
|
18
|
+
|
|
19
|
+
//#endregion
|
|
20
|
+
export default require_getMachineId_linux();
|
|
21
|
+
|
|
22
|
+
export { };
|
|
23
|
+
//# sourceMappingURL=getMachineId-linux-p9niCx07.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getMachineId-linux-
|
|
1
|
+
{"version":3,"file":"getMachineId-linux-p9niCx07.js","names":[],"sources":["../../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-linux.js"],"sourcesContent":["\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getMachineId = void 0;\n/*\n * Copyright The OpenTelemetry Authors\n * SPDX-License-Identifier: Apache-2.0\n */\nconst fs_1 = require(\"fs\");\nconst api_1 = require(\"@opentelemetry/api\");\nasync function getMachineId() {\n const paths = ['/etc/machine-id', '/var/lib/dbus/machine-id'];\n for (const path of paths) {\n try {\n const result = await fs_1.promises.readFile(path, { encoding: 'utf8' });\n return result.trim();\n }\n catch (e) {\n api_1.diag.debug(`error reading machine id: ${e}`);\n }\n }\n return undefined;\n}\nexports.getMachineId = getMachineId;\n//# sourceMappingURL=getMachineId-linux.js.map"],"x_google_ignoreList":[0],"mappings":";;;;CACA,OAAO,eAAe,SAAS,cAAc,EAAE,OAAO,KAAK,CAAC;CAC5D,QAAQ,eAAe,KAAK;CAK5B,MAAM,iBAAe,IAAI;CACzB,MAAM;CACN,eAAe,eAAe;EAE1B,KAAK,MAAM,QAAQ,CADJ,mBAAmB,0BACX,GACnB,IAAI;GAEA,QAAO,MADc,KAAK,SAAS,SAAS,MAAM,EAAE,UAAU,OAAO,CAAC,EACzD,CAAC,KAAK;EACvB,SACO,GAAG;GACN,MAAM,KAAK,MAAM,6BAA6B,GAAG;EACrD;CAGR;CACA,QAAQ,eAAe"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { d as __commonJSMin, h as __toCommonJS, n as init_esm, t as esm_exports } from "./esm-CSGQo6hb.js";
|
|
2
|
+
|
|
3
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-unsupported.js
|
|
4
|
+
var require_getMachineId_unsupported = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.getMachineId = void 0;
|
|
7
|
+
const api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
8
|
+
async function getMachineId() {
|
|
9
|
+
api_1.diag.debug("could not read machine-id: unsupported platform");
|
|
10
|
+
}
|
|
11
|
+
exports.getMachineId = getMachineId;
|
|
12
|
+
}));
|
|
13
|
+
|
|
14
|
+
//#endregion
|
|
15
|
+
export default require_getMachineId_unsupported();
|
|
16
|
+
|
|
17
|
+
export { };
|
|
18
|
+
//# sourceMappingURL=getMachineId-unsupported-hKbFGxhH.js.map
|
package/dist/{getMachineId-unsupported-aqcKyF65.js.map → getMachineId-unsupported-hKbFGxhH.js.map}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getMachineId-unsupported-
|
|
1
|
+
{"version":3,"file":"getMachineId-unsupported-hKbFGxhH.js","names":[],"sources":["../../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-unsupported.js"],"sourcesContent":["\"use strict\";\n/*\n * Copyright The OpenTelemetry Authors\n * SPDX-License-Identifier: Apache-2.0\n */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getMachineId = void 0;\nconst api_1 = require(\"@opentelemetry/api\");\nasync function getMachineId() {\n api_1.diag.debug('could not read machine-id: unsupported platform');\n return undefined;\n}\nexports.getMachineId = getMachineId;\n//# sourceMappingURL=getMachineId-unsupported.js.map"],"x_google_ignoreList":[0],"mappings":";;;;CAKA,OAAO,eAAe,SAAS,cAAc,EAAE,OAAO,KAAK,CAAC;CAC5D,QAAQ,eAAe,KAAK;CAC5B,MAAM;CACN,eAAe,eAAe;EAC1B,MAAM,KAAK,MAAM,iDAAiD;CAEtE;CACA,QAAQ,eAAe"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import { d as __commonJSMin, h as __toCommonJS, m as __require, n as init_esm, t as esm_exports } from "./esm-CSGQo6hb.js";
|
|
2
|
+
import { t as require_execAsync } from "./execAsync-DiFDE921.js";
|
|
3
|
+
|
|
4
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-win.js
|
|
5
|
+
var require_getMachineId_win = /* @__PURE__ */ __commonJSMin(((exports) => {
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.getMachineId = void 0;
|
|
8
|
+
const process = __require("process");
|
|
9
|
+
const execAsync_1 = require_execAsync();
|
|
10
|
+
const api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
11
|
+
async function getMachineId() {
|
|
12
|
+
const args = "QUERY HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Cryptography /v MachineGuid";
|
|
13
|
+
let command = "%windir%\\System32\\REG.exe";
|
|
14
|
+
if (process.arch === "ia32" && "PROCESSOR_ARCHITEW6432" in process.env) command = "%windir%\\sysnative\\cmd.exe /c " + command;
|
|
15
|
+
try {
|
|
16
|
+
const parts = (await (0, execAsync_1.execAsync)(`${command} ${args}`)).stdout.split("REG_SZ");
|
|
17
|
+
if (parts.length === 2) return parts[1].trim();
|
|
18
|
+
} catch (e) {
|
|
19
|
+
api_1.diag.debug(`error reading machine id: ${e}`);
|
|
20
|
+
}
|
|
21
|
+
}
|
|
22
|
+
exports.getMachineId = getMachineId;
|
|
23
|
+
}));
|
|
24
|
+
|
|
25
|
+
//#endregion
|
|
26
|
+
export default require_getMachineId_win();
|
|
27
|
+
|
|
28
|
+
export { };
|
|
29
|
+
//# sourceMappingURL=getMachineId-win-Bn6Q0xbV.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getMachineId-win-
|
|
1
|
+
{"version":3,"file":"getMachineId-win-Bn6Q0xbV.js","names":[],"sources":["../../../node_modules/.pnpm/@opentelemetry+resources@2.7.1_@opentelemetry+api@1.9.0/node_modules/@opentelemetry/resources/build/src/detectors/platform/node/machine-id/getMachineId-win.js"],"sourcesContent":["\"use strict\";\n/*\n * Copyright The OpenTelemetry Authors\n * SPDX-License-Identifier: Apache-2.0\n */\nObject.defineProperty(exports, \"__esModule\", { value: true });\nexports.getMachineId = void 0;\nconst process = require(\"process\");\nconst execAsync_1 = require(\"./execAsync\");\nconst api_1 = require(\"@opentelemetry/api\");\nasync function getMachineId() {\n const args = 'QUERY HKEY_LOCAL_MACHINE\\\\SOFTWARE\\\\Microsoft\\\\Cryptography /v MachineGuid';\n let command = '%windir%\\\\System32\\\\REG.exe';\n if (process.arch === 'ia32' && 'PROCESSOR_ARCHITEW6432' in process.env) {\n command = '%windir%\\\\sysnative\\\\cmd.exe /c ' + command;\n }\n try {\n const result = await (0, execAsync_1.execAsync)(`${command} ${args}`);\n const parts = result.stdout.split('REG_SZ');\n if (parts.length === 2) {\n return parts[1].trim();\n }\n }\n catch (e) {\n api_1.diag.debug(`error reading machine id: ${e}`);\n }\n return undefined;\n}\nexports.getMachineId = getMachineId;\n//# sourceMappingURL=getMachineId-win.js.map"],"x_google_ignoreList":[0],"mappings":";;;;;CAKA,OAAO,eAAe,SAAS,cAAc,EAAE,OAAO,KAAK,CAAC;CAC5D,QAAQ,eAAe,KAAK;CAC5B,MAAM,oBAAkB,SAAS;CACjC,MAAM;CACN,MAAM;CACN,eAAe,eAAe;EAC1B,MAAM,OAAO;EACb,IAAI,UAAU;EACd,IAAI,QAAQ,SAAS,UAAU,4BAA4B,QAAQ,KAC/D,UAAU,qCAAqC;EAEnD,IAAI;GAEA,MAAM,SAAQ,OADQ,GAAG,YAAY,UAAS,CAAE,GAAG,QAAQ,GAAG,MAAM,EAChD,CAAC,OAAO,MAAM,QAAQ;GAC1C,IAAI,MAAM,WAAW,GACjB,OAAO,MAAM,EAAE,CAAC,KAAK;EAE7B,SACO,GAAG;GACN,MAAM,KAAK,MAAM,6BAA6B,GAAG;EACrD;CAEJ;CACA,QAAQ,eAAe"}
|
package/dist/index.js
CHANGED
|
@@ -1,2 +1,68 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { n as PluginManager, t as Plugin } from "./plugin-CteRSWq4.js";
|
|
2
|
+
import { C as mergeProcessResults, E as recordRuntimeInfo, S as makeEthCallKey, T as parseSemver, a as StoreContext, b as errorString, c as metricsStorage, g as configureEndpoints, h as Endpoints, i as DataBindingContext, l as processMetrics, n as GLOBAL_CONFIG, o as timeoutError, r as AbstractStoreContext, s as dbMetrics, t as ProcessorServiceImplV3, u as providerMetrics, v as USER_PROCESSOR, w as mergeProcessResultsInPlace, x as locatePackageJson, y as compareSemver } from "./service-v3-fWCR8MDp.js";
|
|
3
|
+
|
|
4
|
+
//#region src/state.ts
|
|
5
|
+
var State = class State {
|
|
6
|
+
stateMap = /* @__PURE__ */ new Map();
|
|
7
|
+
static INSTANCE = new State();
|
|
8
|
+
static reset() {
|
|
9
|
+
State.INSTANCE = new State();
|
|
10
|
+
}
|
|
11
|
+
};
|
|
12
|
+
var StateStorage = class {
|
|
13
|
+
constructor() {}
|
|
14
|
+
key() {
|
|
15
|
+
return this.constructor.name;
|
|
16
|
+
}
|
|
17
|
+
getOrRegister() {
|
|
18
|
+
let metricState = State.INSTANCE.stateMap.get(this.key());
|
|
19
|
+
if (!metricState) {
|
|
20
|
+
metricState = this.initValue();
|
|
21
|
+
State.INSTANCE.stateMap.set(this.key(), metricState);
|
|
22
|
+
}
|
|
23
|
+
return metricState;
|
|
24
|
+
}
|
|
25
|
+
unregister() {
|
|
26
|
+
const value = State.INSTANCE.stateMap.get(this.key());
|
|
27
|
+
State.INSTANCE.stateMap.delete(this.key());
|
|
28
|
+
return value;
|
|
29
|
+
}
|
|
30
|
+
};
|
|
31
|
+
var MapStateStorage = class extends StateStorage {
|
|
32
|
+
initValue() {
|
|
33
|
+
return /* @__PURE__ */ new Map();
|
|
34
|
+
}
|
|
35
|
+
getValue(key) {
|
|
36
|
+
return this.getOrRegister().get(key);
|
|
37
|
+
}
|
|
38
|
+
getValues() {
|
|
39
|
+
const m = this.getOrRegister();
|
|
40
|
+
return Array.from(m.values());
|
|
41
|
+
}
|
|
42
|
+
getOrSetValue(key, value) {
|
|
43
|
+
const m = this.getOrRegister();
|
|
44
|
+
const oldValue = m.get(key);
|
|
45
|
+
if (oldValue) {
|
|
46
|
+
if (oldValue !== value) console.warn(key, "has been registered twice, use the previous one");
|
|
47
|
+
return oldValue;
|
|
48
|
+
}
|
|
49
|
+
m.set(key, value);
|
|
50
|
+
return value;
|
|
51
|
+
}
|
|
52
|
+
};
|
|
53
|
+
var ListStateStorage = class extends StateStorage {
|
|
54
|
+
initValue() {
|
|
55
|
+
return [];
|
|
56
|
+
}
|
|
57
|
+
getValues() {
|
|
58
|
+
return this.getOrRegister();
|
|
59
|
+
}
|
|
60
|
+
addValue(value) {
|
|
61
|
+
this.getOrRegister().push(value);
|
|
62
|
+
return value;
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
|
|
66
|
+
//#endregion
|
|
67
|
+
export { AbstractStoreContext, DataBindingContext, Endpoints, GLOBAL_CONFIG, ListStateStorage, MapStateStorage, Plugin, PluginManager, ProcessorServiceImplV3, State, StateStorage, StoreContext, USER_PROCESSOR, compareSemver, configureEndpoints, dbMetrics, errorString, locatePackageJson, makeEthCallKey, mergeProcessResults, mergeProcessResultsInPlace, metricsStorage, parseSemver, processMetrics, providerMetrics, recordRuntimeInfo, timeoutError };
|
|
2
68
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","names":[],"sources":["../src/state.ts"],"sourcesContent":["export class State {\n stateMap = new Map<string, any>()\n\n static INSTANCE = new State()\n\n static reset() {\n State.INSTANCE = new State()\n }\n}\n\nexport abstract class StateStorage<T> {\n // TODO learn how to define single instance for all subclasses\n\n protected constructor() {\n //\n }\n\n abstract initValue(): T\n\n key(): string {\n return this.constructor.name\n }\n\n getOrRegister(): T {\n let metricState: T = State.INSTANCE.stateMap.get(this.key())\n if (!metricState) {\n metricState = this.initValue()\n State.INSTANCE.stateMap.set(this.key(), metricState)\n }\n return metricState\n }\n\n unregister(): T {\n const value = State.INSTANCE.stateMap.get(this.key())\n State.INSTANCE.stateMap.delete(this.key())\n return value\n }\n}\n\nexport abstract class MapStateStorage<T> extends StateStorage<Map<string, T>> {\n initValue() {\n return new Map<string, T>()\n }\n\n getValue(key: string): T | undefined {\n const m = this.getOrRegister()\n return m.get(key)\n }\n\n getValues(): T[] {\n const m = this.getOrRegister()\n return Array.from(m.values())\n }\n\n getOrSetValue(key: string, value: T): T {\n const m = this.getOrRegister()\n const oldValue = m.get(key)\n if (oldValue) {\n if (oldValue !== value) {\n console.warn(key, 'has been registered twice, use the previous one')\n }\n return oldValue\n }\n m.set(key, value)\n return value\n }\n}\n\nexport abstract class ListStateStorage<T> extends StateStorage<T[]> {\n initValue() {\n return []\n }\n\n getValues(): T[] {\n return this.getOrRegister()\n }\n\n addValue(value: T): T {\n const m = this.getOrRegister()\n m.push(value)\n return value\n }\n}\n"],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","names":[],"sources":["../src/state.ts"],"sourcesContent":["export class State {\n stateMap = new Map<string, any>()\n\n static INSTANCE = new State()\n\n static reset() {\n State.INSTANCE = new State()\n }\n}\n\nexport abstract class StateStorage<T> {\n // TODO learn how to define single instance for all subclasses\n\n protected constructor() {\n //\n }\n\n abstract initValue(): T\n\n key(): string {\n return this.constructor.name\n }\n\n getOrRegister(): T {\n let metricState: T = State.INSTANCE.stateMap.get(this.key())\n if (!metricState) {\n metricState = this.initValue()\n State.INSTANCE.stateMap.set(this.key(), metricState)\n }\n return metricState\n }\n\n unregister(): T {\n const value = State.INSTANCE.stateMap.get(this.key())\n State.INSTANCE.stateMap.delete(this.key())\n return value\n }\n}\n\nexport abstract class MapStateStorage<T> extends StateStorage<Map<string, T>> {\n initValue() {\n return new Map<string, T>()\n }\n\n getValue(key: string): T | undefined {\n const m = this.getOrRegister()\n return m.get(key)\n }\n\n getValues(): T[] {\n const m = this.getOrRegister()\n return Array.from(m.values())\n }\n\n getOrSetValue(key: string, value: T): T {\n const m = this.getOrRegister()\n const oldValue = m.get(key)\n if (oldValue) {\n if (oldValue !== value) {\n console.warn(key, 'has been registered twice, use the previous one')\n }\n return oldValue\n }\n m.set(key, value)\n return value\n }\n}\n\nexport abstract class ListStateStorage<T> extends StateStorage<T[]> {\n initValue() {\n return []\n }\n\n getValues(): T[] {\n return this.getOrRegister()\n }\n\n addValue(value: T): T {\n const m = this.getOrRegister()\n m.push(value)\n return value\n }\n}\n"],"mappings":";;;;AAAA,IAAa,QAAb,MAAa,MAAM;CACjB,2BAAW,IAAI,IAAiB;CAEhC,OAAO,WAAW,IAAI,MAAM;CAE5B,OAAO,QAAQ;EACb,MAAM,WAAW,IAAI,MAAM;CAC7B;AACF;AAEA,IAAsB,eAAtB,MAAsC;CAGpC,AAAU,cAAc,CAExB;CAIA,MAAc;EACZ,OAAO,KAAK,YAAY;CAC1B;CAEA,gBAAmB;EACjB,IAAI,cAAiB,MAAM,SAAS,SAAS,IAAI,KAAK,IAAI,CAAC;EAC3D,IAAI,CAAC,aAAa;GAChB,cAAc,KAAK,UAAU;GAC7B,MAAM,SAAS,SAAS,IAAI,KAAK,IAAI,GAAG,WAAW;EACrD;EACA,OAAO;CACT;CAEA,aAAgB;EACd,MAAM,QAAQ,MAAM,SAAS,SAAS,IAAI,KAAK,IAAI,CAAC;EACpD,MAAM,SAAS,SAAS,OAAO,KAAK,IAAI,CAAC;EACzC,OAAO;CACT;AACF;AAEA,IAAsB,kBAAtB,cAAiD,aAA6B;CAC5E,YAAY;EACV,uBAAO,IAAI,IAAe;CAC5B;CAEA,SAAS,KAA4B;EAEnC,OADU,KAAK,cACR,CAAC,CAAC,IAAI,GAAG;CAClB;CAEA,YAAiB;EACf,MAAM,IAAI,KAAK,cAAc;EAC7B,OAAO,MAAM,KAAK,EAAE,OAAO,CAAC;CAC9B;CAEA,cAAc,KAAa,OAAa;EACtC,MAAM,IAAI,KAAK,cAAc;EAC7B,MAAM,WAAW,EAAE,IAAI,GAAG;EAC1B,IAAI,UAAU;GACZ,IAAI,aAAa,OACf,QAAQ,KAAK,KAAK,iDAAiD;GAErE,OAAO;EACT;EACA,EAAE,IAAI,KAAK,KAAK;EAChB,OAAO;CACT;AACF;AAEA,IAAsB,mBAAtB,cAAkD,aAAkB;CAClE,YAAY;EACV,OAAO,CAAC;CACV;CAEA,YAAiB;EACf,OAAO,KAAK,cAAc;CAC5B;CAEA,SAAS,OAAa;EAEpB,AADU,KAAK,cACf,CAAC,CAAC,KAAK,KAAK;EACZ,OAAO;CACT;AACF"}
|