@ms-cloudpack/telemetry 0.12.0 → 0.12.2
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/{chunk-5KML56LI.js → chunk-KMOWBBY7.js} +629 -564
- package/dist/{chunk-ADU6KBKW.js → chunk-QIPRD32X.js} +1 -1
- package/dist/{chunk-VFMIPDJG.js → chunk-UQTA3BJ6.js} +131 -106
- package/dist/{customerSDKStats-SUTAPSAC.js → customerSDKStats-JBHDMDFU.js} +8 -8
- package/dist/{getMachineId-bsd-55FFHI4W.js → getMachineId-bsd-A6VNC6N2.js} +2 -2
- package/dist/{getMachineId-darwin-EOCJYW3I.js → getMachineId-darwin-I4GEU4RG.js} +2 -2
- package/dist/{getMachineId-linux-UK6EGJSV.js → getMachineId-linux-YZITQZSS.js} +1 -1
- package/dist/{getMachineId-unsupported-SWVFDPWO.js → getMachineId-unsupported-WGKJT7JA.js} +1 -1
- package/dist/{getMachineId-win-NT6ZG6ZZ.js → getMachineId-win-IMYDUNBQ.js} +2 -2
- package/dist/{httpSender-RVSDBTC3.js → httpSender-LVAQHMJ5.js} +2 -2
- package/dist/index.js +109 -94
- package/dist/{statsbeatExporter-RVJLMKDF.js → statsbeatExporter-XU2SC6L6.js} +2 -2
- package/package.json +3 -3
|
@@ -13,7 +13,6 @@ import {
|
|
|
13
13
|
__esm,
|
|
14
14
|
__export,
|
|
15
15
|
__name,
|
|
16
|
-
__publicField,
|
|
17
16
|
__require,
|
|
18
17
|
__toCommonJS,
|
|
19
18
|
__toESM,
|
|
@@ -21,7 +20,7 @@ import {
|
|
|
21
20
|
diag,
|
|
22
21
|
esm_exports,
|
|
23
22
|
init_esm
|
|
24
|
-
} from "./chunk-
|
|
23
|
+
} from "./chunk-UQTA3BJ6.js";
|
|
25
24
|
|
|
26
25
|
// ../../node_modules/.store/ms-npm-2.1.3-81ff3cfac1/package/index.js
|
|
27
26
|
var require_package = __commonJS({
|
|
@@ -943,7 +942,10 @@ var require_dist = __commonJS({
|
|
|
943
942
|
var https_1 = __require("https");
|
|
944
943
|
__exportStar(require_helpers(), exports);
|
|
945
944
|
var INTERNAL = /* @__PURE__ */ Symbol("AgentBaseInternalState");
|
|
946
|
-
var
|
|
945
|
+
var Agent = class extends http2.Agent {
|
|
946
|
+
static {
|
|
947
|
+
__name(this, "Agent");
|
|
948
|
+
}
|
|
947
949
|
constructor(opts) {
|
|
948
950
|
super(opts);
|
|
949
951
|
this[INTERNAL] = {};
|
|
@@ -1054,8 +1056,6 @@ var require_dist = __commonJS({
|
|
|
1054
1056
|
}
|
|
1055
1057
|
}
|
|
1056
1058
|
};
|
|
1057
|
-
__name(_Agent, "Agent");
|
|
1058
|
-
var Agent = _Agent;
|
|
1059
1059
|
exports.Agent = Agent;
|
|
1060
1060
|
}
|
|
1061
1061
|
});
|
|
@@ -1215,12 +1215,15 @@ var require_dist2 = __commonJS({
|
|
|
1215
1215
|
}
|
|
1216
1216
|
return options;
|
|
1217
1217
|
}, "setServernameFromNonIpHost");
|
|
1218
|
-
var
|
|
1218
|
+
var HttpsProxyAgent2 = class extends agent_base_1.Agent {
|
|
1219
|
+
static {
|
|
1220
|
+
__name(this, "HttpsProxyAgent");
|
|
1221
|
+
}
|
|
1219
1222
|
constructor(proxy, opts) {
|
|
1220
1223
|
super(opts);
|
|
1221
1224
|
this.options = { path: void 0 };
|
|
1222
1225
|
this.proxy = typeof proxy === "string" ? new url_1.URL(proxy) : proxy;
|
|
1223
|
-
this.proxyHeaders =
|
|
1226
|
+
this.proxyHeaders = opts?.headers ?? {};
|
|
1224
1227
|
debug("Creating new HttpsProxyAgent instance: %o", this.proxy.href);
|
|
1225
1228
|
const host2 = (this.proxy.hostname || this.proxy.host).replace(/^\[|\]$/g, "");
|
|
1226
1229
|
const port = this.proxy.port ? parseInt(this.proxy.port, 10) : this.proxy.protocol === "https:" ? 443 : 80;
|
|
@@ -1294,8 +1297,6 @@ var require_dist2 = __commonJS({
|
|
|
1294
1297
|
return fakeSocket;
|
|
1295
1298
|
}
|
|
1296
1299
|
};
|
|
1297
|
-
__name(_HttpsProxyAgent, "HttpsProxyAgent");
|
|
1298
|
-
var HttpsProxyAgent2 = _HttpsProxyAgent;
|
|
1299
1300
|
HttpsProxyAgent2.protocols = ["http", "https"];
|
|
1300
1301
|
exports.HttpsProxyAgent = HttpsProxyAgent2;
|
|
1301
1302
|
function resume(socket) {
|
|
@@ -1359,11 +1360,14 @@ var require_dist3 = __commonJS({
|
|
|
1359
1360
|
var agent_base_1 = require_dist();
|
|
1360
1361
|
var url_1 = __require("url");
|
|
1361
1362
|
var debug = (0, debug_1.default)("http-proxy-agent");
|
|
1362
|
-
var
|
|
1363
|
+
var HttpProxyAgent2 = class extends agent_base_1.Agent {
|
|
1364
|
+
static {
|
|
1365
|
+
__name(this, "HttpProxyAgent");
|
|
1366
|
+
}
|
|
1363
1367
|
constructor(proxy, opts) {
|
|
1364
1368
|
super(opts);
|
|
1365
1369
|
this.proxy = typeof proxy === "string" ? new url_1.URL(proxy) : proxy;
|
|
1366
|
-
this.proxyHeaders =
|
|
1370
|
+
this.proxyHeaders = opts?.headers ?? {};
|
|
1367
1371
|
debug("Creating new HttpProxyAgent instance: %o", this.proxy.href);
|
|
1368
1372
|
const host2 = (this.proxy.hostname || this.proxy.host).replace(/^\[|\]$/g, "");
|
|
1369
1373
|
const port = this.proxy.port ? parseInt(this.proxy.port, 10) : this.proxy.protocol === "https:" ? 443 : 80;
|
|
@@ -1431,8 +1435,6 @@ var require_dist3 = __commonJS({
|
|
|
1431
1435
|
return socket;
|
|
1432
1436
|
}
|
|
1433
1437
|
};
|
|
1434
|
-
__name(_HttpProxyAgent, "HttpProxyAgent");
|
|
1435
|
-
var HttpProxyAgent2 = _HttpProxyAgent;
|
|
1436
1438
|
HttpProxyAgent2.protocols = ["http", "https"];
|
|
1437
1439
|
exports.HttpProxyAgent = HttpProxyAgent2;
|
|
1438
1440
|
function omit(obj, ...keys) {
|
|
@@ -1589,7 +1591,10 @@ var require_W3CBaggagePropagator = __commonJS({
|
|
|
1589
1591
|
var suppress_tracing_1 = require_suppress_tracing();
|
|
1590
1592
|
var constants_1 = require_constants();
|
|
1591
1593
|
var utils_1 = require_utils();
|
|
1592
|
-
var
|
|
1594
|
+
var W3CBaggagePropagator = class {
|
|
1595
|
+
static {
|
|
1596
|
+
__name(this, "W3CBaggagePropagator");
|
|
1597
|
+
}
|
|
1593
1598
|
inject(context4, carrier, setter) {
|
|
1594
1599
|
const baggage = api_1.propagation.getBaggage(context4);
|
|
1595
1600
|
if (!baggage || (0, suppress_tracing_1.isTracingSuppressed)(context4))
|
|
@@ -1631,8 +1636,6 @@ var require_W3CBaggagePropagator = __commonJS({
|
|
|
1631
1636
|
return [constants_1.BAGGAGE_HEADER];
|
|
1632
1637
|
}
|
|
1633
1638
|
};
|
|
1634
|
-
__name(_W3CBaggagePropagator, "W3CBaggagePropagator");
|
|
1635
|
-
var W3CBaggagePropagator = _W3CBaggagePropagator;
|
|
1636
1639
|
exports.W3CBaggagePropagator = W3CBaggagePropagator;
|
|
1637
1640
|
}
|
|
1638
1641
|
});
|
|
@@ -1643,7 +1646,10 @@ var require_anchored_clock = __commonJS({
|
|
|
1643
1646
|
"use strict";
|
|
1644
1647
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
1645
1648
|
exports.AnchoredClock = void 0;
|
|
1646
|
-
var
|
|
1649
|
+
var AnchoredClock = class {
|
|
1650
|
+
static {
|
|
1651
|
+
__name(this, "AnchoredClock");
|
|
1652
|
+
}
|
|
1647
1653
|
_monotonicClock;
|
|
1648
1654
|
_epochMillis;
|
|
1649
1655
|
_performanceMillis;
|
|
@@ -1667,8 +1673,6 @@ var require_anchored_clock = __commonJS({
|
|
|
1667
1673
|
return this._epochMillis + delta;
|
|
1668
1674
|
}
|
|
1669
1675
|
};
|
|
1670
|
-
__name(_AnchoredClock, "AnchoredClock");
|
|
1671
|
-
var AnchoredClock = _AnchoredClock;
|
|
1672
1676
|
exports.AnchoredClock = AnchoredClock;
|
|
1673
1677
|
}
|
|
1674
1678
|
});
|
|
@@ -1851,8 +1855,7 @@ var require_environment = __commonJS({
|
|
|
1851
1855
|
__name(getStringFromEnv, "getStringFromEnv");
|
|
1852
1856
|
exports.getStringFromEnv = getStringFromEnv;
|
|
1853
1857
|
function getBooleanFromEnv(key) {
|
|
1854
|
-
|
|
1855
|
-
const raw = (_a3 = process.env[key]) == null ? void 0 : _a3.trim().toLowerCase();
|
|
1858
|
+
const raw = process.env[key]?.trim().toLowerCase();
|
|
1856
1859
|
if (raw == null || raw === "") {
|
|
1857
1860
|
return false;
|
|
1858
1861
|
}
|
|
@@ -1868,8 +1871,7 @@ var require_environment = __commonJS({
|
|
|
1868
1871
|
__name(getBooleanFromEnv, "getBooleanFromEnv");
|
|
1869
1872
|
exports.getBooleanFromEnv = getBooleanFromEnv;
|
|
1870
1873
|
function getStringListFromEnv(key) {
|
|
1871
|
-
|
|
1872
|
-
return (_a3 = getStringFromEnv(key)) == null ? void 0 : _a3.split(",").map((v) => v.trim()).filter((s) => s !== "");
|
|
1874
|
+
return getStringFromEnv(key)?.split(",").map((v) => v.trim()).filter((s) => s !== "");
|
|
1873
1875
|
}
|
|
1874
1876
|
__name(getStringListFromEnv, "getStringListFromEnv");
|
|
1875
1877
|
exports.getStringListFromEnv = getStringListFromEnv;
|
|
@@ -4242,7 +4244,10 @@ var require_composite = __commonJS({
|
|
|
4242
4244
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4243
4245
|
exports.CompositePropagator = void 0;
|
|
4244
4246
|
var api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
4245
|
-
var
|
|
4247
|
+
var CompositePropagator = class {
|
|
4248
|
+
static {
|
|
4249
|
+
__name(this, "CompositePropagator");
|
|
4250
|
+
}
|
|
4246
4251
|
_propagators;
|
|
4247
4252
|
_fields;
|
|
4248
4253
|
/**
|
|
@@ -4295,8 +4300,6 @@ var require_composite = __commonJS({
|
|
|
4295
4300
|
return this._fields.slice();
|
|
4296
4301
|
}
|
|
4297
4302
|
};
|
|
4298
|
-
__name(_CompositePropagator, "CompositePropagator");
|
|
4299
|
-
var CompositePropagator = _CompositePropagator;
|
|
4300
4303
|
exports.CompositePropagator = CompositePropagator;
|
|
4301
4304
|
}
|
|
4302
4305
|
});
|
|
@@ -4337,7 +4340,10 @@ var require_TraceState = __commonJS({
|
|
|
4337
4340
|
var MAX_TRACE_STATE_LEN = 512;
|
|
4338
4341
|
var LIST_MEMBERS_SEPARATOR = ",";
|
|
4339
4342
|
var LIST_MEMBER_KEY_VALUE_SPLITTER = "=";
|
|
4340
|
-
var
|
|
4343
|
+
var TraceState = class _TraceState {
|
|
4344
|
+
static {
|
|
4345
|
+
__name(this, "TraceState");
|
|
4346
|
+
}
|
|
4341
4347
|
_internalState = /* @__PURE__ */ new Map();
|
|
4342
4348
|
constructor(rawTraceState) {
|
|
4343
4349
|
if (rawTraceState)
|
|
@@ -4394,8 +4400,6 @@ var require_TraceState = __commonJS({
|
|
|
4394
4400
|
return traceState;
|
|
4395
4401
|
}
|
|
4396
4402
|
};
|
|
4397
|
-
__name(_TraceState, "TraceState");
|
|
4398
|
-
var TraceState = _TraceState;
|
|
4399
4403
|
exports.TraceState = TraceState;
|
|
4400
4404
|
}
|
|
4401
4405
|
});
|
|
@@ -4431,7 +4435,10 @@ var require_W3CTraceContextPropagator = __commonJS({
|
|
|
4431
4435
|
}
|
|
4432
4436
|
__name(parseTraceParent, "parseTraceParent");
|
|
4433
4437
|
exports.parseTraceParent = parseTraceParent;
|
|
4434
|
-
var
|
|
4438
|
+
var W3CTraceContextPropagator = class {
|
|
4439
|
+
static {
|
|
4440
|
+
__name(this, "W3CTraceContextPropagator");
|
|
4441
|
+
}
|
|
4435
4442
|
inject(context4, carrier, setter) {
|
|
4436
4443
|
const spanContext = api_1.trace.getSpanContext(context4);
|
|
4437
4444
|
if (!spanContext || (0, suppress_tracing_1.isTracingSuppressed)(context4) || !(0, api_1.isSpanContextValid)(spanContext))
|
|
@@ -4464,8 +4471,6 @@ var require_W3CTraceContextPropagator = __commonJS({
|
|
|
4464
4471
|
return [exports.TRACE_PARENT_HEADER, exports.TRACE_STATE_HEADER];
|
|
4465
4472
|
}
|
|
4466
4473
|
};
|
|
4467
|
-
__name(_W3CTraceContextPropagator, "W3CTraceContextPropagator");
|
|
4468
|
-
var W3CTraceContextPropagator = _W3CTraceContextPropagator;
|
|
4469
4474
|
exports.W3CTraceContextPropagator = W3CTraceContextPropagator;
|
|
4470
4475
|
}
|
|
4471
4476
|
});
|
|
@@ -4697,14 +4702,15 @@ var require_timeout = __commonJS({
|
|
|
4697
4702
|
"use strict";
|
|
4698
4703
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4699
4704
|
exports.callWithTimeout = exports.TimeoutError = void 0;
|
|
4700
|
-
var
|
|
4705
|
+
var TimeoutError = class _TimeoutError extends Error {
|
|
4706
|
+
static {
|
|
4707
|
+
__name(this, "TimeoutError");
|
|
4708
|
+
}
|
|
4701
4709
|
constructor(message) {
|
|
4702
4710
|
super(message);
|
|
4703
4711
|
Object.setPrototypeOf(this, _TimeoutError.prototype);
|
|
4704
4712
|
}
|
|
4705
4713
|
};
|
|
4706
|
-
__name(_TimeoutError, "TimeoutError");
|
|
4707
|
-
var TimeoutError = _TimeoutError;
|
|
4708
4714
|
exports.TimeoutError = TimeoutError;
|
|
4709
4715
|
function callWithTimeout(promise, timeout) {
|
|
4710
4716
|
let timeoutHandle;
|
|
@@ -4763,7 +4769,10 @@ var require_promise = __commonJS({
|
|
|
4763
4769
|
"use strict";
|
|
4764
4770
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4765
4771
|
exports.Deferred = void 0;
|
|
4766
|
-
var
|
|
4772
|
+
var Deferred = class {
|
|
4773
|
+
static {
|
|
4774
|
+
__name(this, "Deferred");
|
|
4775
|
+
}
|
|
4767
4776
|
_promise;
|
|
4768
4777
|
_resolve;
|
|
4769
4778
|
_reject;
|
|
@@ -4783,8 +4792,6 @@ var require_promise = __commonJS({
|
|
|
4783
4792
|
this._reject(err);
|
|
4784
4793
|
}
|
|
4785
4794
|
};
|
|
4786
|
-
__name(_Deferred, "Deferred");
|
|
4787
|
-
var Deferred = _Deferred;
|
|
4788
4795
|
exports.Deferred = Deferred;
|
|
4789
4796
|
}
|
|
4790
4797
|
});
|
|
@@ -4796,7 +4803,10 @@ var require_callback = __commonJS({
|
|
|
4796
4803
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4797
4804
|
exports.BindOnceFuture = void 0;
|
|
4798
4805
|
var promise_1 = require_promise();
|
|
4799
|
-
var
|
|
4806
|
+
var BindOnceFuture = class {
|
|
4807
|
+
static {
|
|
4808
|
+
__name(this, "BindOnceFuture");
|
|
4809
|
+
}
|
|
4800
4810
|
_callback;
|
|
4801
4811
|
_that;
|
|
4802
4812
|
_isCalled = false;
|
|
@@ -4823,8 +4833,6 @@ var require_callback = __commonJS({
|
|
|
4823
4833
|
return this._deferred.promise;
|
|
4824
4834
|
}
|
|
4825
4835
|
};
|
|
4826
|
-
__name(_BindOnceFuture, "BindOnceFuture");
|
|
4827
|
-
var BindOnceFuture = _BindOnceFuture;
|
|
4828
4836
|
exports.BindOnceFuture = BindOnceFuture;
|
|
4829
4837
|
}
|
|
4830
4838
|
});
|
|
@@ -5127,14 +5135,15 @@ var require_utils2 = __commonJS({
|
|
|
5127
5135
|
}
|
|
5128
5136
|
__name(instrumentationScopeId, "instrumentationScopeId");
|
|
5129
5137
|
exports.instrumentationScopeId = instrumentationScopeId;
|
|
5130
|
-
var
|
|
5138
|
+
var TimeoutError = class _TimeoutError extends Error {
|
|
5139
|
+
static {
|
|
5140
|
+
__name(this, "TimeoutError");
|
|
5141
|
+
}
|
|
5131
5142
|
constructor(message) {
|
|
5132
5143
|
super(message);
|
|
5133
5144
|
Object.setPrototypeOf(this, _TimeoutError.prototype);
|
|
5134
5145
|
}
|
|
5135
5146
|
};
|
|
5136
|
-
__name(_TimeoutError, "TimeoutError");
|
|
5137
|
-
var TimeoutError = _TimeoutError;
|
|
5138
5147
|
exports.TimeoutError = TimeoutError;
|
|
5139
5148
|
function callWithTimeout(promise, timeout) {
|
|
5140
5149
|
let timeoutHandle;
|
|
@@ -5247,7 +5256,10 @@ var require_Drop = __commonJS({
|
|
|
5247
5256
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5248
5257
|
exports.DropAggregator = void 0;
|
|
5249
5258
|
var types_1 = require_types();
|
|
5250
|
-
var
|
|
5259
|
+
var DropAggregator = class {
|
|
5260
|
+
static {
|
|
5261
|
+
__name(this, "DropAggregator");
|
|
5262
|
+
}
|
|
5251
5263
|
kind = types_1.AggregatorKind.DROP;
|
|
5252
5264
|
createAccumulation() {
|
|
5253
5265
|
return void 0;
|
|
@@ -5262,8 +5274,6 @@ var require_Drop = __commonJS({
|
|
|
5262
5274
|
return void 0;
|
|
5263
5275
|
}
|
|
5264
5276
|
};
|
|
5265
|
-
__name(_DropAggregator, "DropAggregator");
|
|
5266
|
-
var DropAggregator = _DropAggregator;
|
|
5267
5277
|
exports.DropAggregator = DropAggregator;
|
|
5268
5278
|
}
|
|
5269
5279
|
});
|
|
@@ -5293,7 +5303,10 @@ var require_Histogram = __commonJS({
|
|
|
5293
5303
|
};
|
|
5294
5304
|
}
|
|
5295
5305
|
__name(createNewEmptyCheckpoint, "createNewEmptyCheckpoint");
|
|
5296
|
-
var
|
|
5306
|
+
var HistogramAccumulation = class {
|
|
5307
|
+
static {
|
|
5308
|
+
__name(this, "HistogramAccumulation");
|
|
5309
|
+
}
|
|
5297
5310
|
startTime;
|
|
5298
5311
|
_boundaries;
|
|
5299
5312
|
_recordMinMax;
|
|
@@ -5325,10 +5338,11 @@ var require_Histogram = __commonJS({
|
|
|
5325
5338
|
return this._current;
|
|
5326
5339
|
}
|
|
5327
5340
|
};
|
|
5328
|
-
__name(_HistogramAccumulation, "HistogramAccumulation");
|
|
5329
|
-
var HistogramAccumulation = _HistogramAccumulation;
|
|
5330
5341
|
exports.HistogramAccumulation = HistogramAccumulation;
|
|
5331
|
-
var
|
|
5342
|
+
var HistogramAggregator = class {
|
|
5343
|
+
static {
|
|
5344
|
+
__name(this, "HistogramAggregator");
|
|
5345
|
+
}
|
|
5332
5346
|
_boundaries;
|
|
5333
5347
|
_recordMinMax;
|
|
5334
5348
|
kind = types_1.AggregatorKind.HISTOGRAM;
|
|
@@ -5431,8 +5445,6 @@ var require_Histogram = __commonJS({
|
|
|
5431
5445
|
};
|
|
5432
5446
|
}
|
|
5433
5447
|
};
|
|
5434
|
-
__name(_HistogramAggregator, "HistogramAggregator");
|
|
5435
|
-
var HistogramAggregator = _HistogramAggregator;
|
|
5436
5448
|
exports.HistogramAggregator = HistogramAggregator;
|
|
5437
5449
|
}
|
|
5438
5450
|
});
|
|
@@ -5443,7 +5455,10 @@ var require_Buckets = __commonJS({
|
|
|
5443
5455
|
"use strict";
|
|
5444
5456
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5445
5457
|
exports.Buckets = void 0;
|
|
5446
|
-
var
|
|
5458
|
+
var Buckets = class _Buckets {
|
|
5459
|
+
static {
|
|
5460
|
+
__name(this, "Buckets");
|
|
5461
|
+
}
|
|
5447
5462
|
backing;
|
|
5448
5463
|
indexBase;
|
|
5449
5464
|
indexStart;
|
|
@@ -5617,10 +5632,11 @@ var require_Buckets = __commonJS({
|
|
|
5617
5632
|
this.incrementBucket(dest, this.backing.emptyBucket(src));
|
|
5618
5633
|
}
|
|
5619
5634
|
};
|
|
5620
|
-
__name(_Buckets, "Buckets");
|
|
5621
|
-
var Buckets = _Buckets;
|
|
5622
5635
|
exports.Buckets = Buckets;
|
|
5623
|
-
var
|
|
5636
|
+
var BucketsBacking = class _BucketsBacking {
|
|
5637
|
+
static {
|
|
5638
|
+
__name(this, "BucketsBacking");
|
|
5639
|
+
}
|
|
5624
5640
|
_counts;
|
|
5625
5641
|
constructor(_counts = [0]) {
|
|
5626
5642
|
this._counts = _counts;
|
|
@@ -5691,8 +5707,6 @@ var require_Buckets = __commonJS({
|
|
|
5691
5707
|
return new _BucketsBacking([...this._counts]);
|
|
5692
5708
|
}
|
|
5693
5709
|
};
|
|
5694
|
-
__name(_BucketsBacking, "BucketsBacking");
|
|
5695
|
-
var BucketsBacking = _BucketsBacking;
|
|
5696
5710
|
}
|
|
5697
5711
|
});
|
|
5698
5712
|
|
|
@@ -5766,10 +5780,11 @@ var require_types2 = __commonJS({
|
|
|
5766
5780
|
"use strict";
|
|
5767
5781
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
5768
5782
|
exports.MappingError = void 0;
|
|
5769
|
-
var
|
|
5783
|
+
var MappingError = class extends Error {
|
|
5784
|
+
static {
|
|
5785
|
+
__name(this, "MappingError");
|
|
5786
|
+
}
|
|
5770
5787
|
};
|
|
5771
|
-
__name(_MappingError, "MappingError");
|
|
5772
|
-
var MappingError = _MappingError;
|
|
5773
5788
|
exports.MappingError = MappingError;
|
|
5774
5789
|
}
|
|
5775
5790
|
});
|
|
@@ -5783,7 +5798,10 @@ var require_ExponentMapping = __commonJS({
|
|
|
5783
5798
|
var ieee754 = require_ieee754();
|
|
5784
5799
|
var util2 = require_util();
|
|
5785
5800
|
var types_1 = require_types2();
|
|
5786
|
-
var
|
|
5801
|
+
var ExponentMapping = class {
|
|
5802
|
+
static {
|
|
5803
|
+
__name(this, "ExponentMapping");
|
|
5804
|
+
}
|
|
5787
5805
|
_shift;
|
|
5788
5806
|
constructor(scale) {
|
|
5789
5807
|
this._shift = -scale;
|
|
@@ -5842,8 +5860,6 @@ var require_ExponentMapping = __commonJS({
|
|
|
5842
5860
|
return Math.floor(value * Math.pow(2, -shift));
|
|
5843
5861
|
}
|
|
5844
5862
|
};
|
|
5845
|
-
__name(_ExponentMapping, "ExponentMapping");
|
|
5846
|
-
var ExponentMapping = _ExponentMapping;
|
|
5847
5863
|
exports.ExponentMapping = ExponentMapping;
|
|
5848
5864
|
}
|
|
5849
5865
|
});
|
|
@@ -5857,7 +5873,10 @@ var require_LogarithmMapping = __commonJS({
|
|
|
5857
5873
|
var ieee754 = require_ieee754();
|
|
5858
5874
|
var util2 = require_util();
|
|
5859
5875
|
var types_1 = require_types2();
|
|
5860
|
-
var
|
|
5876
|
+
var LogarithmMapping = class {
|
|
5877
|
+
static {
|
|
5878
|
+
__name(this, "LogarithmMapping");
|
|
5879
|
+
}
|
|
5861
5880
|
_scale;
|
|
5862
5881
|
_scaleFactor;
|
|
5863
5882
|
_inverseFactor;
|
|
@@ -5925,8 +5944,6 @@ var require_LogarithmMapping = __commonJS({
|
|
|
5925
5944
|
return (ieee754.MAX_NORMAL_EXPONENT + 1 << this._scale) - 1;
|
|
5926
5945
|
}
|
|
5927
5946
|
};
|
|
5928
|
-
__name(_LogarithmMapping, "LogarithmMapping");
|
|
5929
|
-
var LogarithmMapping = _LogarithmMapping;
|
|
5930
5947
|
exports.LogarithmMapping = LogarithmMapping;
|
|
5931
5948
|
}
|
|
5932
5949
|
});
|
|
@@ -5971,7 +5988,10 @@ var require_ExponentialHistogram = __commonJS({
|
|
|
5971
5988
|
var Buckets_1 = require_Buckets();
|
|
5972
5989
|
var getMapping_1 = require_getMapping();
|
|
5973
5990
|
var util_1 = require_util();
|
|
5974
|
-
var
|
|
5991
|
+
var HighLow = class _HighLow {
|
|
5992
|
+
static {
|
|
5993
|
+
__name(this, "HighLow");
|
|
5994
|
+
}
|
|
5975
5995
|
low;
|
|
5976
5996
|
high;
|
|
5977
5997
|
static combine(h1, h2) {
|
|
@@ -5982,12 +6002,13 @@ var require_ExponentialHistogram = __commonJS({
|
|
|
5982
6002
|
this.high = high;
|
|
5983
6003
|
}
|
|
5984
6004
|
};
|
|
5985
|
-
__name(_HighLow, "HighLow");
|
|
5986
|
-
var HighLow = _HighLow;
|
|
5987
6005
|
var MAX_SCALE = 20;
|
|
5988
6006
|
var DEFAULT_MAX_SIZE = 160;
|
|
5989
6007
|
var MIN_MAX_SIZE = 2;
|
|
5990
|
-
var
|
|
6008
|
+
var ExponentialHistogramAccumulation = class _ExponentialHistogramAccumulation {
|
|
6009
|
+
static {
|
|
6010
|
+
__name(this, "ExponentialHistogramAccumulation");
|
|
6011
|
+
}
|
|
5991
6012
|
startTime;
|
|
5992
6013
|
_maxSize;
|
|
5993
6014
|
_recordMinMax;
|
|
@@ -6335,10 +6356,11 @@ var require_ExponentialHistogram = __commonJS({
|
|
|
6335
6356
|
ours.trim();
|
|
6336
6357
|
}
|
|
6337
6358
|
};
|
|
6338
|
-
__name(_ExponentialHistogramAccumulation, "ExponentialHistogramAccumulation");
|
|
6339
|
-
var ExponentialHistogramAccumulation = _ExponentialHistogramAccumulation;
|
|
6340
6359
|
exports.ExponentialHistogramAccumulation = ExponentialHistogramAccumulation;
|
|
6341
|
-
var
|
|
6360
|
+
var ExponentialHistogramAggregator = class {
|
|
6361
|
+
static {
|
|
6362
|
+
__name(this, "ExponentialHistogramAggregator");
|
|
6363
|
+
}
|
|
6342
6364
|
_maxSize;
|
|
6343
6365
|
_recordMinMax;
|
|
6344
6366
|
kind = types_1.AggregatorKind.EXPONENTIAL_HISTOGRAM;
|
|
@@ -6404,8 +6426,6 @@ var require_ExponentialHistogram = __commonJS({
|
|
|
6404
6426
|
};
|
|
6405
6427
|
}
|
|
6406
6428
|
};
|
|
6407
|
-
__name(_ExponentialHistogramAggregator, "ExponentialHistogramAggregator");
|
|
6408
|
-
var ExponentialHistogramAggregator = _ExponentialHistogramAggregator;
|
|
6409
6429
|
exports.ExponentialHistogramAggregator = ExponentialHistogramAggregator;
|
|
6410
6430
|
}
|
|
6411
6431
|
});
|
|
@@ -6419,7 +6439,10 @@ var require_LastValue = __commonJS({
|
|
|
6419
6439
|
var types_1 = require_types();
|
|
6420
6440
|
var core_1 = require_src2();
|
|
6421
6441
|
var MetricData_1 = require_MetricData();
|
|
6422
|
-
var
|
|
6442
|
+
var LastValueAccumulation = class {
|
|
6443
|
+
static {
|
|
6444
|
+
__name(this, "LastValueAccumulation");
|
|
6445
|
+
}
|
|
6423
6446
|
startTime;
|
|
6424
6447
|
_current;
|
|
6425
6448
|
sampleTime;
|
|
@@ -6439,10 +6462,11 @@ var require_LastValue = __commonJS({
|
|
|
6439
6462
|
return this._current;
|
|
6440
6463
|
}
|
|
6441
6464
|
};
|
|
6442
|
-
__name(_LastValueAccumulation, "LastValueAccumulation");
|
|
6443
|
-
var LastValueAccumulation = _LastValueAccumulation;
|
|
6444
6465
|
exports.LastValueAccumulation = LastValueAccumulation;
|
|
6445
|
-
var
|
|
6466
|
+
var LastValueAggregator = class {
|
|
6467
|
+
static {
|
|
6468
|
+
__name(this, "LastValueAggregator");
|
|
6469
|
+
}
|
|
6446
6470
|
kind = types_1.AggregatorKind.LAST_VALUE;
|
|
6447
6471
|
createAccumulation(startTime) {
|
|
6448
6472
|
return new LastValueAccumulation(startTime);
|
|
@@ -6482,8 +6506,6 @@ var require_LastValue = __commonJS({
|
|
|
6482
6506
|
};
|
|
6483
6507
|
}
|
|
6484
6508
|
};
|
|
6485
|
-
__name(_LastValueAggregator, "LastValueAggregator");
|
|
6486
|
-
var LastValueAggregator = _LastValueAggregator;
|
|
6487
6509
|
exports.LastValueAggregator = LastValueAggregator;
|
|
6488
6510
|
}
|
|
6489
6511
|
});
|
|
@@ -6496,7 +6518,10 @@ var require_Sum = __commonJS({
|
|
|
6496
6518
|
exports.SumAggregator = exports.SumAccumulation = void 0;
|
|
6497
6519
|
var types_1 = require_types();
|
|
6498
6520
|
var MetricData_1 = require_MetricData();
|
|
6499
|
-
var
|
|
6521
|
+
var SumAccumulation = class {
|
|
6522
|
+
static {
|
|
6523
|
+
__name(this, "SumAccumulation");
|
|
6524
|
+
}
|
|
6500
6525
|
startTime;
|
|
6501
6526
|
monotonic;
|
|
6502
6527
|
_current;
|
|
@@ -6520,10 +6545,11 @@ var require_Sum = __commonJS({
|
|
|
6520
6545
|
return this._current;
|
|
6521
6546
|
}
|
|
6522
6547
|
};
|
|
6523
|
-
__name(_SumAccumulation, "SumAccumulation");
|
|
6524
|
-
var SumAccumulation = _SumAccumulation;
|
|
6525
6548
|
exports.SumAccumulation = SumAccumulation;
|
|
6526
|
-
var
|
|
6549
|
+
var SumAggregator = class {
|
|
6550
|
+
static {
|
|
6551
|
+
__name(this, "SumAggregator");
|
|
6552
|
+
}
|
|
6527
6553
|
monotonic;
|
|
6528
6554
|
kind = types_1.AggregatorKind.SUM;
|
|
6529
6555
|
constructor(monotonic) {
|
|
@@ -6571,8 +6597,6 @@ var require_Sum = __commonJS({
|
|
|
6571
6597
|
};
|
|
6572
6598
|
}
|
|
6573
6599
|
};
|
|
6574
|
-
__name(_SumAggregator, "SumAggregator");
|
|
6575
|
-
var SumAggregator = _SumAggregator;
|
|
6576
6600
|
exports.SumAggregator = SumAggregator;
|
|
6577
6601
|
}
|
|
6578
6602
|
});
|
|
@@ -6627,16 +6651,22 @@ var require_Aggregation = __commonJS({
|
|
|
6627
6651
|
var api = (init_esm(), __toCommonJS(esm_exports));
|
|
6628
6652
|
var aggregator_1 = require_aggregator();
|
|
6629
6653
|
var MetricData_1 = require_MetricData();
|
|
6630
|
-
var
|
|
6654
|
+
var DropAggregation = class _DropAggregation {
|
|
6655
|
+
static {
|
|
6656
|
+
__name(this, "DropAggregation");
|
|
6657
|
+
}
|
|
6658
|
+
static DEFAULT_INSTANCE = new aggregator_1.DropAggregator();
|
|
6631
6659
|
createAggregator(_instrument) {
|
|
6632
6660
|
return _DropAggregation.DEFAULT_INSTANCE;
|
|
6633
6661
|
}
|
|
6634
6662
|
};
|
|
6635
|
-
__name(_DropAggregation, "DropAggregation");
|
|
6636
|
-
__publicField(_DropAggregation, "DEFAULT_INSTANCE", new aggregator_1.DropAggregator());
|
|
6637
|
-
var DropAggregation = _DropAggregation;
|
|
6638
6663
|
exports.DropAggregation = DropAggregation;
|
|
6639
|
-
var
|
|
6664
|
+
var SumAggregation = class _SumAggregation {
|
|
6665
|
+
static {
|
|
6666
|
+
__name(this, "SumAggregation");
|
|
6667
|
+
}
|
|
6668
|
+
static MONOTONIC_INSTANCE = new aggregator_1.SumAggregator(true);
|
|
6669
|
+
static NON_MONOTONIC_INSTANCE = new aggregator_1.SumAggregator(false);
|
|
6640
6670
|
createAggregator(instrument) {
|
|
6641
6671
|
switch (instrument.type) {
|
|
6642
6672
|
case MetricData_1.InstrumentType.COUNTER:
|
|
@@ -6650,30 +6680,31 @@ var require_Aggregation = __commonJS({
|
|
|
6650
6680
|
}
|
|
6651
6681
|
}
|
|
6652
6682
|
};
|
|
6653
|
-
__name(_SumAggregation, "SumAggregation");
|
|
6654
|
-
__publicField(_SumAggregation, "MONOTONIC_INSTANCE", new aggregator_1.SumAggregator(true));
|
|
6655
|
-
__publicField(_SumAggregation, "NON_MONOTONIC_INSTANCE", new aggregator_1.SumAggregator(false));
|
|
6656
|
-
var SumAggregation = _SumAggregation;
|
|
6657
6683
|
exports.SumAggregation = SumAggregation;
|
|
6658
|
-
var
|
|
6684
|
+
var LastValueAggregation = class _LastValueAggregation {
|
|
6685
|
+
static {
|
|
6686
|
+
__name(this, "LastValueAggregation");
|
|
6687
|
+
}
|
|
6688
|
+
static DEFAULT_INSTANCE = new aggregator_1.LastValueAggregator();
|
|
6659
6689
|
createAggregator(_instrument) {
|
|
6660
6690
|
return _LastValueAggregation.DEFAULT_INSTANCE;
|
|
6661
6691
|
}
|
|
6662
6692
|
};
|
|
6663
|
-
__name(_LastValueAggregation, "LastValueAggregation");
|
|
6664
|
-
__publicField(_LastValueAggregation, "DEFAULT_INSTANCE", new aggregator_1.LastValueAggregator());
|
|
6665
|
-
var LastValueAggregation = _LastValueAggregation;
|
|
6666
6693
|
exports.LastValueAggregation = LastValueAggregation;
|
|
6667
|
-
var
|
|
6694
|
+
var HistogramAggregation = class _HistogramAggregation {
|
|
6695
|
+
static {
|
|
6696
|
+
__name(this, "HistogramAggregation");
|
|
6697
|
+
}
|
|
6698
|
+
static DEFAULT_INSTANCE = new aggregator_1.HistogramAggregator([0, 5, 10, 25, 50, 75, 100, 250, 500, 750, 1e3, 2500, 5e3, 7500, 1e4], true);
|
|
6668
6699
|
createAggregator(_instrument) {
|
|
6669
6700
|
return _HistogramAggregation.DEFAULT_INSTANCE;
|
|
6670
6701
|
}
|
|
6671
6702
|
};
|
|
6672
|
-
__name(_HistogramAggregation, "HistogramAggregation");
|
|
6673
|
-
__publicField(_HistogramAggregation, "DEFAULT_INSTANCE", new aggregator_1.HistogramAggregator([0, 5, 10, 25, 50, 75, 100, 250, 500, 750, 1e3, 2500, 5e3, 7500, 1e4], true));
|
|
6674
|
-
var HistogramAggregation = _HistogramAggregation;
|
|
6675
6703
|
exports.HistogramAggregation = HistogramAggregation;
|
|
6676
|
-
var
|
|
6704
|
+
var ExplicitBucketHistogramAggregation = class {
|
|
6705
|
+
static {
|
|
6706
|
+
__name(this, "ExplicitBucketHistogramAggregation");
|
|
6707
|
+
}
|
|
6677
6708
|
_recordMinMax;
|
|
6678
6709
|
_boundaries;
|
|
6679
6710
|
/**
|
|
@@ -6698,10 +6729,11 @@ var require_Aggregation = __commonJS({
|
|
|
6698
6729
|
return new aggregator_1.HistogramAggregator(this._boundaries, this._recordMinMax);
|
|
6699
6730
|
}
|
|
6700
6731
|
};
|
|
6701
|
-
__name(_ExplicitBucketHistogramAggregation, "ExplicitBucketHistogramAggregation");
|
|
6702
|
-
var ExplicitBucketHistogramAggregation = _ExplicitBucketHistogramAggregation;
|
|
6703
6732
|
exports.ExplicitBucketHistogramAggregation = ExplicitBucketHistogramAggregation;
|
|
6704
|
-
var
|
|
6733
|
+
var ExponentialHistogramAggregation = class {
|
|
6734
|
+
static {
|
|
6735
|
+
__name(this, "ExponentialHistogramAggregation");
|
|
6736
|
+
}
|
|
6705
6737
|
_maxSize;
|
|
6706
6738
|
_recordMinMax;
|
|
6707
6739
|
constructor(_maxSize = 160, _recordMinMax = true) {
|
|
@@ -6712,10 +6744,11 @@ var require_Aggregation = __commonJS({
|
|
|
6712
6744
|
return new aggregator_1.ExponentialHistogramAggregator(this._maxSize, this._recordMinMax);
|
|
6713
6745
|
}
|
|
6714
6746
|
};
|
|
6715
|
-
__name(_ExponentialHistogramAggregation, "ExponentialHistogramAggregation");
|
|
6716
|
-
var ExponentialHistogramAggregation = _ExponentialHistogramAggregation;
|
|
6717
6747
|
exports.ExponentialHistogramAggregation = ExponentialHistogramAggregation;
|
|
6718
|
-
var
|
|
6748
|
+
var DefaultAggregation = class {
|
|
6749
|
+
static {
|
|
6750
|
+
__name(this, "DefaultAggregation");
|
|
6751
|
+
}
|
|
6719
6752
|
_resolve(instrument) {
|
|
6720
6753
|
switch (instrument.type) {
|
|
6721
6754
|
case MetricData_1.InstrumentType.COUNTER:
|
|
@@ -6742,8 +6775,6 @@ var require_Aggregation = __commonJS({
|
|
|
6742
6775
|
return this._resolve(instrument).createAggregator(instrument);
|
|
6743
6776
|
}
|
|
6744
6777
|
};
|
|
6745
|
-
__name(_DefaultAggregation, "DefaultAggregation");
|
|
6746
|
-
var DefaultAggregation = _DefaultAggregation;
|
|
6747
6778
|
exports.DefaultAggregation = DefaultAggregation;
|
|
6748
6779
|
exports.DROP_AGGREGATION = new DropAggregation();
|
|
6749
6780
|
exports.SUM_AGGREGATION = new SumAggregation();
|
|
@@ -6771,7 +6802,6 @@ var require_AggregationOption = __commonJS({
|
|
|
6771
6802
|
AggregationType2[AggregationType2["EXPONENTIAL_HISTOGRAM"] = 5] = "EXPONENTIAL_HISTOGRAM";
|
|
6772
6803
|
})(AggregationType = exports.AggregationType || (exports.AggregationType = {}));
|
|
6773
6804
|
function toAggregation(option) {
|
|
6774
|
-
var _a3, _b2, _c2, _d;
|
|
6775
6805
|
switch (option.type) {
|
|
6776
6806
|
case AggregationType.DEFAULT:
|
|
6777
6807
|
return Aggregation_1.DEFAULT_AGGREGATION;
|
|
@@ -6783,14 +6813,14 @@ var require_AggregationOption = __commonJS({
|
|
|
6783
6813
|
return Aggregation_1.LAST_VALUE_AGGREGATION;
|
|
6784
6814
|
case AggregationType.EXPONENTIAL_HISTOGRAM: {
|
|
6785
6815
|
const expOption = option;
|
|
6786
|
-
return new Aggregation_1.ExponentialHistogramAggregation(
|
|
6816
|
+
return new Aggregation_1.ExponentialHistogramAggregation(expOption.options?.maxSize, expOption.options?.recordMinMax);
|
|
6787
6817
|
}
|
|
6788
6818
|
case AggregationType.EXPLICIT_BUCKET_HISTOGRAM: {
|
|
6789
6819
|
const expOption = option;
|
|
6790
6820
|
if (expOption.options == null) {
|
|
6791
6821
|
return Aggregation_1.HISTOGRAM_AGGREGATION;
|
|
6792
6822
|
} else {
|
|
6793
|
-
return new Aggregation_1.ExplicitBucketHistogramAggregation(
|
|
6823
|
+
return new Aggregation_1.ExplicitBucketHistogramAggregation(expOption.options?.boundaries, expOption.options?.recordMinMax);
|
|
6794
6824
|
}
|
|
6795
6825
|
}
|
|
6796
6826
|
default:
|
|
@@ -6830,7 +6860,10 @@ var require_MetricReader = __commonJS({
|
|
|
6830
6860
|
var api = (init_esm(), __toCommonJS(esm_exports));
|
|
6831
6861
|
var utils_1 = require_utils2();
|
|
6832
6862
|
var AggregationSelector_1 = require_AggregationSelector();
|
|
6833
|
-
var
|
|
6863
|
+
var MetricReader = class {
|
|
6864
|
+
static {
|
|
6865
|
+
__name(this, "MetricReader");
|
|
6866
|
+
}
|
|
6834
6867
|
// Tracks the shutdown state.
|
|
6835
6868
|
// TODO: use BindOncePromise here once a new version of @opentelemetry/core is available.
|
|
6836
6869
|
_shutdown = false;
|
|
@@ -6842,10 +6875,10 @@ var require_MetricReader = __commonJS({
|
|
|
6842
6875
|
_aggregationSelector;
|
|
6843
6876
|
_cardinalitySelector;
|
|
6844
6877
|
constructor(options) {
|
|
6845
|
-
this._aggregationSelector =
|
|
6846
|
-
this._aggregationTemporalitySelector =
|
|
6847
|
-
this._metricProducers =
|
|
6848
|
-
this._cardinalitySelector = options
|
|
6878
|
+
this._aggregationSelector = options?.aggregationSelector ?? AggregationSelector_1.DEFAULT_AGGREGATION_SELECTOR;
|
|
6879
|
+
this._aggregationTemporalitySelector = options?.aggregationTemporalitySelector ?? AggregationSelector_1.DEFAULT_AGGREGATION_TEMPORALITY_SELECTOR;
|
|
6880
|
+
this._metricProducers = options?.metricProducers ?? [];
|
|
6881
|
+
this._cardinalitySelector = options?.cardinalitySelector;
|
|
6849
6882
|
}
|
|
6850
6883
|
setMetricProducer(metricProducer) {
|
|
6851
6884
|
if (this._sdkMetricProducer) {
|
|
@@ -6878,10 +6911,10 @@ var require_MetricReader = __commonJS({
|
|
|
6878
6911
|
}
|
|
6879
6912
|
const [sdkCollectionResults, ...additionalCollectionResults] = await Promise.all([
|
|
6880
6913
|
this._sdkMetricProducer.collect({
|
|
6881
|
-
timeoutMillis: options
|
|
6914
|
+
timeoutMillis: options?.timeoutMillis
|
|
6882
6915
|
}),
|
|
6883
6916
|
...this._metricProducers.map((producer) => producer.collect({
|
|
6884
|
-
timeoutMillis: options
|
|
6917
|
+
timeoutMillis: options?.timeoutMillis
|
|
6885
6918
|
}))
|
|
6886
6919
|
]);
|
|
6887
6920
|
const errors = sdkCollectionResults.errors.concat((0, utils_1.FlatMap)(additionalCollectionResults, (result) => result.errors));
|
|
@@ -6900,7 +6933,7 @@ var require_MetricReader = __commonJS({
|
|
|
6900
6933
|
api.diag.error("Cannot call shutdown twice.");
|
|
6901
6934
|
return;
|
|
6902
6935
|
}
|
|
6903
|
-
if (
|
|
6936
|
+
if (options?.timeoutMillis == null) {
|
|
6904
6937
|
await this.onShutdown();
|
|
6905
6938
|
} else {
|
|
6906
6939
|
await (0, utils_1.callWithTimeout)(this.onShutdown(), options.timeoutMillis);
|
|
@@ -6912,15 +6945,13 @@ var require_MetricReader = __commonJS({
|
|
|
6912
6945
|
api.diag.warn("Cannot forceFlush on already shutdown MetricReader.");
|
|
6913
6946
|
return;
|
|
6914
6947
|
}
|
|
6915
|
-
if (
|
|
6948
|
+
if (options?.timeoutMillis == null) {
|
|
6916
6949
|
await this.onForceFlush();
|
|
6917
6950
|
return;
|
|
6918
6951
|
}
|
|
6919
6952
|
await (0, utils_1.callWithTimeout)(this.onForceFlush(), options.timeoutMillis);
|
|
6920
6953
|
}
|
|
6921
6954
|
};
|
|
6922
|
-
__name(_MetricReader, "MetricReader");
|
|
6923
|
-
var MetricReader = _MetricReader;
|
|
6924
6955
|
exports.MetricReader = MetricReader;
|
|
6925
6956
|
}
|
|
6926
6957
|
});
|
|
@@ -6935,16 +6966,18 @@ var require_PeriodicExportingMetricReader = __commonJS({
|
|
|
6935
6966
|
var core_1 = require_src2();
|
|
6936
6967
|
var MetricReader_1 = require_MetricReader();
|
|
6937
6968
|
var utils_1 = require_utils2();
|
|
6938
|
-
var
|
|
6969
|
+
var PeriodicExportingMetricReader3 = class extends MetricReader_1.MetricReader {
|
|
6970
|
+
static {
|
|
6971
|
+
__name(this, "PeriodicExportingMetricReader");
|
|
6972
|
+
}
|
|
6939
6973
|
_interval;
|
|
6940
6974
|
_exporter;
|
|
6941
6975
|
_exportInterval;
|
|
6942
6976
|
_exportTimeout;
|
|
6943
6977
|
constructor(options) {
|
|
6944
|
-
var _a3, _b2;
|
|
6945
6978
|
super({
|
|
6946
|
-
aggregationSelector:
|
|
6947
|
-
aggregationTemporalitySelector:
|
|
6979
|
+
aggregationSelector: options.exporter.selectAggregation?.bind(options.exporter),
|
|
6980
|
+
aggregationTemporalitySelector: options.exporter.selectAggregationTemporality?.bind(options.exporter),
|
|
6948
6981
|
metricProducers: options.metricProducers
|
|
6949
6982
|
});
|
|
6950
6983
|
if (options.exportIntervalMillis !== void 0 && options.exportIntervalMillis <= 0) {
|
|
@@ -6972,7 +7005,6 @@ var require_PeriodicExportingMetricReader = __commonJS({
|
|
|
6972
7005
|
}
|
|
6973
7006
|
}
|
|
6974
7007
|
async _doRun() {
|
|
6975
|
-
var _a3, _b2;
|
|
6976
7008
|
const { resourceMetrics, errors } = await this.collect({
|
|
6977
7009
|
timeoutMillis: this._exportTimeout
|
|
6978
7010
|
});
|
|
@@ -6981,7 +7013,7 @@ var require_PeriodicExportingMetricReader = __commonJS({
|
|
|
6981
7013
|
}
|
|
6982
7014
|
if (resourceMetrics.resource.asyncAttributesPending) {
|
|
6983
7015
|
try {
|
|
6984
|
-
await
|
|
7016
|
+
await resourceMetrics.resource.waitForAsyncAttributes?.();
|
|
6985
7017
|
} catch (e) {
|
|
6986
7018
|
api.diag.debug("Error while resolving async portion of resource: ", e);
|
|
6987
7019
|
(0, core_1.globalErrorHandler)(e);
|
|
@@ -7013,8 +7045,6 @@ var require_PeriodicExportingMetricReader = __commonJS({
|
|
|
7013
7045
|
await this._exporter.shutdown();
|
|
7014
7046
|
}
|
|
7015
7047
|
};
|
|
7016
|
-
__name(_PeriodicExportingMetricReader, "PeriodicExportingMetricReader");
|
|
7017
|
-
var PeriodicExportingMetricReader3 = _PeriodicExportingMetricReader;
|
|
7018
7048
|
exports.PeriodicExportingMetricReader = PeriodicExportingMetricReader3;
|
|
7019
7049
|
}
|
|
7020
7050
|
});
|
|
@@ -7026,7 +7056,10 @@ var require_InMemoryMetricExporter = __commonJS({
|
|
|
7026
7056
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7027
7057
|
exports.InMemoryMetricExporter = void 0;
|
|
7028
7058
|
var core_1 = require_src2();
|
|
7029
|
-
var
|
|
7059
|
+
var InMemoryMetricExporter = class {
|
|
7060
|
+
static {
|
|
7061
|
+
__name(this, "InMemoryMetricExporter");
|
|
7062
|
+
}
|
|
7030
7063
|
_shutdown = false;
|
|
7031
7064
|
_aggregationTemporality;
|
|
7032
7065
|
_metrics = [];
|
|
@@ -7065,8 +7098,6 @@ var require_InMemoryMetricExporter = __commonJS({
|
|
|
7065
7098
|
return Promise.resolve();
|
|
7066
7099
|
}
|
|
7067
7100
|
};
|
|
7068
|
-
__name(_InMemoryMetricExporter, "InMemoryMetricExporter");
|
|
7069
|
-
var InMemoryMetricExporter = _InMemoryMetricExporter;
|
|
7070
7101
|
exports.InMemoryMetricExporter = InMemoryMetricExporter;
|
|
7071
7102
|
}
|
|
7072
7103
|
});
|
|
@@ -7079,11 +7110,14 @@ var require_ConsoleMetricExporter = __commonJS({
|
|
|
7079
7110
|
exports.ConsoleMetricExporter = void 0;
|
|
7080
7111
|
var core_1 = require_src2();
|
|
7081
7112
|
var AggregationSelector_1 = require_AggregationSelector();
|
|
7082
|
-
var
|
|
7113
|
+
var ConsoleMetricExporter = class _ConsoleMetricExporter {
|
|
7114
|
+
static {
|
|
7115
|
+
__name(this, "ConsoleMetricExporter");
|
|
7116
|
+
}
|
|
7083
7117
|
_shutdown = false;
|
|
7084
7118
|
_temporalitySelector;
|
|
7085
7119
|
constructor(options) {
|
|
7086
|
-
this._temporalitySelector =
|
|
7120
|
+
this._temporalitySelector = options?.temporalitySelector ?? AggregationSelector_1.DEFAULT_AGGREGATION_TEMPORALITY_SELECTOR;
|
|
7087
7121
|
}
|
|
7088
7122
|
export(metrics, resultCallback) {
|
|
7089
7123
|
if (this._shutdown) {
|
|
@@ -7115,8 +7149,6 @@ var require_ConsoleMetricExporter = __commonJS({
|
|
|
7115
7149
|
done({ code: core_1.ExportResultCode.SUCCESS });
|
|
7116
7150
|
}
|
|
7117
7151
|
};
|
|
7118
|
-
__name(_ConsoleMetricExporter, "ConsoleMetricExporter");
|
|
7119
|
-
var ConsoleMetricExporter = _ConsoleMetricExporter;
|
|
7120
7152
|
exports.ConsoleMetricExporter = ConsoleMetricExporter;
|
|
7121
7153
|
}
|
|
7122
7154
|
});
|
|
@@ -7190,7 +7222,10 @@ var require_ResourceImpl = __commonJS({
|
|
|
7190
7222
|
var semantic_conventions_1 = (init_esm2(), __toCommonJS(esm_exports3));
|
|
7191
7223
|
var platform_1 = require_platform2();
|
|
7192
7224
|
var utils_1 = require_utils3();
|
|
7193
|
-
var
|
|
7225
|
+
var ResourceImpl = class _ResourceImpl {
|
|
7226
|
+
static {
|
|
7227
|
+
__name(this, "ResourceImpl");
|
|
7228
|
+
}
|
|
7194
7229
|
_rawAttributes;
|
|
7195
7230
|
_asyncAttributesPending = false;
|
|
7196
7231
|
_schemaUrl;
|
|
@@ -7210,7 +7245,7 @@ var require_ResourceImpl = __commonJS({
|
|
|
7210
7245
|
return [k, v];
|
|
7211
7246
|
});
|
|
7212
7247
|
this._rawAttributes = guardedRawAttributes(this._rawAttributes);
|
|
7213
|
-
this._schemaUrl = validateSchemaUrl(options
|
|
7248
|
+
this._schemaUrl = validateSchemaUrl(options?.schemaUrl);
|
|
7214
7249
|
}
|
|
7215
7250
|
get asyncAttributesPending() {
|
|
7216
7251
|
return this._asyncAttributesPending;
|
|
@@ -7261,8 +7296,6 @@ var require_ResourceImpl = __commonJS({
|
|
|
7261
7296
|
return _ResourceImpl.FromAttributeList([...resource.getRawAttributes(), ...this.getRawAttributes()], mergedOptions);
|
|
7262
7297
|
}
|
|
7263
7298
|
};
|
|
7264
|
-
__name(_ResourceImpl, "ResourceImpl");
|
|
7265
|
-
var ResourceImpl = _ResourceImpl;
|
|
7266
7299
|
function resourceFromAttributes(attributes, options) {
|
|
7267
7300
|
return ResourceImpl.FromAttributeList(Object.entries(attributes), options);
|
|
7268
7301
|
}
|
|
@@ -7312,8 +7345,8 @@ var require_ResourceImpl = __commonJS({
|
|
|
7312
7345
|
}
|
|
7313
7346
|
__name(validateSchemaUrl, "validateSchemaUrl");
|
|
7314
7347
|
function mergeSchemaUrl(old, updating) {
|
|
7315
|
-
const oldSchemaUrl = old
|
|
7316
|
-
const updatingSchemaUrl = updating
|
|
7348
|
+
const oldSchemaUrl = old?.schemaUrl;
|
|
7349
|
+
const updatingSchemaUrl = updating?.schemaUrl;
|
|
7317
7350
|
const isOldEmpty = oldSchemaUrl === void 0 || oldSchemaUrl === "";
|
|
7318
7351
|
const isUpdatingEmpty = updatingSchemaUrl === void 0 || updatingSchemaUrl === "";
|
|
7319
7352
|
if (isOldEmpty) {
|
|
@@ -7366,7 +7399,10 @@ var require_EnvDetector = __commonJS({
|
|
|
7366
7399
|
var api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
7367
7400
|
var semantic_conventions_1 = (init_esm2(), __toCommonJS(esm_exports3));
|
|
7368
7401
|
var core_1 = require_src2();
|
|
7369
|
-
var
|
|
7402
|
+
var EnvDetector = class {
|
|
7403
|
+
static {
|
|
7404
|
+
__name(this, "EnvDetector");
|
|
7405
|
+
}
|
|
7370
7406
|
// Type, attribute keys, and attribute values should not exceed 256 characters.
|
|
7371
7407
|
_MAX_LENGTH = 255;
|
|
7372
7408
|
// OTEL_RESOURCE_ATTRIBUTES is a comma-separated list of attributes.
|
|
@@ -7467,8 +7503,6 @@ var require_EnvDetector = __commonJS({
|
|
|
7467
7503
|
return str.length > 0 && this._isValid(str);
|
|
7468
7504
|
}
|
|
7469
7505
|
};
|
|
7470
|
-
__name(_EnvDetector, "EnvDetector");
|
|
7471
|
-
var EnvDetector = _EnvDetector;
|
|
7472
7506
|
exports.envDetector = new EnvDetector();
|
|
7473
7507
|
}
|
|
7474
7508
|
});
|
|
@@ -7529,19 +7563,19 @@ var require_getMachineId = __commonJS({
|
|
|
7529
7563
|
if (!getMachineIdImpl) {
|
|
7530
7564
|
switch (process5.platform) {
|
|
7531
7565
|
case "darwin":
|
|
7532
|
-
getMachineIdImpl = (await import("./getMachineId-darwin-
|
|
7566
|
+
getMachineIdImpl = (await import("./getMachineId-darwin-I4GEU4RG.js")).getMachineId;
|
|
7533
7567
|
break;
|
|
7534
7568
|
case "linux":
|
|
7535
|
-
getMachineIdImpl = (await import("./getMachineId-linux-
|
|
7569
|
+
getMachineIdImpl = (await import("./getMachineId-linux-YZITQZSS.js")).getMachineId;
|
|
7536
7570
|
break;
|
|
7537
7571
|
case "freebsd":
|
|
7538
|
-
getMachineIdImpl = (await import("./getMachineId-bsd-
|
|
7572
|
+
getMachineIdImpl = (await import("./getMachineId-bsd-A6VNC6N2.js")).getMachineId;
|
|
7539
7573
|
break;
|
|
7540
7574
|
case "win32":
|
|
7541
|
-
getMachineIdImpl = (await import("./getMachineId-win-
|
|
7575
|
+
getMachineIdImpl = (await import("./getMachineId-win-IMYDUNBQ.js")).getMachineId;
|
|
7542
7576
|
break;
|
|
7543
7577
|
default:
|
|
7544
|
-
getMachineIdImpl = (await import("./getMachineId-unsupported-
|
|
7578
|
+
getMachineIdImpl = (await import("./getMachineId-unsupported-WGKJT7JA.js")).getMachineId;
|
|
7545
7579
|
break;
|
|
7546
7580
|
}
|
|
7547
7581
|
}
|
|
@@ -7595,7 +7629,10 @@ var require_HostDetector = __commonJS({
|
|
|
7595
7629
|
var os_1 = __require("os");
|
|
7596
7630
|
var getMachineId_1 = require_getMachineId();
|
|
7597
7631
|
var utils_1 = require_utils4();
|
|
7598
|
-
var
|
|
7632
|
+
var HostDetector = class {
|
|
7633
|
+
static {
|
|
7634
|
+
__name(this, "HostDetector");
|
|
7635
|
+
}
|
|
7599
7636
|
detect(_config) {
|
|
7600
7637
|
const attributes = {
|
|
7601
7638
|
[semconv_1.ATTR_HOST_NAME]: (0, os_1.hostname)(),
|
|
@@ -7605,8 +7642,6 @@ var require_HostDetector = __commonJS({
|
|
|
7605
7642
|
return { attributes };
|
|
7606
7643
|
}
|
|
7607
7644
|
};
|
|
7608
|
-
__name(_HostDetector, "HostDetector");
|
|
7609
|
-
var HostDetector = _HostDetector;
|
|
7610
7645
|
exports.hostDetector = new HostDetector();
|
|
7611
7646
|
}
|
|
7612
7647
|
});
|
|
@@ -7620,7 +7655,10 @@ var require_OSDetector = __commonJS({
|
|
|
7620
7655
|
var semconv_1 = require_semconv2();
|
|
7621
7656
|
var os_1 = __require("os");
|
|
7622
7657
|
var utils_1 = require_utils4();
|
|
7623
|
-
var
|
|
7658
|
+
var OSDetector = class {
|
|
7659
|
+
static {
|
|
7660
|
+
__name(this, "OSDetector");
|
|
7661
|
+
}
|
|
7624
7662
|
detect(_config) {
|
|
7625
7663
|
const attributes = {
|
|
7626
7664
|
[semconv_1.ATTR_OS_TYPE]: (0, utils_1.normalizeType)((0, os_1.platform)()),
|
|
@@ -7629,8 +7667,6 @@ var require_OSDetector = __commonJS({
|
|
|
7629
7667
|
return { attributes };
|
|
7630
7668
|
}
|
|
7631
7669
|
};
|
|
7632
|
-
__name(_OSDetector, "OSDetector");
|
|
7633
|
-
var OSDetector = _OSDetector;
|
|
7634
7670
|
exports.osDetector = new OSDetector();
|
|
7635
7671
|
}
|
|
7636
7672
|
});
|
|
@@ -7644,7 +7680,10 @@ var require_ProcessDetector = __commonJS({
|
|
|
7644
7680
|
var api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
7645
7681
|
var semconv_1 = require_semconv2();
|
|
7646
7682
|
var os4 = __require("os");
|
|
7647
|
-
var
|
|
7683
|
+
var ProcessDetector = class {
|
|
7684
|
+
static {
|
|
7685
|
+
__name(this, "ProcessDetector");
|
|
7686
|
+
}
|
|
7648
7687
|
detect(_config) {
|
|
7649
7688
|
const attributes = {
|
|
7650
7689
|
[semconv_1.ATTR_PROCESS_PID]: process.pid,
|
|
@@ -7671,8 +7710,6 @@ var require_ProcessDetector = __commonJS({
|
|
|
7671
7710
|
return { attributes };
|
|
7672
7711
|
}
|
|
7673
7712
|
};
|
|
7674
|
-
__name(_ProcessDetector, "ProcessDetector");
|
|
7675
|
-
var ProcessDetector = _ProcessDetector;
|
|
7676
7713
|
exports.processDetector = new ProcessDetector();
|
|
7677
7714
|
}
|
|
7678
7715
|
});
|
|
@@ -7685,7 +7722,10 @@ var require_ServiceInstanceIdDetector = __commonJS({
|
|
|
7685
7722
|
exports.serviceInstanceIdDetector = void 0;
|
|
7686
7723
|
var semconv_1 = require_semconv2();
|
|
7687
7724
|
var crypto_1 = __require("crypto");
|
|
7688
|
-
var
|
|
7725
|
+
var ServiceInstanceIdDetector = class {
|
|
7726
|
+
static {
|
|
7727
|
+
__name(this, "ServiceInstanceIdDetector");
|
|
7728
|
+
}
|
|
7689
7729
|
detect(_config) {
|
|
7690
7730
|
return {
|
|
7691
7731
|
attributes: {
|
|
@@ -7694,8 +7734,6 @@ var require_ServiceInstanceIdDetector = __commonJS({
|
|
|
7694
7734
|
};
|
|
7695
7735
|
}
|
|
7696
7736
|
};
|
|
7697
|
-
__name(_ServiceInstanceIdDetector, "ServiceInstanceIdDetector");
|
|
7698
|
-
var ServiceInstanceIdDetector = _ServiceInstanceIdDetector;
|
|
7699
7737
|
exports.serviceInstanceIdDetector = new ServiceInstanceIdDetector();
|
|
7700
7738
|
}
|
|
7701
7739
|
});
|
|
@@ -7753,15 +7791,16 @@ var require_NoopDetector = __commonJS({
|
|
|
7753
7791
|
"use strict";
|
|
7754
7792
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7755
7793
|
exports.noopDetector = exports.NoopDetector = void 0;
|
|
7756
|
-
var
|
|
7794
|
+
var NoopDetector = class {
|
|
7795
|
+
static {
|
|
7796
|
+
__name(this, "NoopDetector");
|
|
7797
|
+
}
|
|
7757
7798
|
detect() {
|
|
7758
7799
|
return {
|
|
7759
7800
|
attributes: {}
|
|
7760
7801
|
};
|
|
7761
7802
|
}
|
|
7762
7803
|
};
|
|
7763
|
-
__name(_NoopDetector, "NoopDetector");
|
|
7764
|
-
var NoopDetector = _NoopDetector;
|
|
7765
7804
|
exports.NoopDetector = NoopDetector;
|
|
7766
7805
|
exports.noopDetector = new NoopDetector();
|
|
7767
7806
|
}
|
|
@@ -7846,7 +7885,10 @@ var require_ViewRegistry = __commonJS({
|
|
|
7846
7885
|
"use strict";
|
|
7847
7886
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7848
7887
|
exports.ViewRegistry = void 0;
|
|
7849
|
-
var
|
|
7888
|
+
var ViewRegistry = class {
|
|
7889
|
+
static {
|
|
7890
|
+
__name(this, "ViewRegistry");
|
|
7891
|
+
}
|
|
7850
7892
|
_registeredViews = [];
|
|
7851
7893
|
addView(view) {
|
|
7852
7894
|
this._registeredViews.push(view);
|
|
@@ -7864,8 +7906,6 @@ var require_ViewRegistry = __commonJS({
|
|
|
7864
7906
|
return selector.getNameFilter().match(meter.name) && (meter.version === void 0 || selector.getVersionFilter().match(meter.version)) && (meter.schemaUrl === void 0 || selector.getSchemaUrlFilter().match(meter.schemaUrl));
|
|
7865
7907
|
}
|
|
7866
7908
|
};
|
|
7867
|
-
__name(_ViewRegistry, "ViewRegistry");
|
|
7868
|
-
var ViewRegistry = _ViewRegistry;
|
|
7869
7909
|
exports.ViewRegistry = ViewRegistry;
|
|
7870
7910
|
}
|
|
7871
7911
|
});
|
|
@@ -7885,10 +7925,10 @@ var require_InstrumentDescriptor = __commonJS({
|
|
|
7885
7925
|
return {
|
|
7886
7926
|
name,
|
|
7887
7927
|
type,
|
|
7888
|
-
description:
|
|
7889
|
-
unit:
|
|
7890
|
-
valueType:
|
|
7891
|
-
advice:
|
|
7928
|
+
description: options?.description ?? "",
|
|
7929
|
+
unit: options?.unit ?? "",
|
|
7930
|
+
valueType: options?.valueType ?? api_1.ValueType.DOUBLE,
|
|
7931
|
+
advice: options?.advice ?? {}
|
|
7892
7932
|
};
|
|
7893
7933
|
}
|
|
7894
7934
|
__name(createInstrumentDescriptor, "createInstrumentDescriptor");
|
|
@@ -7927,7 +7967,10 @@ var require_Instruments = __commonJS({
|
|
|
7927
7967
|
exports.isObservableInstrument = exports.ObservableUpDownCounterInstrument = exports.ObservableGaugeInstrument = exports.ObservableCounterInstrument = exports.ObservableInstrument = exports.HistogramInstrument = exports.GaugeInstrument = exports.CounterInstrument = exports.UpDownCounterInstrument = exports.SyncInstrument = void 0;
|
|
7928
7968
|
var api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
7929
7969
|
var core_1 = require_src2();
|
|
7930
|
-
var
|
|
7970
|
+
var SyncInstrument = class {
|
|
7971
|
+
static {
|
|
7972
|
+
__name(this, "SyncInstrument");
|
|
7973
|
+
}
|
|
7931
7974
|
_writableMetricStorage;
|
|
7932
7975
|
_descriptor;
|
|
7933
7976
|
constructor(_writableMetricStorage, _descriptor) {
|
|
@@ -7949,10 +7992,11 @@ var require_Instruments = __commonJS({
|
|
|
7949
7992
|
this._writableMetricStorage.record(value, attributes, context4, (0, core_1.millisToHrTime)(Date.now()));
|
|
7950
7993
|
}
|
|
7951
7994
|
};
|
|
7952
|
-
__name(_SyncInstrument, "SyncInstrument");
|
|
7953
|
-
var SyncInstrument = _SyncInstrument;
|
|
7954
7995
|
exports.SyncInstrument = SyncInstrument;
|
|
7955
|
-
var
|
|
7996
|
+
var UpDownCounterInstrument = class extends SyncInstrument {
|
|
7997
|
+
static {
|
|
7998
|
+
__name(this, "UpDownCounterInstrument");
|
|
7999
|
+
}
|
|
7956
8000
|
/**
|
|
7957
8001
|
* Increment value of counter by the input. Inputs may be negative.
|
|
7958
8002
|
*/
|
|
@@ -7960,10 +8004,11 @@ var require_Instruments = __commonJS({
|
|
|
7960
8004
|
this._record(value, attributes, ctx);
|
|
7961
8005
|
}
|
|
7962
8006
|
};
|
|
7963
|
-
__name(_UpDownCounterInstrument, "UpDownCounterInstrument");
|
|
7964
|
-
var UpDownCounterInstrument = _UpDownCounterInstrument;
|
|
7965
8007
|
exports.UpDownCounterInstrument = UpDownCounterInstrument;
|
|
7966
|
-
var
|
|
8008
|
+
var CounterInstrument = class extends SyncInstrument {
|
|
8009
|
+
static {
|
|
8010
|
+
__name(this, "CounterInstrument");
|
|
8011
|
+
}
|
|
7967
8012
|
/**
|
|
7968
8013
|
* Increment value of counter by the input. Inputs may not be negative.
|
|
7969
8014
|
*/
|
|
@@ -7975,10 +8020,11 @@ var require_Instruments = __commonJS({
|
|
|
7975
8020
|
this._record(value, attributes, ctx);
|
|
7976
8021
|
}
|
|
7977
8022
|
};
|
|
7978
|
-
__name(_CounterInstrument, "CounterInstrument");
|
|
7979
|
-
var CounterInstrument = _CounterInstrument;
|
|
7980
8023
|
exports.CounterInstrument = CounterInstrument;
|
|
7981
|
-
var
|
|
8024
|
+
var GaugeInstrument = class extends SyncInstrument {
|
|
8025
|
+
static {
|
|
8026
|
+
__name(this, "GaugeInstrument");
|
|
8027
|
+
}
|
|
7982
8028
|
/**
|
|
7983
8029
|
* Records a measurement.
|
|
7984
8030
|
*/
|
|
@@ -7986,10 +8032,11 @@ var require_Instruments = __commonJS({
|
|
|
7986
8032
|
this._record(value, attributes, ctx);
|
|
7987
8033
|
}
|
|
7988
8034
|
};
|
|
7989
|
-
__name(_GaugeInstrument, "GaugeInstrument");
|
|
7990
|
-
var GaugeInstrument = _GaugeInstrument;
|
|
7991
8035
|
exports.GaugeInstrument = GaugeInstrument;
|
|
7992
|
-
var
|
|
8036
|
+
var HistogramInstrument = class extends SyncInstrument {
|
|
8037
|
+
static {
|
|
8038
|
+
__name(this, "HistogramInstrument");
|
|
8039
|
+
}
|
|
7993
8040
|
/**
|
|
7994
8041
|
* Records a measurement. Value of the measurement must not be negative.
|
|
7995
8042
|
*/
|
|
@@ -8001,10 +8048,11 @@ var require_Instruments = __commonJS({
|
|
|
8001
8048
|
this._record(value, attributes, ctx);
|
|
8002
8049
|
}
|
|
8003
8050
|
};
|
|
8004
|
-
__name(_HistogramInstrument, "HistogramInstrument");
|
|
8005
|
-
var HistogramInstrument = _HistogramInstrument;
|
|
8006
8051
|
exports.HistogramInstrument = HistogramInstrument;
|
|
8007
|
-
var
|
|
8052
|
+
var ObservableInstrument = class {
|
|
8053
|
+
static {
|
|
8054
|
+
__name(this, "ObservableInstrument");
|
|
8055
|
+
}
|
|
8008
8056
|
_observableRegistry;
|
|
8009
8057
|
/** @internal */
|
|
8010
8058
|
_metricStorages;
|
|
@@ -8028,23 +8076,24 @@ var require_Instruments = __commonJS({
|
|
|
8028
8076
|
this._observableRegistry.removeCallback(callback, this);
|
|
8029
8077
|
}
|
|
8030
8078
|
};
|
|
8031
|
-
__name(_ObservableInstrument, "ObservableInstrument");
|
|
8032
|
-
var ObservableInstrument = _ObservableInstrument;
|
|
8033
8079
|
exports.ObservableInstrument = ObservableInstrument;
|
|
8034
|
-
var
|
|
8080
|
+
var ObservableCounterInstrument = class extends ObservableInstrument {
|
|
8081
|
+
static {
|
|
8082
|
+
__name(this, "ObservableCounterInstrument");
|
|
8083
|
+
}
|
|
8035
8084
|
};
|
|
8036
|
-
__name(_ObservableCounterInstrument, "ObservableCounterInstrument");
|
|
8037
|
-
var ObservableCounterInstrument = _ObservableCounterInstrument;
|
|
8038
8085
|
exports.ObservableCounterInstrument = ObservableCounterInstrument;
|
|
8039
|
-
var
|
|
8086
|
+
var ObservableGaugeInstrument = class extends ObservableInstrument {
|
|
8087
|
+
static {
|
|
8088
|
+
__name(this, "ObservableGaugeInstrument");
|
|
8089
|
+
}
|
|
8040
8090
|
};
|
|
8041
|
-
__name(_ObservableGaugeInstrument, "ObservableGaugeInstrument");
|
|
8042
|
-
var ObservableGaugeInstrument = _ObservableGaugeInstrument;
|
|
8043
8091
|
exports.ObservableGaugeInstrument = ObservableGaugeInstrument;
|
|
8044
|
-
var
|
|
8092
|
+
var ObservableUpDownCounterInstrument = class extends ObservableInstrument {
|
|
8093
|
+
static {
|
|
8094
|
+
__name(this, "ObservableUpDownCounterInstrument");
|
|
8095
|
+
}
|
|
8045
8096
|
};
|
|
8046
|
-
__name(_ObservableUpDownCounterInstrument, "ObservableUpDownCounterInstrument");
|
|
8047
|
-
var ObservableUpDownCounterInstrument = _ObservableUpDownCounterInstrument;
|
|
8048
8097
|
exports.ObservableUpDownCounterInstrument = ObservableUpDownCounterInstrument;
|
|
8049
8098
|
function isObservableInstrument(it) {
|
|
8050
8099
|
return it instanceof ObservableInstrument;
|
|
@@ -8063,7 +8112,10 @@ var require_Meter = __commonJS({
|
|
|
8063
8112
|
var InstrumentDescriptor_1 = require_InstrumentDescriptor();
|
|
8064
8113
|
var Instruments_1 = require_Instruments();
|
|
8065
8114
|
var MetricData_1 = require_MetricData();
|
|
8066
|
-
var
|
|
8115
|
+
var Meter = class {
|
|
8116
|
+
static {
|
|
8117
|
+
__name(this, "Meter");
|
|
8118
|
+
}
|
|
8067
8119
|
_meterSharedState;
|
|
8068
8120
|
constructor(_meterSharedState) {
|
|
8069
8121
|
this._meterSharedState = _meterSharedState;
|
|
@@ -8137,8 +8189,6 @@ var require_Meter = __commonJS({
|
|
|
8137
8189
|
this._meterSharedState.observableRegistry.removeBatchCallback(callback, observables);
|
|
8138
8190
|
}
|
|
8139
8191
|
};
|
|
8140
|
-
__name(_Meter, "Meter");
|
|
8141
|
-
var Meter = _Meter;
|
|
8142
8192
|
exports.Meter = Meter;
|
|
8143
8193
|
}
|
|
8144
8194
|
});
|
|
@@ -8150,7 +8200,10 @@ var require_MetricStorage = __commonJS({
|
|
|
8150
8200
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8151
8201
|
exports.MetricStorage = void 0;
|
|
8152
8202
|
var InstrumentDescriptor_1 = require_InstrumentDescriptor();
|
|
8153
|
-
var
|
|
8203
|
+
var MetricStorage = class {
|
|
8204
|
+
static {
|
|
8205
|
+
__name(this, "MetricStorage");
|
|
8206
|
+
}
|
|
8154
8207
|
_instrumentDescriptor;
|
|
8155
8208
|
constructor(_instrumentDescriptor) {
|
|
8156
8209
|
this._instrumentDescriptor = _instrumentDescriptor;
|
|
@@ -8167,8 +8220,6 @@ var require_MetricStorage = __commonJS({
|
|
|
8167
8220
|
});
|
|
8168
8221
|
}
|
|
8169
8222
|
};
|
|
8170
|
-
__name(_MetricStorage, "MetricStorage");
|
|
8171
|
-
var MetricStorage = _MetricStorage;
|
|
8172
8223
|
exports.MetricStorage = MetricStorage;
|
|
8173
8224
|
}
|
|
8174
8225
|
});
|
|
@@ -8180,7 +8231,10 @@ var require_HashMap = __commonJS({
|
|
|
8180
8231
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8181
8232
|
exports.AttributeHashMap = exports.HashMap = void 0;
|
|
8182
8233
|
var utils_1 = require_utils2();
|
|
8183
|
-
var
|
|
8234
|
+
var HashMap = class {
|
|
8235
|
+
static {
|
|
8236
|
+
__name(this, "HashMap");
|
|
8237
|
+
}
|
|
8184
8238
|
_hash;
|
|
8185
8239
|
_valueMap = /* @__PURE__ */ new Map();
|
|
8186
8240
|
_keyMap = /* @__PURE__ */ new Map();
|
|
@@ -8234,16 +8288,15 @@ var require_HashMap = __commonJS({
|
|
|
8234
8288
|
return this._valueMap.size;
|
|
8235
8289
|
}
|
|
8236
8290
|
};
|
|
8237
|
-
__name(_HashMap, "HashMap");
|
|
8238
|
-
var HashMap = _HashMap;
|
|
8239
8291
|
exports.HashMap = HashMap;
|
|
8240
|
-
var
|
|
8292
|
+
var AttributeHashMap = class extends HashMap {
|
|
8293
|
+
static {
|
|
8294
|
+
__name(this, "AttributeHashMap");
|
|
8295
|
+
}
|
|
8241
8296
|
constructor() {
|
|
8242
8297
|
super(utils_1.hashAttributes);
|
|
8243
8298
|
}
|
|
8244
8299
|
};
|
|
8245
|
-
__name(_AttributeHashMap, "AttributeHashMap");
|
|
8246
|
-
var AttributeHashMap = _AttributeHashMap;
|
|
8247
8300
|
exports.AttributeHashMap = AttributeHashMap;
|
|
8248
8301
|
}
|
|
8249
8302
|
});
|
|
@@ -8256,7 +8309,10 @@ var require_DeltaMetricProcessor = __commonJS({
|
|
|
8256
8309
|
exports.DeltaMetricProcessor = void 0;
|
|
8257
8310
|
var utils_1 = require_utils2();
|
|
8258
8311
|
var HashMap_1 = require_HashMap();
|
|
8259
|
-
var
|
|
8312
|
+
var DeltaMetricProcessor = class {
|
|
8313
|
+
static {
|
|
8314
|
+
__name(this, "DeltaMetricProcessor");
|
|
8315
|
+
}
|
|
8260
8316
|
_aggregator;
|
|
8261
8317
|
_activeCollectionStorage = new HashMap_1.AttributeHashMap();
|
|
8262
8318
|
// TODO: find a reasonable mean to clean the memo;
|
|
@@ -8275,18 +8331,18 @@ var require_DeltaMetricProcessor = __commonJS({
|
|
|
8275
8331
|
if (!accumulation) {
|
|
8276
8332
|
if (this._activeCollectionStorage.size >= this._cardinalityLimit) {
|
|
8277
8333
|
const overflowAccumulation = this._activeCollectionStorage.getOrDefault(this._overflowAttributes, () => this._aggregator.createAccumulation(collectionTime));
|
|
8278
|
-
overflowAccumulation
|
|
8334
|
+
overflowAccumulation?.record(value);
|
|
8279
8335
|
return;
|
|
8280
8336
|
}
|
|
8281
8337
|
accumulation = this._aggregator.createAccumulation(collectionTime);
|
|
8282
8338
|
this._activeCollectionStorage.set(attributes, accumulation);
|
|
8283
8339
|
}
|
|
8284
|
-
accumulation
|
|
8340
|
+
accumulation?.record(value);
|
|
8285
8341
|
}
|
|
8286
8342
|
batchCumulate(measurements, collectionTime) {
|
|
8287
8343
|
Array.from(measurements.entries()).forEach(([attributes, value, hashCode]) => {
|
|
8288
8344
|
const accumulation = this._aggregator.createAccumulation(collectionTime);
|
|
8289
|
-
accumulation
|
|
8345
|
+
accumulation?.record(value);
|
|
8290
8346
|
let delta = accumulation;
|
|
8291
8347
|
if (this._cumulativeMemoStorage.has(attributes, hashCode)) {
|
|
8292
8348
|
const previous = this._cumulativeMemoStorage.get(attributes, hashCode);
|
|
@@ -8319,8 +8375,6 @@ var require_DeltaMetricProcessor = __commonJS({
|
|
|
8319
8375
|
return unreportedDelta;
|
|
8320
8376
|
}
|
|
8321
8377
|
};
|
|
8322
|
-
__name(_DeltaMetricProcessor, "DeltaMetricProcessor");
|
|
8323
|
-
var DeltaMetricProcessor = _DeltaMetricProcessor;
|
|
8324
8378
|
exports.DeltaMetricProcessor = DeltaMetricProcessor;
|
|
8325
8379
|
}
|
|
8326
8380
|
});
|
|
@@ -8333,7 +8387,10 @@ var require_TemporalMetricProcessor = __commonJS({
|
|
|
8333
8387
|
exports.TemporalMetricProcessor = void 0;
|
|
8334
8388
|
var AggregationTemporality_1 = require_AggregationTemporality();
|
|
8335
8389
|
var HashMap_1 = require_HashMap();
|
|
8336
|
-
var
|
|
8390
|
+
var TemporalMetricProcessor = class _TemporalMetricProcessor {
|
|
8391
|
+
static {
|
|
8392
|
+
__name(this, "TemporalMetricProcessor");
|
|
8393
|
+
}
|
|
8337
8394
|
_aggregator;
|
|
8338
8395
|
_unreportedAccumulations = /* @__PURE__ */ new Map();
|
|
8339
8396
|
_reportHistory = /* @__PURE__ */ new Map();
|
|
@@ -8433,13 +8490,11 @@ var require_TemporalMetricProcessor = __commonJS({
|
|
|
8433
8490
|
static calibrateStartTime(last, current, lastCollectionTime) {
|
|
8434
8491
|
for (const [key, hash] of last.keys()) {
|
|
8435
8492
|
const currentAccumulation = current.get(key, hash);
|
|
8436
|
-
currentAccumulation
|
|
8493
|
+
currentAccumulation?.setStartTime(lastCollectionTime);
|
|
8437
8494
|
}
|
|
8438
8495
|
return current;
|
|
8439
8496
|
}
|
|
8440
8497
|
};
|
|
8441
|
-
__name(_TemporalMetricProcessor, "TemporalMetricProcessor");
|
|
8442
|
-
var TemporalMetricProcessor = _TemporalMetricProcessor;
|
|
8443
8498
|
exports.TemporalMetricProcessor = TemporalMetricProcessor;
|
|
8444
8499
|
function AttributesMapToAccumulationRecords(map) {
|
|
8445
8500
|
return Array.from(map.entries());
|
|
@@ -8458,7 +8513,10 @@ var require_AsyncMetricStorage = __commonJS({
|
|
|
8458
8513
|
var DeltaMetricProcessor_1 = require_DeltaMetricProcessor();
|
|
8459
8514
|
var TemporalMetricProcessor_1 = require_TemporalMetricProcessor();
|
|
8460
8515
|
var HashMap_1 = require_HashMap();
|
|
8461
|
-
var
|
|
8516
|
+
var AsyncMetricStorage = class extends MetricStorage_1.MetricStorage {
|
|
8517
|
+
static {
|
|
8518
|
+
__name(this, "AsyncMetricStorage");
|
|
8519
|
+
}
|
|
8462
8520
|
_attributesProcessor;
|
|
8463
8521
|
_aggregationCardinalityLimit;
|
|
8464
8522
|
_deltaMetricStorage;
|
|
@@ -8489,8 +8547,6 @@ var require_AsyncMetricStorage = __commonJS({
|
|
|
8489
8547
|
return this._temporalMetricStorage.buildMetrics(collector, this._instrumentDescriptor, accumulations, collectionTime);
|
|
8490
8548
|
}
|
|
8491
8549
|
};
|
|
8492
|
-
__name(_AsyncMetricStorage, "AsyncMetricStorage");
|
|
8493
|
-
var AsyncMetricStorage = _AsyncMetricStorage;
|
|
8494
8550
|
exports.AsyncMetricStorage = AsyncMetricStorage;
|
|
8495
8551
|
}
|
|
8496
8552
|
});
|
|
@@ -8586,7 +8642,10 @@ var require_MetricStorageRegistry = __commonJS({
|
|
|
8586
8642
|
var InstrumentDescriptor_1 = require_InstrumentDescriptor();
|
|
8587
8643
|
var api = (init_esm(), __toCommonJS(esm_exports));
|
|
8588
8644
|
var RegistrationConflicts_1 = require_RegistrationConflicts();
|
|
8589
|
-
var
|
|
8645
|
+
var MetricStorageRegistry = class _MetricStorageRegistry {
|
|
8646
|
+
static {
|
|
8647
|
+
__name(this, "MetricStorageRegistry");
|
|
8648
|
+
}
|
|
8590
8649
|
_sharedRegistry = /* @__PURE__ */ new Map();
|
|
8591
8650
|
_perCollectorRegistry = /* @__PURE__ */ new Map();
|
|
8592
8651
|
static create() {
|
|
@@ -8662,8 +8721,6 @@ var require_MetricStorageRegistry = __commonJS({
|
|
|
8662
8721
|
return compatibleStorage;
|
|
8663
8722
|
}
|
|
8664
8723
|
};
|
|
8665
|
-
__name(_MetricStorageRegistry, "MetricStorageRegistry");
|
|
8666
|
-
var MetricStorageRegistry = _MetricStorageRegistry;
|
|
8667
8724
|
exports.MetricStorageRegistry = MetricStorageRegistry;
|
|
8668
8725
|
}
|
|
8669
8726
|
});
|
|
@@ -8674,7 +8731,10 @@ var require_MultiWritableMetricStorage = __commonJS({
|
|
|
8674
8731
|
"use strict";
|
|
8675
8732
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8676
8733
|
exports.MultiMetricStorage = void 0;
|
|
8677
|
-
var
|
|
8734
|
+
var MultiMetricStorage = class {
|
|
8735
|
+
static {
|
|
8736
|
+
__name(this, "MultiMetricStorage");
|
|
8737
|
+
}
|
|
8678
8738
|
_backingStorages;
|
|
8679
8739
|
constructor(_backingStorages) {
|
|
8680
8740
|
this._backingStorages = _backingStorages;
|
|
@@ -8685,8 +8745,6 @@ var require_MultiWritableMetricStorage = __commonJS({
|
|
|
8685
8745
|
});
|
|
8686
8746
|
}
|
|
8687
8747
|
};
|
|
8688
|
-
__name(_MultiMetricStorage, "MultiMetricStorage");
|
|
8689
|
-
var MultiMetricStorage = _MultiMetricStorage;
|
|
8690
8748
|
exports.MultiMetricStorage = MultiMetricStorage;
|
|
8691
8749
|
}
|
|
8692
8750
|
});
|
|
@@ -8700,7 +8758,10 @@ var require_ObservableResult = __commonJS({
|
|
|
8700
8758
|
var api_1 = (init_esm(), __toCommonJS(esm_exports));
|
|
8701
8759
|
var HashMap_1 = require_HashMap();
|
|
8702
8760
|
var Instruments_1 = require_Instruments();
|
|
8703
|
-
var
|
|
8761
|
+
var ObservableResultImpl = class {
|
|
8762
|
+
static {
|
|
8763
|
+
__name(this, "ObservableResultImpl");
|
|
8764
|
+
}
|
|
8704
8765
|
_instrumentName;
|
|
8705
8766
|
_valueType;
|
|
8706
8767
|
/**
|
|
@@ -8729,10 +8790,11 @@ var require_ObservableResult = __commonJS({
|
|
|
8729
8790
|
this._buffer.set(attributes, value);
|
|
8730
8791
|
}
|
|
8731
8792
|
};
|
|
8732
|
-
__name(_ObservableResultImpl, "ObservableResultImpl");
|
|
8733
|
-
var ObservableResultImpl = _ObservableResultImpl;
|
|
8734
8793
|
exports.ObservableResultImpl = ObservableResultImpl;
|
|
8735
|
-
var
|
|
8794
|
+
var BatchObservableResultImpl = class {
|
|
8795
|
+
static {
|
|
8796
|
+
__name(this, "BatchObservableResultImpl");
|
|
8797
|
+
}
|
|
8736
8798
|
/**
|
|
8737
8799
|
* @internal
|
|
8738
8800
|
*/
|
|
@@ -8763,8 +8825,6 @@ var require_ObservableResult = __commonJS({
|
|
|
8763
8825
|
map.set(attributes, value);
|
|
8764
8826
|
}
|
|
8765
8827
|
};
|
|
8766
|
-
__name(_BatchObservableResultImpl, "BatchObservableResultImpl");
|
|
8767
|
-
var BatchObservableResultImpl = _BatchObservableResultImpl;
|
|
8768
8828
|
exports.BatchObservableResultImpl = BatchObservableResultImpl;
|
|
8769
8829
|
}
|
|
8770
8830
|
});
|
|
@@ -8779,7 +8839,10 @@ var require_ObservableRegistry = __commonJS({
|
|
|
8779
8839
|
var Instruments_1 = require_Instruments();
|
|
8780
8840
|
var ObservableResult_1 = require_ObservableResult();
|
|
8781
8841
|
var utils_1 = require_utils2();
|
|
8782
|
-
var
|
|
8842
|
+
var ObservableRegistry = class {
|
|
8843
|
+
static {
|
|
8844
|
+
__name(this, "ObservableRegistry");
|
|
8845
|
+
}
|
|
8783
8846
|
_callbacks = [];
|
|
8784
8847
|
_batchCallbacks = [];
|
|
8785
8848
|
addCallback(callback, instrument) {
|
|
@@ -8872,8 +8935,6 @@ var require_ObservableRegistry = __commonJS({
|
|
|
8872
8935
|
});
|
|
8873
8936
|
}
|
|
8874
8937
|
};
|
|
8875
|
-
__name(_ObservableRegistry, "ObservableRegistry");
|
|
8876
|
-
var ObservableRegistry = _ObservableRegistry;
|
|
8877
8938
|
exports.ObservableRegistry = ObservableRegistry;
|
|
8878
8939
|
}
|
|
8879
8940
|
});
|
|
@@ -8887,7 +8948,10 @@ var require_SyncMetricStorage = __commonJS({
|
|
|
8887
8948
|
var MetricStorage_1 = require_MetricStorage();
|
|
8888
8949
|
var DeltaMetricProcessor_1 = require_DeltaMetricProcessor();
|
|
8889
8950
|
var TemporalMetricProcessor_1 = require_TemporalMetricProcessor();
|
|
8890
|
-
var
|
|
8951
|
+
var SyncMetricStorage = class extends MetricStorage_1.MetricStorage {
|
|
8952
|
+
static {
|
|
8953
|
+
__name(this, "SyncMetricStorage");
|
|
8954
|
+
}
|
|
8891
8955
|
_attributesProcessor;
|
|
8892
8956
|
_aggregationCardinalityLimit;
|
|
8893
8957
|
_deltaMetricStorage;
|
|
@@ -8914,8 +8978,6 @@ var require_SyncMetricStorage = __commonJS({
|
|
|
8914
8978
|
return this._temporalMetricStorage.buildMetrics(collector, this._instrumentDescriptor, accumulations, collectionTime);
|
|
8915
8979
|
}
|
|
8916
8980
|
};
|
|
8917
|
-
__name(_SyncMetricStorage, "SyncMetricStorage");
|
|
8918
|
-
var SyncMetricStorage = _SyncMetricStorage;
|
|
8919
8981
|
exports.SyncMetricStorage = SyncMetricStorage;
|
|
8920
8982
|
}
|
|
8921
8983
|
});
|
|
@@ -8926,14 +8988,18 @@ var require_AttributesProcessor = __commonJS({
|
|
|
8926
8988
|
"use strict";
|
|
8927
8989
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8928
8990
|
exports.createDenyListAttributesProcessor = exports.createAllowListAttributesProcessor = exports.createMultiAttributesProcessor = exports.createNoopAttributesProcessor = void 0;
|
|
8929
|
-
var
|
|
8991
|
+
var NoopAttributesProcessor = class {
|
|
8992
|
+
static {
|
|
8993
|
+
__name(this, "NoopAttributesProcessor");
|
|
8994
|
+
}
|
|
8930
8995
|
process(incoming, _context) {
|
|
8931
8996
|
return incoming;
|
|
8932
8997
|
}
|
|
8933
8998
|
};
|
|
8934
|
-
|
|
8935
|
-
|
|
8936
|
-
|
|
8999
|
+
var MultiAttributesProcessor = class {
|
|
9000
|
+
static {
|
|
9001
|
+
__name(this, "MultiAttributesProcessor");
|
|
9002
|
+
}
|
|
8937
9003
|
_processors;
|
|
8938
9004
|
constructor(_processors) {
|
|
8939
9005
|
this._processors = _processors;
|
|
@@ -8946,9 +9012,10 @@ var require_AttributesProcessor = __commonJS({
|
|
|
8946
9012
|
return filteredAttributes;
|
|
8947
9013
|
}
|
|
8948
9014
|
};
|
|
8949
|
-
|
|
8950
|
-
|
|
8951
|
-
|
|
9015
|
+
var AllowListProcessor = class {
|
|
9016
|
+
static {
|
|
9017
|
+
__name(this, "AllowListProcessor");
|
|
9018
|
+
}
|
|
8952
9019
|
_allowedAttributeNames;
|
|
8953
9020
|
constructor(_allowedAttributeNames) {
|
|
8954
9021
|
this._allowedAttributeNames = _allowedAttributeNames;
|
|
@@ -8959,9 +9026,10 @@ var require_AttributesProcessor = __commonJS({
|
|
|
8959
9026
|
return filteredAttributes;
|
|
8960
9027
|
}
|
|
8961
9028
|
};
|
|
8962
|
-
|
|
8963
|
-
|
|
8964
|
-
|
|
9029
|
+
var DenyListProcessor = class {
|
|
9030
|
+
static {
|
|
9031
|
+
__name(this, "DenyListProcessor");
|
|
9032
|
+
}
|
|
8965
9033
|
_deniedAttributeNames;
|
|
8966
9034
|
constructor(_deniedAttributeNames) {
|
|
8967
9035
|
this._deniedAttributeNames = _deniedAttributeNames;
|
|
@@ -8972,8 +9040,6 @@ var require_AttributesProcessor = __commonJS({
|
|
|
8972
9040
|
return filteredAttributes;
|
|
8973
9041
|
}
|
|
8974
9042
|
};
|
|
8975
|
-
__name(_DenyListProcessor, "DenyListProcessor");
|
|
8976
|
-
var DenyListProcessor = _DenyListProcessor;
|
|
8977
9043
|
function createNoopAttributesProcessor() {
|
|
8978
9044
|
return NOOP;
|
|
8979
9045
|
}
|
|
@@ -9013,7 +9079,10 @@ var require_MeterSharedState = __commonJS({
|
|
|
9013
9079
|
var ObservableRegistry_1 = require_ObservableRegistry();
|
|
9014
9080
|
var SyncMetricStorage_1 = require_SyncMetricStorage();
|
|
9015
9081
|
var AttributesProcessor_1 = require_AttributesProcessor();
|
|
9016
|
-
var
|
|
9082
|
+
var MeterSharedState = class {
|
|
9083
|
+
static {
|
|
9084
|
+
__name(this, "MeterSharedState");
|
|
9085
|
+
}
|
|
9017
9086
|
_meterProviderSharedState;
|
|
9018
9087
|
_instrumentationScope;
|
|
9019
9088
|
metricStorageRegistry = new MetricStorageRegistry_1.MetricStorageRegistry();
|
|
@@ -9042,7 +9111,7 @@ var require_MeterSharedState = __commonJS({
|
|
|
9042
9111
|
* @returns the list of metric data collected.
|
|
9043
9112
|
*/
|
|
9044
9113
|
async collect(collector, collectionTime, options) {
|
|
9045
|
-
const errors = await this.observableRegistry.observe(collectionTime, options
|
|
9114
|
+
const errors = await this.observableRegistry.observe(collectionTime, options?.timeoutMillis);
|
|
9046
9115
|
const storages = this.metricStorageRegistry.getStorages(collector);
|
|
9047
9116
|
if (storages.length === 0) {
|
|
9048
9117
|
return null;
|
|
@@ -9092,8 +9161,6 @@ var require_MeterSharedState = __commonJS({
|
|
|
9092
9161
|
return storages;
|
|
9093
9162
|
}
|
|
9094
9163
|
};
|
|
9095
|
-
__name(_MeterSharedState, "MeterSharedState");
|
|
9096
|
-
var MeterSharedState = _MeterSharedState;
|
|
9097
9164
|
exports.MeterSharedState = MeterSharedState;
|
|
9098
9165
|
}
|
|
9099
9166
|
});
|
|
@@ -9108,7 +9175,10 @@ var require_MeterProviderSharedState = __commonJS({
|
|
|
9108
9175
|
var ViewRegistry_1 = require_ViewRegistry();
|
|
9109
9176
|
var MeterSharedState_1 = require_MeterSharedState();
|
|
9110
9177
|
var AggregationOption_1 = require_AggregationOption();
|
|
9111
|
-
var
|
|
9178
|
+
var MeterProviderSharedState = class {
|
|
9179
|
+
static {
|
|
9180
|
+
__name(this, "MeterProviderSharedState");
|
|
9181
|
+
}
|
|
9112
9182
|
resource;
|
|
9113
9183
|
viewRegistry = new ViewRegistry_1.ViewRegistry();
|
|
9114
9184
|
metricCollectors = [];
|
|
@@ -9136,8 +9206,6 @@ var require_MeterProviderSharedState = __commonJS({
|
|
|
9136
9206
|
return result;
|
|
9137
9207
|
}
|
|
9138
9208
|
};
|
|
9139
|
-
__name(_MeterProviderSharedState, "MeterProviderSharedState");
|
|
9140
|
-
var MeterProviderSharedState = _MeterProviderSharedState;
|
|
9141
9209
|
exports.MeterProviderSharedState = MeterProviderSharedState;
|
|
9142
9210
|
}
|
|
9143
9211
|
});
|
|
@@ -9149,7 +9217,10 @@ var require_MetricCollector = __commonJS({
|
|
|
9149
9217
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9150
9218
|
exports.MetricCollector = void 0;
|
|
9151
9219
|
var core_1 = require_src2();
|
|
9152
|
-
var
|
|
9220
|
+
var MetricCollector = class {
|
|
9221
|
+
static {
|
|
9222
|
+
__name(this, "MetricCollector");
|
|
9223
|
+
}
|
|
9153
9224
|
_sharedState;
|
|
9154
9225
|
_metricReader;
|
|
9155
9226
|
constructor(_sharedState, _metricReader) {
|
|
@@ -9162,10 +9233,10 @@ var require_MetricCollector = __commonJS({
|
|
|
9162
9233
|
const errors = [];
|
|
9163
9234
|
const meterCollectionPromises = Array.from(this._sharedState.meterSharedStates.values()).map(async (meterSharedState) => {
|
|
9164
9235
|
const current = await meterSharedState.collect(this, collectionTime, options);
|
|
9165
|
-
if (
|
|
9236
|
+
if (current?.scopeMetrics != null) {
|
|
9166
9237
|
scopeMetrics.push(current.scopeMetrics);
|
|
9167
9238
|
}
|
|
9168
|
-
if (
|
|
9239
|
+
if (current?.errors != null) {
|
|
9169
9240
|
errors.push(...current.errors);
|
|
9170
9241
|
}
|
|
9171
9242
|
});
|
|
@@ -9201,12 +9272,9 @@ var require_MetricCollector = __commonJS({
|
|
|
9201
9272
|
* collector.
|
|
9202
9273
|
*/
|
|
9203
9274
|
selectCardinalityLimit(instrumentType) {
|
|
9204
|
-
|
|
9205
|
-
return ((_b2 = (_a3 = this._metricReader).selectCardinalityLimit) == null ? void 0 : _b2.call(_a3, instrumentType)) ?? 2e3;
|
|
9275
|
+
return this._metricReader.selectCardinalityLimit?.(instrumentType) ?? 2e3;
|
|
9206
9276
|
}
|
|
9207
9277
|
};
|
|
9208
|
-
__name(_MetricCollector, "MetricCollector");
|
|
9209
|
-
var MetricCollector = _MetricCollector;
|
|
9210
9278
|
exports.MetricCollector = MetricCollector;
|
|
9211
9279
|
}
|
|
9212
9280
|
});
|
|
@@ -9218,7 +9286,10 @@ var require_Predicate = __commonJS({
|
|
|
9218
9286
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9219
9287
|
exports.ExactPredicate = exports.PatternPredicate = void 0;
|
|
9220
9288
|
var ESCAPE = /[\^$\\.+?()[\]{}|]/g;
|
|
9221
|
-
var
|
|
9289
|
+
var PatternPredicate = class _PatternPredicate {
|
|
9290
|
+
static {
|
|
9291
|
+
__name(this, "PatternPredicate");
|
|
9292
|
+
}
|
|
9222
9293
|
_matchAll;
|
|
9223
9294
|
_regexp;
|
|
9224
9295
|
constructor(pattern) {
|
|
@@ -9243,10 +9314,11 @@ var require_Predicate = __commonJS({
|
|
|
9243
9314
|
return pattern.includes("*");
|
|
9244
9315
|
}
|
|
9245
9316
|
};
|
|
9246
|
-
__name(_PatternPredicate, "PatternPredicate");
|
|
9247
|
-
var PatternPredicate = _PatternPredicate;
|
|
9248
9317
|
exports.PatternPredicate = PatternPredicate;
|
|
9249
|
-
var
|
|
9318
|
+
var ExactPredicate = class {
|
|
9319
|
+
static {
|
|
9320
|
+
__name(this, "ExactPredicate");
|
|
9321
|
+
}
|
|
9250
9322
|
_matchAll;
|
|
9251
9323
|
_pattern;
|
|
9252
9324
|
constructor(pattern) {
|
|
@@ -9263,8 +9335,6 @@ var require_Predicate = __commonJS({
|
|
|
9263
9335
|
return false;
|
|
9264
9336
|
}
|
|
9265
9337
|
};
|
|
9266
|
-
__name(_ExactPredicate, "ExactPredicate");
|
|
9267
|
-
var ExactPredicate = _ExactPredicate;
|
|
9268
9338
|
exports.ExactPredicate = ExactPredicate;
|
|
9269
9339
|
}
|
|
9270
9340
|
});
|
|
@@ -9276,14 +9346,17 @@ var require_InstrumentSelector = __commonJS({
|
|
|
9276
9346
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9277
9347
|
exports.InstrumentSelector = void 0;
|
|
9278
9348
|
var Predicate_1 = require_Predicate();
|
|
9279
|
-
var
|
|
9349
|
+
var InstrumentSelector = class {
|
|
9350
|
+
static {
|
|
9351
|
+
__name(this, "InstrumentSelector");
|
|
9352
|
+
}
|
|
9280
9353
|
_nameFilter;
|
|
9281
9354
|
_type;
|
|
9282
9355
|
_unitFilter;
|
|
9283
9356
|
constructor(criteria) {
|
|
9284
|
-
this._nameFilter = new Predicate_1.PatternPredicate(
|
|
9285
|
-
this._type = criteria
|
|
9286
|
-
this._unitFilter = new Predicate_1.ExactPredicate(criteria
|
|
9357
|
+
this._nameFilter = new Predicate_1.PatternPredicate(criteria?.name ?? "*");
|
|
9358
|
+
this._type = criteria?.type;
|
|
9359
|
+
this._unitFilter = new Predicate_1.ExactPredicate(criteria?.unit);
|
|
9287
9360
|
}
|
|
9288
9361
|
getType() {
|
|
9289
9362
|
return this._type;
|
|
@@ -9295,8 +9368,6 @@ var require_InstrumentSelector = __commonJS({
|
|
|
9295
9368
|
return this._unitFilter;
|
|
9296
9369
|
}
|
|
9297
9370
|
};
|
|
9298
|
-
__name(_InstrumentSelector, "InstrumentSelector");
|
|
9299
|
-
var InstrumentSelector = _InstrumentSelector;
|
|
9300
9371
|
exports.InstrumentSelector = InstrumentSelector;
|
|
9301
9372
|
}
|
|
9302
9373
|
});
|
|
@@ -9308,14 +9379,17 @@ var require_MeterSelector = __commonJS({
|
|
|
9308
9379
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
9309
9380
|
exports.MeterSelector = void 0;
|
|
9310
9381
|
var Predicate_1 = require_Predicate();
|
|
9311
|
-
var
|
|
9382
|
+
var MeterSelector = class {
|
|
9383
|
+
static {
|
|
9384
|
+
__name(this, "MeterSelector");
|
|
9385
|
+
}
|
|
9312
9386
|
_nameFilter;
|
|
9313
9387
|
_versionFilter;
|
|
9314
9388
|
_schemaUrlFilter;
|
|
9315
9389
|
constructor(criteria) {
|
|
9316
|
-
this._nameFilter = new Predicate_1.ExactPredicate(criteria
|
|
9317
|
-
this._versionFilter = new Predicate_1.ExactPredicate(criteria
|
|
9318
|
-
this._schemaUrlFilter = new Predicate_1.ExactPredicate(criteria
|
|
9390
|
+
this._nameFilter = new Predicate_1.ExactPredicate(criteria?.name);
|
|
9391
|
+
this._versionFilter = new Predicate_1.ExactPredicate(criteria?.version);
|
|
9392
|
+
this._schemaUrlFilter = new Predicate_1.ExactPredicate(criteria?.schemaUrl);
|
|
9319
9393
|
}
|
|
9320
9394
|
getNameFilter() {
|
|
9321
9395
|
return this._nameFilter;
|
|
@@ -9330,8 +9404,6 @@ var require_MeterSelector = __commonJS({
|
|
|
9330
9404
|
return this._schemaUrlFilter;
|
|
9331
9405
|
}
|
|
9332
9406
|
};
|
|
9333
|
-
__name(_MeterSelector, "MeterSelector");
|
|
9334
|
-
var MeterSelector = _MeterSelector;
|
|
9335
9407
|
exports.MeterSelector = MeterSelector;
|
|
9336
9408
|
}
|
|
9337
9409
|
});
|
|
@@ -9355,12 +9427,15 @@ var require_View = __commonJS({
|
|
|
9355
9427
|
if (isSelectorNotProvided(viewOptions)) {
|
|
9356
9428
|
throw new Error("Cannot create view with no selector arguments supplied");
|
|
9357
9429
|
}
|
|
9358
|
-
if (viewOptions.name != null && (
|
|
9430
|
+
if (viewOptions.name != null && (viewOptions?.instrumentName == null || Predicate_1.PatternPredicate.hasWildcard(viewOptions.instrumentName))) {
|
|
9359
9431
|
throw new Error("Views with a specified name must be declared with an instrument selector that selects at most one instrument per meter.");
|
|
9360
9432
|
}
|
|
9361
9433
|
}
|
|
9362
9434
|
__name(validateViewOptions, "validateViewOptions");
|
|
9363
|
-
var
|
|
9435
|
+
var View = class {
|
|
9436
|
+
static {
|
|
9437
|
+
__name(this, "View");
|
|
9438
|
+
}
|
|
9364
9439
|
name;
|
|
9365
9440
|
description;
|
|
9366
9441
|
aggregation;
|
|
@@ -9447,8 +9522,6 @@ var require_View = __commonJS({
|
|
|
9447
9522
|
this.aggregationCardinalityLimit = viewOptions.aggregationCardinalityLimit;
|
|
9448
9523
|
}
|
|
9449
9524
|
};
|
|
9450
|
-
__name(_View, "View");
|
|
9451
|
-
var View = _View;
|
|
9452
9525
|
exports.View = View;
|
|
9453
9526
|
}
|
|
9454
9527
|
});
|
|
@@ -9464,17 +9537,20 @@ var require_MeterProvider = __commonJS({
|
|
|
9464
9537
|
var MeterProviderSharedState_1 = require_MeterProviderSharedState();
|
|
9465
9538
|
var MetricCollector_1 = require_MetricCollector();
|
|
9466
9539
|
var View_1 = require_View();
|
|
9467
|
-
var
|
|
9540
|
+
var MeterProvider3 = class {
|
|
9541
|
+
static {
|
|
9542
|
+
__name(this, "MeterProvider");
|
|
9543
|
+
}
|
|
9468
9544
|
_sharedState;
|
|
9469
9545
|
_shutdown = false;
|
|
9470
9546
|
constructor(options) {
|
|
9471
|
-
this._sharedState = new MeterProviderSharedState_1.MeterProviderSharedState(
|
|
9472
|
-
if (
|
|
9547
|
+
this._sharedState = new MeterProviderSharedState_1.MeterProviderSharedState(options?.resource ?? (0, resources_1.defaultResource)());
|
|
9548
|
+
if (options?.views != null && options.views.length > 0) {
|
|
9473
9549
|
for (const viewOption of options.views) {
|
|
9474
9550
|
this._sharedState.viewRegistry.addView(new View_1.View(viewOption));
|
|
9475
9551
|
}
|
|
9476
9552
|
}
|
|
9477
|
-
if (
|
|
9553
|
+
if (options?.readers != null && options.readers.length > 0) {
|
|
9478
9554
|
for (const metricReader of options.readers) {
|
|
9479
9555
|
const collector = new MetricCollector_1.MetricCollector(this._sharedState, metricReader);
|
|
9480
9556
|
metricReader.setMetricProducer(collector);
|
|
@@ -9527,8 +9603,6 @@ var require_MeterProvider = __commonJS({
|
|
|
9527
9603
|
}));
|
|
9528
9604
|
}
|
|
9529
9605
|
};
|
|
9530
|
-
__name(_MeterProvider, "MeterProvider");
|
|
9531
|
-
var MeterProvider3 = _MeterProvider;
|
|
9532
9606
|
exports.MeterProvider = MeterProvider3;
|
|
9533
9607
|
}
|
|
9534
9608
|
});
|
|
@@ -9593,14 +9667,15 @@ init_esm();
|
|
|
9593
9667
|
import url from "node:url";
|
|
9594
9668
|
|
|
9595
9669
|
// ../../node_modules/.store/@typespec-ts-http-runtime-npm-0.3.4-02baaeb328/package/dist/esm/abort-controller/AbortError.js
|
|
9596
|
-
var
|
|
9670
|
+
var AbortError = class extends Error {
|
|
9671
|
+
static {
|
|
9672
|
+
__name(this, "AbortError");
|
|
9673
|
+
}
|
|
9597
9674
|
constructor(message) {
|
|
9598
9675
|
super(message);
|
|
9599
9676
|
this.name = "AbortError";
|
|
9600
9677
|
}
|
|
9601
9678
|
};
|
|
9602
|
-
__name(_AbortError, "AbortError");
|
|
9603
|
-
var AbortError = _AbortError;
|
|
9604
9679
|
|
|
9605
9680
|
// ../../node_modules/.store/@typespec-ts-http-runtime-npm-0.3.4-02baaeb328/package/dist/esm/logger/log.js
|
|
9606
9681
|
import { EOL } from "node:os";
|
|
@@ -9885,7 +9960,10 @@ function* headerIterator(map) {
|
|
|
9885
9960
|
}
|
|
9886
9961
|
}
|
|
9887
9962
|
__name(headerIterator, "headerIterator");
|
|
9888
|
-
var
|
|
9963
|
+
var HttpHeadersImpl = class {
|
|
9964
|
+
static {
|
|
9965
|
+
__name(this, "HttpHeadersImpl");
|
|
9966
|
+
}
|
|
9889
9967
|
_headersMap;
|
|
9890
9968
|
constructor(rawHeaders) {
|
|
9891
9969
|
this._headersMap = /* @__PURE__ */ new Map();
|
|
@@ -9910,8 +9988,7 @@ var _HttpHeadersImpl = class _HttpHeadersImpl {
|
|
|
9910
9988
|
* @param name - The name of the header. This value is case-insensitive.
|
|
9911
9989
|
*/
|
|
9912
9990
|
get(name) {
|
|
9913
|
-
|
|
9914
|
-
return (_a3 = this._headersMap.get(normalizeName(name))) == null ? void 0 : _a3.value;
|
|
9991
|
+
return this._headersMap.get(normalizeName(name))?.value;
|
|
9915
9992
|
}
|
|
9916
9993
|
/**
|
|
9917
9994
|
* Get whether or not this header collection contains a header entry for the provided header name.
|
|
@@ -9956,8 +10033,6 @@ var _HttpHeadersImpl = class _HttpHeadersImpl {
|
|
|
9956
10033
|
return headerIterator(this._headersMap);
|
|
9957
10034
|
}
|
|
9958
10035
|
};
|
|
9959
|
-
__name(_HttpHeadersImpl, "HttpHeadersImpl");
|
|
9960
|
-
var HttpHeadersImpl = _HttpHeadersImpl;
|
|
9961
10036
|
function createHttpHeaders(rawHeaders) {
|
|
9962
10037
|
return new HttpHeadersImpl(rawHeaders);
|
|
9963
10038
|
}
|
|
@@ -9970,7 +10045,10 @@ function randomUUID() {
|
|
|
9970
10045
|
__name(randomUUID, "randomUUID");
|
|
9971
10046
|
|
|
9972
10047
|
// ../../node_modules/.store/@typespec-ts-http-runtime-npm-0.3.4-02baaeb328/package/dist/esm/pipelineRequest.js
|
|
9973
|
-
var
|
|
10048
|
+
var PipelineRequestImpl = class {
|
|
10049
|
+
static {
|
|
10050
|
+
__name(this, "PipelineRequestImpl");
|
|
10051
|
+
}
|
|
9974
10052
|
url;
|
|
9975
10053
|
method;
|
|
9976
10054
|
headers;
|
|
@@ -10012,8 +10090,6 @@ var _PipelineRequestImpl = class _PipelineRequestImpl {
|
|
|
10012
10090
|
this.authSchemes = options.authSchemes;
|
|
10013
10091
|
}
|
|
10014
10092
|
};
|
|
10015
|
-
__name(_PipelineRequestImpl, "PipelineRequestImpl");
|
|
10016
|
-
var PipelineRequestImpl = _PipelineRequestImpl;
|
|
10017
10093
|
function createPipelineRequest(options) {
|
|
10018
10094
|
return new PipelineRequestImpl(options);
|
|
10019
10095
|
}
|
|
@@ -10021,11 +10097,14 @@ __name(createPipelineRequest, "createPipelineRequest");
|
|
|
10021
10097
|
|
|
10022
10098
|
// ../../node_modules/.store/@typespec-ts-http-runtime-npm-0.3.4-02baaeb328/package/dist/esm/pipeline.js
|
|
10023
10099
|
var ValidPhaseNames = /* @__PURE__ */ new Set(["Deserialize", "Serialize", "Retry", "Sign"]);
|
|
10024
|
-
var
|
|
10100
|
+
var HttpPipeline = class _HttpPipeline {
|
|
10101
|
+
static {
|
|
10102
|
+
__name(this, "HttpPipeline");
|
|
10103
|
+
}
|
|
10025
10104
|
_policies = [];
|
|
10026
10105
|
_orderedPolicies;
|
|
10027
10106
|
constructor(policies) {
|
|
10028
|
-
this._policies =
|
|
10107
|
+
this._policies = policies?.slice(0) ?? [];
|
|
10029
10108
|
this._orderedPolicies = void 0;
|
|
10030
10109
|
}
|
|
10031
10110
|
addPolicy(policy, options = {}) {
|
|
@@ -10200,8 +10279,6 @@ var _HttpPipeline = class _HttpPipeline {
|
|
|
10200
10279
|
return result;
|
|
10201
10280
|
}
|
|
10202
10281
|
};
|
|
10203
|
-
__name(_HttpPipeline, "HttpPipeline");
|
|
10204
|
-
var HttpPipeline = _HttpPipeline;
|
|
10205
10282
|
function createEmptyPipeline() {
|
|
10206
10283
|
return HttpPipeline.create();
|
|
10207
10284
|
}
|
|
@@ -10272,7 +10349,10 @@ var defaultAllowedHeaderNames = [
|
|
|
10272
10349
|
"WWW-Authenticate"
|
|
10273
10350
|
];
|
|
10274
10351
|
var defaultAllowedQueryParameters = ["api-version"];
|
|
10275
|
-
var
|
|
10352
|
+
var Sanitizer = class {
|
|
10353
|
+
static {
|
|
10354
|
+
__name(this, "Sanitizer");
|
|
10355
|
+
}
|
|
10276
10356
|
allowedHeaderNames;
|
|
10277
10357
|
allowedQueryParameters;
|
|
10278
10358
|
constructor({ additionalAllowedHeaderNames: allowedHeaderNames = [], additionalAllowedQueryParameters: allowedQueryParameters = [] } = {}) {
|
|
@@ -10363,12 +10443,24 @@ var _Sanitizer = class _Sanitizer {
|
|
|
10363
10443
|
return sanitized;
|
|
10364
10444
|
}
|
|
10365
10445
|
};
|
|
10366
|
-
__name(_Sanitizer, "Sanitizer");
|
|
10367
|
-
var Sanitizer = _Sanitizer;
|
|
10368
10446
|
|
|
10369
10447
|
// ../../node_modules/.store/@typespec-ts-http-runtime-npm-0.3.4-02baaeb328/package/dist/esm/restError.js
|
|
10370
10448
|
var errorSanitizer = new Sanitizer();
|
|
10371
|
-
var
|
|
10449
|
+
var RestError = class _RestError extends Error {
|
|
10450
|
+
static {
|
|
10451
|
+
__name(this, "RestError");
|
|
10452
|
+
}
|
|
10453
|
+
/**
|
|
10454
|
+
* Something went wrong when making the request.
|
|
10455
|
+
* This means the actual request failed for some reason,
|
|
10456
|
+
* such as a DNS issue or the connection being lost.
|
|
10457
|
+
*/
|
|
10458
|
+
static REQUEST_SEND_ERROR = "REQUEST_SEND_ERROR";
|
|
10459
|
+
/**
|
|
10460
|
+
* This means that parsing the response from the server failed.
|
|
10461
|
+
* It may have been malformed.
|
|
10462
|
+
*/
|
|
10463
|
+
static PARSE_ERROR = "PARSE_ERROR";
|
|
10372
10464
|
/**
|
|
10373
10465
|
* The code of the error itself (use statics on RestError if possible.)
|
|
10374
10466
|
*/
|
|
@@ -10392,14 +10484,13 @@ var _RestError = class _RestError extends Error {
|
|
|
10392
10484
|
*/
|
|
10393
10485
|
details;
|
|
10394
10486
|
constructor(message, options = {}) {
|
|
10395
|
-
var _a3;
|
|
10396
10487
|
super(message);
|
|
10397
10488
|
this.name = "RestError";
|
|
10398
10489
|
this.code = options.code;
|
|
10399
10490
|
this.statusCode = options.statusCode;
|
|
10400
10491
|
Object.defineProperty(this, "request", { value: options.request, enumerable: false });
|
|
10401
10492
|
Object.defineProperty(this, "response", { value: options.response, enumerable: false });
|
|
10402
|
-
const agent =
|
|
10493
|
+
const agent = this.request?.agent ? {
|
|
10403
10494
|
maxFreeSockets: this.request.agent.maxFreeSockets,
|
|
10404
10495
|
maxSockets: this.request.agent.maxSockets
|
|
10405
10496
|
} : void 0;
|
|
@@ -10417,19 +10508,6 @@ var _RestError = class _RestError extends Error {
|
|
|
10417
10508
|
Object.setPrototypeOf(this, _RestError.prototype);
|
|
10418
10509
|
}
|
|
10419
10510
|
};
|
|
10420
|
-
__name(_RestError, "RestError");
|
|
10421
|
-
/**
|
|
10422
|
-
* Something went wrong when making the request.
|
|
10423
|
-
* This means the actual request failed for some reason,
|
|
10424
|
-
* such as a DNS issue or the connection being lost.
|
|
10425
|
-
*/
|
|
10426
|
-
__publicField(_RestError, "REQUEST_SEND_ERROR", "REQUEST_SEND_ERROR");
|
|
10427
|
-
/**
|
|
10428
|
-
* This means that parsing the response from the server failed.
|
|
10429
|
-
* It may have been malformed.
|
|
10430
|
-
*/
|
|
10431
|
-
__publicField(_RestError, "PARSE_ERROR", "PARSE_ERROR");
|
|
10432
|
-
var RestError = _RestError;
|
|
10433
10511
|
function isRestError(e) {
|
|
10434
10512
|
if (e instanceof RestError) {
|
|
10435
10513
|
return true;
|
|
@@ -10480,7 +10558,10 @@ function isArrayBuffer(body2) {
|
|
|
10480
10558
|
return body2 && typeof body2.byteLength === "number";
|
|
10481
10559
|
}
|
|
10482
10560
|
__name(isArrayBuffer, "isArrayBuffer");
|
|
10483
|
-
var
|
|
10561
|
+
var ReportTransform = class extends Transform {
|
|
10562
|
+
static {
|
|
10563
|
+
__name(this, "ReportTransform");
|
|
10564
|
+
}
|
|
10484
10565
|
loadedBytes = 0;
|
|
10485
10566
|
progressCallback;
|
|
10486
10567
|
// eslint-disable-next-line @typescript-eslint/no-unsafe-function-type
|
|
@@ -10499,9 +10580,10 @@ var _ReportTransform = class _ReportTransform extends Transform {
|
|
|
10499
10580
|
this.progressCallback = progressCallback;
|
|
10500
10581
|
}
|
|
10501
10582
|
};
|
|
10502
|
-
|
|
10503
|
-
|
|
10504
|
-
|
|
10583
|
+
var NodeHttpClient = class {
|
|
10584
|
+
static {
|
|
10585
|
+
__name(this, "NodeHttpClient");
|
|
10586
|
+
}
|
|
10505
10587
|
cachedHttpAgent;
|
|
10506
10588
|
cachedHttpsAgents = /* @__PURE__ */ new WeakMap();
|
|
10507
10589
|
/**
|
|
@@ -10509,7 +10591,6 @@ var _NodeHttpClient = class _NodeHttpClient {
|
|
|
10509
10591
|
* @param request - The request to be made.
|
|
10510
10592
|
*/
|
|
10511
10593
|
async sendRequest(request) {
|
|
10512
|
-
var _a3, _b2;
|
|
10513
10594
|
const abortController = new AbortController();
|
|
10514
10595
|
let abortListener;
|
|
10515
10596
|
if (request.abortSignal) {
|
|
@@ -10532,7 +10613,7 @@ var _NodeHttpClient = class _NodeHttpClient {
|
|
|
10532
10613
|
}, request.timeout);
|
|
10533
10614
|
}
|
|
10534
10615
|
const acceptEncoding = request.headers.get("Accept-Encoding");
|
|
10535
|
-
const shouldDecompress =
|
|
10616
|
+
const shouldDecompress = acceptEncoding?.includes("gzip") || acceptEncoding?.includes("deflate");
|
|
10536
10617
|
let body2 = typeof request.body === "function" ? request.body() : request.body;
|
|
10537
10618
|
if (body2 && !request.headers.has("Content-Length")) {
|
|
10538
10619
|
const bodyLength = getBodyLength(body2);
|
|
@@ -10582,7 +10663,7 @@ var _NodeHttpClient = class _NodeHttpClient {
|
|
|
10582
10663
|
}
|
|
10583
10664
|
if (
|
|
10584
10665
|
// Value of POSITIVE_INFINITY in streamResponseStatusCodes is considered as any status code
|
|
10585
|
-
|
|
10666
|
+
request.streamResponseStatusCodes?.has(Number.POSITIVE_INFINITY) || request.streamResponseStatusCodes?.has(response.status)
|
|
10586
10667
|
) {
|
|
10587
10668
|
response.readableStreamBody = responseStream;
|
|
10588
10669
|
} else {
|
|
@@ -10600,9 +10681,8 @@ var _NodeHttpClient = class _NodeHttpClient {
|
|
|
10600
10681
|
downloadStreamDone = isStreamComplete(responseStream);
|
|
10601
10682
|
}
|
|
10602
10683
|
Promise.all([uploadStreamDone, downloadStreamDone]).then(() => {
|
|
10603
|
-
var _a4;
|
|
10604
10684
|
if (abortListener) {
|
|
10605
|
-
|
|
10685
|
+
request.abortSignal?.removeEventListener("abort", abortListener);
|
|
10606
10686
|
}
|
|
10607
10687
|
}).catch((e) => {
|
|
10608
10688
|
logger.warning("Error when cleaning up abortListener on httpRequest", e);
|
|
@@ -10683,8 +10763,6 @@ var _NodeHttpClient = class _NodeHttpClient {
|
|
|
10683
10763
|
}
|
|
10684
10764
|
}
|
|
10685
10765
|
};
|
|
10686
|
-
__name(_NodeHttpClient, "NodeHttpClient");
|
|
10687
|
-
var NodeHttpClient = _NodeHttpClient;
|
|
10688
10766
|
function getResponseHeaders(res) {
|
|
10689
10767
|
const headers = createHttpHeaders();
|
|
10690
10768
|
for (const header of Object.keys(res.headers)) {
|
|
@@ -10728,7 +10806,7 @@ function streamToText(stream) {
|
|
|
10728
10806
|
resolve(Buffer.concat(buffer).toString("utf8"));
|
|
10729
10807
|
});
|
|
10730
10808
|
stream.on("error", (e) => {
|
|
10731
|
-
if (e &&
|
|
10809
|
+
if (e && e?.name === "AbortError") {
|
|
10732
10810
|
reject(e);
|
|
10733
10811
|
} else {
|
|
10734
10812
|
reject(new RestError(`Error reading response as text: ${e.message}`, {
|
|
@@ -10888,10 +10966,10 @@ function delay(delayInMs, value, options) {
|
|
|
10888
10966
|
let timer = void 0;
|
|
10889
10967
|
let onAborted = void 0;
|
|
10890
10968
|
const rejectOnAbort = /* @__PURE__ */ __name(() => {
|
|
10891
|
-
return reject(new AbortError(
|
|
10969
|
+
return reject(new AbortError(options?.abortErrorMsg ? options?.abortErrorMsg : StandardAbortMessage));
|
|
10892
10970
|
}, "rejectOnAbort");
|
|
10893
10971
|
const removeListeners = /* @__PURE__ */ __name(() => {
|
|
10894
|
-
if (
|
|
10972
|
+
if (options?.abortSignal && onAborted) {
|
|
10895
10973
|
options.abortSignal.removeEventListener("abort", onAborted);
|
|
10896
10974
|
}
|
|
10897
10975
|
}, "removeListeners");
|
|
@@ -10902,14 +10980,14 @@ function delay(delayInMs, value, options) {
|
|
|
10902
10980
|
removeListeners();
|
|
10903
10981
|
return rejectOnAbort();
|
|
10904
10982
|
}, "onAborted");
|
|
10905
|
-
if (
|
|
10983
|
+
if (options?.abortSignal && options.abortSignal.aborted) {
|
|
10906
10984
|
return rejectOnAbort();
|
|
10907
10985
|
}
|
|
10908
10986
|
timer = setTimeout(() => {
|
|
10909
10987
|
removeListeners();
|
|
10910
10988
|
resolve(value);
|
|
10911
10989
|
}, delayInMs);
|
|
10912
|
-
if (options
|
|
10990
|
+
if (options?.abortSignal) {
|
|
10913
10991
|
options.abortSignal.addEventListener("abort", onAborted);
|
|
10914
10992
|
}
|
|
10915
10993
|
});
|
|
@@ -11019,7 +11097,6 @@ function retryPolicy(strategies, options = { maxRetries: DEFAULT_RETRY_POLICY_CO
|
|
|
11019
11097
|
return {
|
|
11020
11098
|
name: retryPolicyName,
|
|
11021
11099
|
async sendRequest(request, next) {
|
|
11022
|
-
var _a3;
|
|
11023
11100
|
let response;
|
|
11024
11101
|
let responseError;
|
|
11025
11102
|
let retryCount = -1;
|
|
@@ -11039,7 +11116,7 @@ function retryPolicy(strategies, options = { maxRetries: DEFAULT_RETRY_POLICY_CO
|
|
|
11039
11116
|
}
|
|
11040
11117
|
response = responseError.response;
|
|
11041
11118
|
}
|
|
11042
|
-
if (
|
|
11119
|
+
if (request.abortSignal?.aborted) {
|
|
11043
11120
|
logger4.error(`Retry ${retryCount}: Request aborted.`);
|
|
11044
11121
|
const abortError = new AbortError();
|
|
11045
11122
|
throw abortError;
|
|
@@ -11111,13 +11188,11 @@ __name(defaultRetryPolicy, "defaultRetryPolicy");
|
|
|
11111
11188
|
|
|
11112
11189
|
// ../../node_modules/.store/@typespec-ts-http-runtime-npm-0.3.4-02baaeb328/package/dist/esm/util/checkEnvironment.js
|
|
11113
11190
|
var isBrowser = typeof window !== "undefined" && typeof window.document !== "undefined";
|
|
11114
|
-
var
|
|
11115
|
-
var isWebWorker = typeof self === "object" && typeof (self == null ? void 0 : self.importScripts) === "function" && (((_a = self.constructor) == null ? void 0 : _a.name) === "DedicatedWorkerGlobalScope" || ((_b = self.constructor) == null ? void 0 : _b.name) === "ServiceWorkerGlobalScope" || ((_c = self.constructor) == null ? void 0 : _c.name) === "SharedWorkerGlobalScope");
|
|
11191
|
+
var isWebWorker = typeof self === "object" && typeof self?.importScripts === "function" && (self.constructor?.name === "DedicatedWorkerGlobalScope" || self.constructor?.name === "ServiceWorkerGlobalScope" || self.constructor?.name === "SharedWorkerGlobalScope");
|
|
11116
11192
|
var isDeno = typeof Deno !== "undefined" && typeof Deno.version !== "undefined" && typeof Deno.version.deno !== "undefined";
|
|
11117
11193
|
var isBun = typeof Bun !== "undefined" && typeof Bun.version !== "undefined";
|
|
11118
|
-
var
|
|
11119
|
-
var
|
|
11120
|
-
var isReactNative = typeof navigator !== "undefined" && (navigator == null ? void 0 : navigator.product) === "ReactNative";
|
|
11194
|
+
var isNodeLike = typeof globalThis.process !== "undefined" && Boolean(globalThis.process.version) && Boolean(globalThis.process.versions?.node);
|
|
11195
|
+
var isReactNative = typeof navigator !== "undefined" && navigator?.product === "ReactNative";
|
|
11121
11196
|
|
|
11122
11197
|
// ../../node_modules/.store/@typespec-ts-http-runtime-npm-0.3.4-02baaeb328/package/dist/esm/policies/formDataPolicy.js
|
|
11123
11198
|
var formDataPolicyName = "formDataPolicy";
|
|
@@ -11235,7 +11310,7 @@ function isBypassed(uri, noProxyList, bypassedMap) {
|
|
|
11235
11310
|
return false;
|
|
11236
11311
|
}
|
|
11237
11312
|
const host2 = new URL(uri).hostname;
|
|
11238
|
-
if (bypassedMap
|
|
11313
|
+
if (bypassedMap?.has(host2)) {
|
|
11239
11314
|
return bypassedMap.get(host2);
|
|
11240
11315
|
}
|
|
11241
11316
|
let isBypassedFlag = false;
|
|
@@ -11254,7 +11329,7 @@ function isBypassed(uri, noProxyList, bypassedMap) {
|
|
|
11254
11329
|
}
|
|
11255
11330
|
}
|
|
11256
11331
|
}
|
|
11257
|
-
bypassedMap
|
|
11332
|
+
bypassedMap?.set(host2, isBypassedFlag);
|
|
11258
11333
|
return isBypassedFlag;
|
|
11259
11334
|
}
|
|
11260
11335
|
__name(isBypassed, "isBypassed");
|
|
@@ -11321,7 +11396,7 @@ function proxyPolicy(proxySettings, options) {
|
|
|
11321
11396
|
return {
|
|
11322
11397
|
name: proxyPolicyName,
|
|
11323
11398
|
async sendRequest(request, next) {
|
|
11324
|
-
if (!request.proxySettings && defaultProxy && !isBypassed(request.url,
|
|
11399
|
+
if (!request.proxySettings && defaultProxy && !isBypassed(request.url, options?.customNoProxyList ?? globalNoProxyList, options?.customNoProxyList ? void 0 : globalBypassedMap)) {
|
|
11325
11400
|
setProxyAgentOnRequest(request, cachedAgents, defaultProxy);
|
|
11326
11401
|
} else if (request.proxySettings) {
|
|
11327
11402
|
setProxyAgentOnRequest(request, cachedAgents, getUrlFromProxySettings(request.proxySettings));
|
|
@@ -11634,14 +11709,15 @@ function userAgentPolicy2(options = {}) {
|
|
|
11634
11709
|
__name(userAgentPolicy2, "userAgentPolicy");
|
|
11635
11710
|
|
|
11636
11711
|
// ../../node_modules/.store/@azure-abort-controller-npm-2.1.2-a36d73ebb9/package/dist/esm/AbortError.js
|
|
11637
|
-
var
|
|
11712
|
+
var AbortError2 = class extends Error {
|
|
11713
|
+
static {
|
|
11714
|
+
__name(this, "AbortError");
|
|
11715
|
+
}
|
|
11638
11716
|
constructor(message) {
|
|
11639
11717
|
super(message);
|
|
11640
11718
|
this.name = "AbortError";
|
|
11641
11719
|
}
|
|
11642
11720
|
};
|
|
11643
|
-
__name(_AbortError2, "AbortError");
|
|
11644
|
-
var AbortError2 = _AbortError2;
|
|
11645
11721
|
|
|
11646
11722
|
// ../../node_modules/.store/@azure-core-util-npm-1.13.1-f6d65e92ea/package/dist/esm/createAbortablePromise.js
|
|
11647
11723
|
function createAbortablePromise(buildPromise, options) {
|
|
@@ -11652,16 +11728,16 @@ function createAbortablePromise(buildPromise, options) {
|
|
|
11652
11728
|
}
|
|
11653
11729
|
__name(rejectOnAbort, "rejectOnAbort");
|
|
11654
11730
|
function removeListeners() {
|
|
11655
|
-
abortSignal
|
|
11731
|
+
abortSignal?.removeEventListener("abort", onAbort);
|
|
11656
11732
|
}
|
|
11657
11733
|
__name(removeListeners, "removeListeners");
|
|
11658
11734
|
function onAbort() {
|
|
11659
|
-
cleanupBeforeAbort
|
|
11735
|
+
cleanupBeforeAbort?.();
|
|
11660
11736
|
removeListeners();
|
|
11661
11737
|
rejectOnAbort();
|
|
11662
11738
|
}
|
|
11663
11739
|
__name(onAbort, "onAbort");
|
|
11664
|
-
if (abortSignal
|
|
11740
|
+
if (abortSignal?.aborted) {
|
|
11665
11741
|
return rejectOnAbort();
|
|
11666
11742
|
}
|
|
11667
11743
|
try {
|
|
@@ -11675,7 +11751,7 @@ function createAbortablePromise(buildPromise, options) {
|
|
|
11675
11751
|
} catch (err) {
|
|
11676
11752
|
reject(err);
|
|
11677
11753
|
}
|
|
11678
|
-
abortSignal
|
|
11754
|
+
abortSignal?.addEventListener("abort", onAbort);
|
|
11679
11755
|
});
|
|
11680
11756
|
}
|
|
11681
11757
|
__name(createAbortablePromise, "createAbortablePromise");
|
|
@@ -11824,7 +11900,10 @@ function createTracingContext(options = {}) {
|
|
|
11824
11900
|
return context4;
|
|
11825
11901
|
}
|
|
11826
11902
|
__name(createTracingContext, "createTracingContext");
|
|
11827
|
-
var
|
|
11903
|
+
var TracingContextImpl = class _TracingContextImpl {
|
|
11904
|
+
static {
|
|
11905
|
+
__name(this, "TracingContextImpl");
|
|
11906
|
+
}
|
|
11828
11907
|
_contextMap;
|
|
11829
11908
|
constructor(initialContext) {
|
|
11830
11909
|
this._contextMap = initialContext instanceof _TracingContextImpl ? new Map(initialContext._contextMap) : /* @__PURE__ */ new Map();
|
|
@@ -11843,8 +11922,6 @@ var _TracingContextImpl = class _TracingContextImpl {
|
|
|
11843
11922
|
return newContext;
|
|
11844
11923
|
}
|
|
11845
11924
|
};
|
|
11846
|
-
__name(_TracingContextImpl, "TracingContextImpl");
|
|
11847
|
-
var TracingContextImpl = _TracingContextImpl;
|
|
11848
11925
|
|
|
11849
11926
|
// ../../node_modules/.store/@azure-core-tracing-npm-1.3.1-eb2949b9c4/package/dist/esm/state.js
|
|
11850
11927
|
var import_state = __toESM(require_state(), 1);
|
|
@@ -11899,12 +11976,11 @@ __name(getInstrumenter, "getInstrumenter");
|
|
|
11899
11976
|
function createTracingClient(options) {
|
|
11900
11977
|
const { namespace, packageName, packageVersion: packageVersion2 } = options;
|
|
11901
11978
|
function startSpan(name, operationOptions, spanOptions) {
|
|
11902
|
-
var _a3;
|
|
11903
11979
|
const startSpanResult = getInstrumenter().startSpan(name, {
|
|
11904
11980
|
...spanOptions,
|
|
11905
11981
|
packageName,
|
|
11906
11982
|
packageVersion: packageVersion2,
|
|
11907
|
-
tracingContext:
|
|
11983
|
+
tracingContext: operationOptions?.tracingOptions?.tracingContext
|
|
11908
11984
|
});
|
|
11909
11985
|
let tracingContext = startSpanResult.tracingContext;
|
|
11910
11986
|
const span = startSpanResult.span;
|
|
@@ -11913,7 +11989,7 @@ function createTracingClient(options) {
|
|
|
11913
11989
|
}
|
|
11914
11990
|
span.setAttribute("az.namespace", tracingContext.getValue(knownContextKeys.namespace));
|
|
11915
11991
|
const updatedOptions = Object.assign({}, operationOptions, {
|
|
11916
|
-
tracingOptions: { ...operationOptions
|
|
11992
|
+
tracingOptions: { ...operationOptions?.tracingOptions, tracingContext }
|
|
11917
11993
|
});
|
|
11918
11994
|
return {
|
|
11919
11995
|
span,
|
|
@@ -12113,7 +12189,7 @@ function wrapAbortSignalLikePolicy() {
|
|
|
12113
12189
|
try {
|
|
12114
12190
|
return await next(request);
|
|
12115
12191
|
} finally {
|
|
12116
|
-
cleanup
|
|
12192
|
+
cleanup?.();
|
|
12117
12193
|
}
|
|
12118
12194
|
}, "sendRequest")
|
|
12119
12195
|
};
|
|
@@ -12122,7 +12198,6 @@ __name(wrapAbortSignalLikePolicy, "wrapAbortSignalLikePolicy");
|
|
|
12122
12198
|
|
|
12123
12199
|
// ../../node_modules/.store/@azure-core-rest-pipeline-npm-1.23.0-0e1edaa1a0/package/dist/esm/createPipelineFromOptions.js
|
|
12124
12200
|
function createPipelineFromOptions2(options) {
|
|
12125
|
-
var _a3;
|
|
12126
12201
|
const pipeline = createEmptyPipeline2();
|
|
12127
12202
|
if (isNodeLike2) {
|
|
12128
12203
|
if (options.agent) {
|
|
@@ -12137,7 +12212,7 @@ function createPipelineFromOptions2(options) {
|
|
|
12137
12212
|
pipeline.addPolicy(wrapAbortSignalLikePolicy());
|
|
12138
12213
|
pipeline.addPolicy(formDataPolicy2(), { beforePolicies: [multipartPolicyName2] });
|
|
12139
12214
|
pipeline.addPolicy(userAgentPolicy2(options.userAgentOptions));
|
|
12140
|
-
pipeline.addPolicy(setClientRequestIdPolicy(
|
|
12215
|
+
pipeline.addPolicy(setClientRequestIdPolicy(options.telemetryOptions?.clientRequestIdHeaderName));
|
|
12141
12216
|
pipeline.addPolicy(multipartPolicy2(), { afterPhase: "Deserialize" });
|
|
12142
12217
|
pipeline.addPolicy(defaultRetryPolicy2(options.retryOptions), { phase: "Retry" });
|
|
12143
12218
|
pipeline.addPolicy(tracingPolicy({ ...options.userAgentOptions, ...options.loggingOptions }), {
|
|
@@ -12161,7 +12236,7 @@ function createDefaultHttpClient2() {
|
|
|
12161
12236
|
request.abortSignal = abortSignal;
|
|
12162
12237
|
return await client.sendRequest(request);
|
|
12163
12238
|
} finally {
|
|
12164
|
-
cleanup
|
|
12239
|
+
cleanup?.();
|
|
12165
12240
|
}
|
|
12166
12241
|
}
|
|
12167
12242
|
};
|
|
@@ -12234,10 +12309,10 @@ function createTokenCycler(credential, tokenCyclerOptions) {
|
|
|
12234
12309
|
if (cycler.isRefreshing) {
|
|
12235
12310
|
return false;
|
|
12236
12311
|
}
|
|
12237
|
-
if (
|
|
12312
|
+
if (token?.refreshAfterTimestamp && token.refreshAfterTimestamp < Date.now()) {
|
|
12238
12313
|
return true;
|
|
12239
12314
|
}
|
|
12240
|
-
return (
|
|
12315
|
+
return (token?.expiresOnTimestamp ?? 0) - options.refreshWindowInMs < Date.now();
|
|
12241
12316
|
},
|
|
12242
12317
|
/**
|
|
12243
12318
|
* Produces true if the cycler MUST refresh (null or nearly-expired
|
|
@@ -12254,7 +12329,7 @@ function createTokenCycler(credential, tokenCyclerOptions) {
|
|
|
12254
12329
|
tryGetAccessToken,
|
|
12255
12330
|
options.retryIntervalInMs,
|
|
12256
12331
|
// If we don't have a token, then we should timeout immediately
|
|
12257
|
-
|
|
12332
|
+
token?.expiresOnTimestamp ?? Date.now()
|
|
12258
12333
|
).then((_token) => {
|
|
12259
12334
|
refreshWorker = null;
|
|
12260
12335
|
token = _token;
|
|
@@ -12333,12 +12408,11 @@ async function authorizeRequestOnCaeChallenge(onChallengeOptions, caeClaims) {
|
|
|
12333
12408
|
}
|
|
12334
12409
|
__name(authorizeRequestOnCaeChallenge, "authorizeRequestOnCaeChallenge");
|
|
12335
12410
|
function bearerTokenAuthenticationPolicy(options) {
|
|
12336
|
-
var _a3, _b2;
|
|
12337
12411
|
const { credential, scopes, challengeCallbacks } = options;
|
|
12338
12412
|
const logger4 = options.logger || logger2;
|
|
12339
12413
|
const callbacks = {
|
|
12340
|
-
authorizeRequest:
|
|
12341
|
-
authorizeRequestOnChallenge:
|
|
12414
|
+
authorizeRequest: challengeCallbacks?.authorizeRequest?.bind(challengeCallbacks) ?? defaultAuthorizeRequest,
|
|
12415
|
+
authorizeRequestOnChallenge: challengeCallbacks?.authorizeRequestOnChallenge?.bind(challengeCallbacks)
|
|
12342
12416
|
};
|
|
12343
12417
|
const getAccessToken = credential ? createTokenCycler(
|
|
12344
12418
|
credential
|
|
@@ -12456,12 +12530,11 @@ function parseChallenges(challenges) {
|
|
|
12456
12530
|
}
|
|
12457
12531
|
__name(parseChallenges, "parseChallenges");
|
|
12458
12532
|
function getCaeChallengeClaims(challenges) {
|
|
12459
|
-
var _a3;
|
|
12460
12533
|
if (!challenges) {
|
|
12461
12534
|
return;
|
|
12462
12535
|
}
|
|
12463
12536
|
const parsedChallenges = parseChallenges(challenges);
|
|
12464
|
-
return
|
|
12537
|
+
return parsedChallenges.find((x) => x.scheme === "Bearer" && x.params.claims && x.params.error === "insufficient_claims")?.params.claims;
|
|
12465
12538
|
}
|
|
12466
12539
|
__name(getCaeChallengeClaims, "getCaeChallengeClaims");
|
|
12467
12540
|
|
|
@@ -12528,7 +12601,7 @@ var XML_CHARKEY = "_";
|
|
|
12528
12601
|
|
|
12529
12602
|
// ../../node_modules/.store/@azure-core-client-npm-1.10.1-c6f6d34e9a/package/dist/esm/utils.js
|
|
12530
12603
|
function isPrimitiveBody(value, mapperTypeName) {
|
|
12531
|
-
return mapperTypeName !== "Composite" && mapperTypeName !== "Dictionary" && (typeof value === "string" || typeof value === "number" || typeof value === "boolean" ||
|
|
12604
|
+
return mapperTypeName !== "Composite" && mapperTypeName !== "Dictionary" && (typeof value === "string" || typeof value === "number" || typeof value === "boolean" || mapperTypeName?.match(/^(Date|DateTime|DateTimeRfc1123|UnixTime|ByteArray|Base64Url)$/i) !== null || value === void 0 || value === null);
|
|
12532
12605
|
}
|
|
12533
12606
|
__name(isPrimitiveBody, "isPrimitiveBody");
|
|
12534
12607
|
var validateISODuration = /^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/;
|
|
@@ -12557,7 +12630,6 @@ function handleNullableResponseAndWrappableBody(responseObject) {
|
|
|
12557
12630
|
}
|
|
12558
12631
|
__name(handleNullableResponseAndWrappableBody, "handleNullableResponseAndWrappableBody");
|
|
12559
12632
|
function flattenResponse(fullResponse, responseSpec) {
|
|
12560
|
-
var _a3;
|
|
12561
12633
|
const parsedHeaders = fullResponse.parsedHeaders;
|
|
12562
12634
|
if (fullResponse.request.method === "HEAD") {
|
|
12563
12635
|
return {
|
|
@@ -12566,8 +12638,8 @@ function flattenResponse(fullResponse, responseSpec) {
|
|
|
12566
12638
|
};
|
|
12567
12639
|
}
|
|
12568
12640
|
const bodyMapper = responseSpec && responseSpec.bodyMapper;
|
|
12569
|
-
const isNullable = Boolean(bodyMapper
|
|
12570
|
-
const expectedBodyTypeName = bodyMapper
|
|
12641
|
+
const isNullable = Boolean(bodyMapper?.nullable);
|
|
12642
|
+
const expectedBodyTypeName = bodyMapper?.type.name;
|
|
12571
12643
|
if (expectedBodyTypeName === "Stream") {
|
|
12572
12644
|
return {
|
|
12573
12645
|
...parsedHeaders,
|
|
@@ -12581,7 +12653,7 @@ function flattenResponse(fullResponse, responseSpec) {
|
|
|
12581
12653
|
const arrayResponse = fullResponse.parsedBody ?? [];
|
|
12582
12654
|
for (const key of Object.keys(modelProperties)) {
|
|
12583
12655
|
if (modelProperties[key].serializedName) {
|
|
12584
|
-
arrayResponse[key] =
|
|
12656
|
+
arrayResponse[key] = fullResponse.parsedBody?.[key];
|
|
12585
12657
|
}
|
|
12586
12658
|
}
|
|
12587
12659
|
if (parsedHeaders) {
|
|
@@ -12601,7 +12673,10 @@ function flattenResponse(fullResponse, responseSpec) {
|
|
|
12601
12673
|
__name(flattenResponse, "flattenResponse");
|
|
12602
12674
|
|
|
12603
12675
|
// ../../node_modules/.store/@azure-core-client-npm-1.10.1-c6f6d34e9a/package/dist/esm/serializer.js
|
|
12604
|
-
var
|
|
12676
|
+
var SerializerImpl = class {
|
|
12677
|
+
static {
|
|
12678
|
+
__name(this, "SerializerImpl");
|
|
12679
|
+
}
|
|
12605
12680
|
modelMappers;
|
|
12606
12681
|
isXML;
|
|
12607
12682
|
constructor(modelMappers = {}, isXML = false) {
|
|
@@ -12803,8 +12878,6 @@ var _SerializerImpl = class _SerializerImpl {
|
|
|
12803
12878
|
return payload;
|
|
12804
12879
|
}
|
|
12805
12880
|
};
|
|
12806
|
-
__name(_SerializerImpl, "SerializerImpl");
|
|
12807
|
-
var SerializerImpl = _SerializerImpl;
|
|
12808
12881
|
function createSerializer(modelMappers = {}, isXML = false) {
|
|
12809
12882
|
return new SerializerImpl(modelMappers, isXML);
|
|
12810
12883
|
}
|
|
@@ -13029,7 +13102,7 @@ function resolveAdditionalProperties(serializer2, mapper, objectName) {
|
|
|
13029
13102
|
const additionalProperties = mapper.type.additionalProperties;
|
|
13030
13103
|
if (!additionalProperties && mapper.type.className) {
|
|
13031
13104
|
const modelMapper = resolveReferencedMapper(serializer2, mapper, objectName);
|
|
13032
|
-
return modelMapper
|
|
13105
|
+
return modelMapper?.type.additionalProperties;
|
|
13033
13106
|
}
|
|
13034
13107
|
return additionalProperties;
|
|
13035
13108
|
}
|
|
@@ -13049,7 +13122,7 @@ function resolveModelProperties(serializer2, mapper, objectName) {
|
|
|
13049
13122
|
if (!modelMapper) {
|
|
13050
13123
|
throw new Error(`mapper() cannot be null or undefined for model "${mapper.type.className}".`);
|
|
13051
13124
|
}
|
|
13052
|
-
modelProps = modelMapper
|
|
13125
|
+
modelProps = modelMapper?.type.modelProperties;
|
|
13053
13126
|
if (!modelProps) {
|
|
13054
13127
|
throw new Error(`modelProperties cannot be null or undefined in the mapper "${JSON.stringify(modelMapper)}" of type "${mapper.type.className}" for object "${objectName}".`);
|
|
13055
13128
|
}
|
|
@@ -13196,7 +13269,7 @@ function deserializeCompositeType(serializer2, mapper, responseBody, objectName,
|
|
|
13196
13269
|
const propertyName = xmlElementName || xmlName || serializedName;
|
|
13197
13270
|
if (propertyMapper.xmlIsWrapped) {
|
|
13198
13271
|
const wrapped = responseBody[xmlName];
|
|
13199
|
-
const elementList =
|
|
13272
|
+
const elementList = wrapped?.[xmlElementName] ?? [];
|
|
13200
13273
|
instance2[key] = serializer2.deserialize(propertyMapper, elementList, propertyObjectName, options);
|
|
13201
13274
|
handledPropertyNames.push(xmlName);
|
|
13202
13275
|
} else {
|
|
@@ -13458,16 +13531,15 @@ var defaultJsonContentTypes = ["application/json", "text/json"];
|
|
|
13458
13531
|
var defaultXmlContentTypes = ["application/xml", "application/atom+xml"];
|
|
13459
13532
|
var deserializationPolicyName = "deserializationPolicy";
|
|
13460
13533
|
function deserializationPolicy(options = {}) {
|
|
13461
|
-
|
|
13462
|
-
const
|
|
13463
|
-
const xmlContentTypes = ((_b2 = options.expectedContentTypes) == null ? void 0 : _b2.xml) ?? defaultXmlContentTypes;
|
|
13534
|
+
const jsonContentTypes = options.expectedContentTypes?.json ?? defaultJsonContentTypes;
|
|
13535
|
+
const xmlContentTypes = options.expectedContentTypes?.xml ?? defaultXmlContentTypes;
|
|
13464
13536
|
const parseXML = options.parseXML;
|
|
13465
13537
|
const serializerOptions = options.serializerOptions;
|
|
13466
13538
|
const updatedOptions = {
|
|
13467
13539
|
xml: {
|
|
13468
|
-
rootName:
|
|
13469
|
-
includeRoot:
|
|
13470
|
-
xmlCharKey:
|
|
13540
|
+
rootName: serializerOptions?.xml.rootName ?? "",
|
|
13541
|
+
includeRoot: serializerOptions?.xml.includeRoot ?? false,
|
|
13542
|
+
xmlCharKey: serializerOptions?.xml.xmlCharKey ?? XML_CHARKEY
|
|
13471
13543
|
}
|
|
13472
13544
|
};
|
|
13473
13545
|
return {
|
|
@@ -13483,12 +13555,12 @@ function getOperationResponseMap(parsedResponse) {
|
|
|
13483
13555
|
let result;
|
|
13484
13556
|
const request = parsedResponse.request;
|
|
13485
13557
|
const operationInfo = getOperationRequestInfo(request);
|
|
13486
|
-
const operationSpec = operationInfo
|
|
13558
|
+
const operationSpec = operationInfo?.operationSpec;
|
|
13487
13559
|
if (operationSpec) {
|
|
13488
|
-
if (!
|
|
13560
|
+
if (!operationInfo?.operationResponseGetter) {
|
|
13489
13561
|
result = operationSpec.responses[parsedResponse.status];
|
|
13490
13562
|
} else {
|
|
13491
|
-
result = operationInfo
|
|
13563
|
+
result = operationInfo?.operationResponseGetter(operationSpec, parsedResponse);
|
|
13492
13564
|
}
|
|
13493
13565
|
}
|
|
13494
13566
|
return result;
|
|
@@ -13497,7 +13569,7 @@ __name(getOperationResponseMap, "getOperationResponseMap");
|
|
|
13497
13569
|
function shouldDeserializeResponse(parsedResponse) {
|
|
13498
13570
|
const request = parsedResponse.request;
|
|
13499
13571
|
const operationInfo = getOperationRequestInfo(request);
|
|
13500
|
-
const shouldDeserialize = operationInfo
|
|
13572
|
+
const shouldDeserialize = operationInfo?.shouldDeserialize;
|
|
13501
13573
|
let result;
|
|
13502
13574
|
if (shouldDeserialize === void 0) {
|
|
13503
13575
|
result = true;
|
|
@@ -13515,7 +13587,7 @@ async function deserializeResponseBody(jsonContentTypes, xmlContentTypes, respon
|
|
|
13515
13587
|
return parsedResponse;
|
|
13516
13588
|
}
|
|
13517
13589
|
const operationInfo = getOperationRequestInfo(parsedResponse.request);
|
|
13518
|
-
const operationSpec = operationInfo
|
|
13590
|
+
const operationSpec = operationInfo?.operationSpec;
|
|
13519
13591
|
if (!operationSpec || !operationSpec.responses) {
|
|
13520
13592
|
return parsedResponse;
|
|
13521
13593
|
}
|
|
@@ -13558,7 +13630,6 @@ function isOperationSpecEmpty(operationSpec) {
|
|
|
13558
13630
|
}
|
|
13559
13631
|
__name(isOperationSpecEmpty, "isOperationSpecEmpty");
|
|
13560
13632
|
function handleErrorResponse(parsedResponse, operationSpec, responseSpec, options) {
|
|
13561
|
-
var _a3, _b2, _c2, _d, _e;
|
|
13562
13633
|
const isSuccessByStatus = 200 <= parsedResponse.status && parsedResponse.status < 300;
|
|
13563
13634
|
const isExpectedStatusCode = isOperationSpecEmpty(operationSpec) ? isSuccessByStatus : !!responseSpec;
|
|
13564
13635
|
if (isExpectedStatusCode) {
|
|
@@ -13571,17 +13642,17 @@ function handleErrorResponse(parsedResponse, operationSpec, responseSpec, option
|
|
|
13571
13642
|
}
|
|
13572
13643
|
}
|
|
13573
13644
|
const errorResponseSpec = responseSpec ?? operationSpec.responses.default;
|
|
13574
|
-
const initialErrorMessage =
|
|
13645
|
+
const initialErrorMessage = parsedResponse.request.streamResponseStatusCodes?.has(parsedResponse.status) ? `Unexpected status code: ${parsedResponse.status}` : parsedResponse.bodyAsText;
|
|
13575
13646
|
const error = new RestError2(initialErrorMessage, {
|
|
13576
13647
|
statusCode: parsedResponse.status,
|
|
13577
13648
|
request: parsedResponse.request,
|
|
13578
13649
|
response: parsedResponse
|
|
13579
13650
|
});
|
|
13580
|
-
if (!errorResponseSpec && !(
|
|
13651
|
+
if (!errorResponseSpec && !(parsedResponse.parsedBody?.error?.code && parsedResponse.parsedBody?.error?.message)) {
|
|
13581
13652
|
throw error;
|
|
13582
13653
|
}
|
|
13583
|
-
const defaultBodyMapper = errorResponseSpec
|
|
13584
|
-
const defaultHeadersMapper = errorResponseSpec
|
|
13654
|
+
const defaultBodyMapper = errorResponseSpec?.bodyMapper;
|
|
13655
|
+
const defaultHeadersMapper = errorResponseSpec?.headersMapper;
|
|
13585
13656
|
try {
|
|
13586
13657
|
if (parsedResponse.parsedBody) {
|
|
13587
13658
|
const parsedBody = parsedResponse.parsedBody;
|
|
@@ -13616,8 +13687,7 @@ function handleErrorResponse(parsedResponse, operationSpec, responseSpec, option
|
|
|
13616
13687
|
}
|
|
13617
13688
|
__name(handleErrorResponse, "handleErrorResponse");
|
|
13618
13689
|
async function parse(jsonContentTypes, xmlContentTypes, operationResponse, opts, parseXML) {
|
|
13619
|
-
|
|
13620
|
-
if (!((_a3 = operationResponse.request.streamResponseStatusCodes) == null ? void 0 : _a3.has(operationResponse.status)) && operationResponse.bodyAsText) {
|
|
13690
|
+
if (!operationResponse.request.streamResponseStatusCodes?.has(operationResponse.status) && operationResponse.bodyAsText) {
|
|
13621
13691
|
const text = operationResponse.bodyAsText;
|
|
13622
13692
|
const contentType2 = operationResponse.headers.get("Content-Type") || "";
|
|
13623
13693
|
const contentComponents = !contentType2 ? [] : contentType2.split(";").map((component) => component.toLowerCase());
|
|
@@ -13683,8 +13753,8 @@ function serializationPolicy(options = {}) {
|
|
|
13683
13753
|
name: serializationPolicyName,
|
|
13684
13754
|
async sendRequest(request, next) {
|
|
13685
13755
|
const operationInfo = getOperationRequestInfo(request);
|
|
13686
|
-
const operationSpec = operationInfo
|
|
13687
|
-
const operationArguments = operationInfo
|
|
13756
|
+
const operationSpec = operationInfo?.operationSpec;
|
|
13757
|
+
const operationArguments = operationInfo?.operationArguments;
|
|
13688
13758
|
if (operationSpec && operationArguments) {
|
|
13689
13759
|
serializeHeaders(request, operationArguments, operationSpec);
|
|
13690
13760
|
serializeRequestBody(request, operationArguments, operationSpec, stringifyXML);
|
|
@@ -13695,7 +13765,6 @@ function serializationPolicy(options = {}) {
|
|
|
13695
13765
|
}
|
|
13696
13766
|
__name(serializationPolicy, "serializationPolicy");
|
|
13697
13767
|
function serializeHeaders(request, operationArguments, operationSpec) {
|
|
13698
|
-
var _a3, _b2;
|
|
13699
13768
|
if (operationSpec.headerParameters) {
|
|
13700
13769
|
for (const headerParameter of operationSpec.headerParameters) {
|
|
13701
13770
|
let headerValue = getOperationArgumentValueFromParameter(operationArguments, headerParameter);
|
|
@@ -13712,7 +13781,7 @@ function serializeHeaders(request, operationArguments, operationSpec) {
|
|
|
13712
13781
|
}
|
|
13713
13782
|
}
|
|
13714
13783
|
}
|
|
13715
|
-
const customHeaders =
|
|
13784
|
+
const customHeaders = operationArguments.options?.requestOptions?.customHeaders;
|
|
13716
13785
|
if (customHeaders) {
|
|
13717
13786
|
for (const customHeaderName of Object.keys(customHeaders)) {
|
|
13718
13787
|
request.headers.set(customHeaderName, customHeaders[customHeaderName]);
|
|
@@ -13723,13 +13792,12 @@ __name(serializeHeaders, "serializeHeaders");
|
|
|
13723
13792
|
function serializeRequestBody(request, operationArguments, operationSpec, stringifyXML = function() {
|
|
13724
13793
|
throw new Error("XML serialization unsupported!");
|
|
13725
13794
|
}) {
|
|
13726
|
-
|
|
13727
|
-
const serializerOptions = (_a3 = operationArguments.options) == null ? void 0 : _a3.serializerOptions;
|
|
13795
|
+
const serializerOptions = operationArguments.options?.serializerOptions;
|
|
13728
13796
|
const updatedOptions = {
|
|
13729
13797
|
xml: {
|
|
13730
|
-
rootName:
|
|
13731
|
-
includeRoot:
|
|
13732
|
-
xmlCharKey:
|
|
13798
|
+
rootName: serializerOptions?.xml.rootName ?? "",
|
|
13799
|
+
includeRoot: serializerOptions?.xml.includeRoot ?? false,
|
|
13800
|
+
xmlCharKey: serializerOptions?.xml.xmlCharKey ?? XML_CHARKEY
|
|
13733
13801
|
}
|
|
13734
13802
|
};
|
|
13735
13803
|
const xmlCharKey = updatedOptions.xml.xmlCharKey;
|
|
@@ -13754,7 +13822,7 @@ function serializeRequestBody(request, operationArguments, operationSpec, string
|
|
|
13754
13822
|
xmlCharKey
|
|
13755
13823
|
});
|
|
13756
13824
|
}
|
|
13757
|
-
} else if (typeName === MapperTypeNames.String && (
|
|
13825
|
+
} else if (typeName === MapperTypeNames.String && (operationSpec.contentType?.match("text/plain") || operationSpec.mediaType === "text")) {
|
|
13758
13826
|
return;
|
|
13759
13827
|
} else if (!isStream) {
|
|
13760
13828
|
request.body = JSON.stringify(request.body);
|
|
@@ -13863,9 +13931,8 @@ function replaceAll(input, replacements) {
|
|
|
13863
13931
|
}
|
|
13864
13932
|
__name(replaceAll, "replaceAll");
|
|
13865
13933
|
function calculateUrlReplacements(operationSpec, operationArguments, fallbackObject) {
|
|
13866
|
-
var _a3;
|
|
13867
13934
|
const result = /* @__PURE__ */ new Map();
|
|
13868
|
-
if (
|
|
13935
|
+
if (operationSpec.urlParameters?.length) {
|
|
13869
13936
|
for (const urlParameter of operationSpec.urlParameters) {
|
|
13870
13937
|
let urlParameterValue = getOperationArgumentValueFromParameter(operationArguments, urlParameter, fallbackObject);
|
|
13871
13938
|
const parameterPathString = getPathStringFromParameter(urlParameter);
|
|
@@ -13911,10 +13978,9 @@ function appendPath(url2, pathToAppend) {
|
|
|
13911
13978
|
}
|
|
13912
13979
|
__name(appendPath, "appendPath");
|
|
13913
13980
|
function calculateQueryParameters(operationSpec, operationArguments, fallbackObject) {
|
|
13914
|
-
var _a3;
|
|
13915
13981
|
const result = /* @__PURE__ */ new Map();
|
|
13916
13982
|
const sequenceParams = /* @__PURE__ */ new Set();
|
|
13917
|
-
if (
|
|
13983
|
+
if (operationSpec.queryParameters?.length) {
|
|
13918
13984
|
for (const queryParameter of operationSpec.queryParameters) {
|
|
13919
13985
|
if (queryParameter.mapper.type.name === "Sequence" && queryParameter.mapper.serializedName) {
|
|
13920
13986
|
sequenceParams.add(queryParameter.mapper.serializedName);
|
|
@@ -14031,7 +14097,10 @@ __name(appendQueryParams, "appendQueryParams");
|
|
|
14031
14097
|
var logger3 = createClientLogger2("core-client");
|
|
14032
14098
|
|
|
14033
14099
|
// ../../node_modules/.store/@azure-core-client-npm-1.10.1-c6f6d34e9a/package/dist/esm/serviceClient.js
|
|
14034
|
-
var
|
|
14100
|
+
var ServiceClient = class {
|
|
14101
|
+
static {
|
|
14102
|
+
__name(this, "ServiceClient");
|
|
14103
|
+
}
|
|
14035
14104
|
/**
|
|
14036
14105
|
* If specified, this is the base URI that requests will be made against for this ServiceClient.
|
|
14037
14106
|
* If it is not specified, then all OperationSpecs must contain a baseUrl property.
|
|
@@ -14059,7 +14128,6 @@ var _ServiceClient = class _ServiceClient {
|
|
|
14059
14128
|
* @param options - The service client options that govern the behavior of the client.
|
|
14060
14129
|
*/
|
|
14061
14130
|
constructor(options = {}) {
|
|
14062
|
-
var _a3;
|
|
14063
14131
|
this._requestContentType = options.requestContentType;
|
|
14064
14132
|
this._endpoint = options.endpoint ?? options.baseUri;
|
|
14065
14133
|
if (options.baseUri) {
|
|
@@ -14068,7 +14136,7 @@ var _ServiceClient = class _ServiceClient {
|
|
|
14068
14136
|
this._allowInsecureConnection = options.allowInsecureConnection;
|
|
14069
14137
|
this._httpClient = options.httpClient || getCachedDefaultHttpClient();
|
|
14070
14138
|
this.pipeline = options.pipeline || createDefaultPipeline2(options);
|
|
14071
|
-
if (
|
|
14139
|
+
if (options.additionalPolicies?.length) {
|
|
14072
14140
|
for (const { policy, position } of options.additionalPolicies) {
|
|
14073
14141
|
const afterPhase = position === "perRetry" ? "Sign" : void 0;
|
|
14074
14142
|
this.pipeline.addPolicy(policy, {
|
|
@@ -14142,16 +14210,16 @@ var _ServiceClient = class _ServiceClient {
|
|
|
14142
14210
|
try {
|
|
14143
14211
|
const rawResponse = await this.sendRequest(request);
|
|
14144
14212
|
const flatResponse = flattenResponse(rawResponse, operationSpec.responses[rawResponse.status]);
|
|
14145
|
-
if (options
|
|
14213
|
+
if (options?.onResponse) {
|
|
14146
14214
|
options.onResponse(rawResponse, flatResponse);
|
|
14147
14215
|
}
|
|
14148
14216
|
return flatResponse;
|
|
14149
14217
|
} catch (error) {
|
|
14150
|
-
if (typeof error === "object" &&
|
|
14218
|
+
if (typeof error === "object" && error?.response) {
|
|
14151
14219
|
const rawResponse = error.response;
|
|
14152
14220
|
const flatResponse = flattenResponse(rawResponse, operationSpec.responses[error.statusCode] || operationSpec.responses["default"]);
|
|
14153
14221
|
error.details = flatResponse;
|
|
14154
|
-
if (options
|
|
14222
|
+
if (options?.onResponse) {
|
|
14155
14223
|
options.onResponse(rawResponse, flatResponse, error);
|
|
14156
14224
|
}
|
|
14157
14225
|
}
|
|
@@ -14159,8 +14227,6 @@ var _ServiceClient = class _ServiceClient {
|
|
|
14159
14227
|
}
|
|
14160
14228
|
}
|
|
14161
14229
|
};
|
|
14162
|
-
__name(_ServiceClient, "ServiceClient");
|
|
14163
|
-
var ServiceClient = _ServiceClient;
|
|
14164
14230
|
function createDefaultPipeline2(options) {
|
|
14165
14231
|
const credentialScopes = getCredentialScopes(options);
|
|
14166
14232
|
const credentialOptions = options.credential && credentialScopes ? { credentialScopes, credential: options.credential } : void 0;
|
|
@@ -15175,7 +15241,10 @@ var RequestData = {
|
|
|
15175
15241
|
};
|
|
15176
15242
|
|
|
15177
15243
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/generated/applicationInsightsClient.js
|
|
15178
|
-
var
|
|
15244
|
+
var ApplicationInsightsClient = class extends ServiceClient {
|
|
15245
|
+
static {
|
|
15246
|
+
__name(this, "ApplicationInsightsClient");
|
|
15247
|
+
}
|
|
15179
15248
|
host;
|
|
15180
15249
|
/**
|
|
15181
15250
|
* Initializes a new instance of the ApplicationInsightsClient class.
|
|
@@ -15210,8 +15279,6 @@ var _ApplicationInsightsClient = class _ApplicationInsightsClient extends Servic
|
|
|
15210
15279
|
return this.sendOperationRequest({ body: body2, options }, trackOperationSpec);
|
|
15211
15280
|
}
|
|
15212
15281
|
};
|
|
15213
|
-
__name(_ApplicationInsightsClient, "ApplicationInsightsClient");
|
|
15214
|
-
var ApplicationInsightsClient = _ApplicationInsightsClient;
|
|
15215
15282
|
var serializer = createSerializer(
|
|
15216
15283
|
mappers_exports,
|
|
15217
15284
|
/* isXml */
|
|
@@ -15259,7 +15326,10 @@ var trackOperationSpec = {
|
|
|
15259
15326
|
init_esm();
|
|
15260
15327
|
|
|
15261
15328
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/export/statsbeat/types.js
|
|
15262
|
-
var
|
|
15329
|
+
var NetworkStatsbeat = class {
|
|
15330
|
+
static {
|
|
15331
|
+
__name(this, "NetworkStatsbeat");
|
|
15332
|
+
}
|
|
15263
15333
|
time;
|
|
15264
15334
|
lastTime;
|
|
15265
15335
|
endpoint;
|
|
@@ -15294,9 +15364,10 @@ var _NetworkStatsbeat = class _NetworkStatsbeat {
|
|
|
15294
15364
|
this.averageRequestExecutionTime = 0;
|
|
15295
15365
|
}
|
|
15296
15366
|
};
|
|
15297
|
-
|
|
15298
|
-
|
|
15299
|
-
|
|
15367
|
+
var CustomerSDKStats = class {
|
|
15368
|
+
static {
|
|
15369
|
+
__name(this, "CustomerSDKStats");
|
|
15370
|
+
}
|
|
15300
15371
|
totalItemSuccessCount;
|
|
15301
15372
|
// telemetry_type -> drop.code -> drop.reason -> success -> count
|
|
15302
15373
|
// success can be true/false for request/dependency telemetry, or null for other types
|
|
@@ -15309,8 +15380,6 @@ var _CustomerSDKStats = class _CustomerSDKStats {
|
|
|
15309
15380
|
this.totalItemRetryCount = /* @__PURE__ */ new Map();
|
|
15310
15381
|
}
|
|
15311
15382
|
};
|
|
15312
|
-
__name(_CustomerSDKStats, "CustomerSDKStats");
|
|
15313
|
-
var CustomerSDKStats = _CustomerSDKStats;
|
|
15314
15383
|
var STATSBEAT_LANGUAGE = "node";
|
|
15315
15384
|
var AZURE_MONITOR_AUTO_ATTACH = "AZURE_MONITOR_AUTO_ATTACH";
|
|
15316
15385
|
var MAX_STATSBEAT_FAILURES = 3;
|
|
@@ -15434,7 +15503,17 @@ import { existsSync } from "node:fs";
|
|
|
15434
15503
|
import { type as osType } from "node:os";
|
|
15435
15504
|
import { spawn, spawnSync } from "node:child_process";
|
|
15436
15505
|
import process4 from "node:process";
|
|
15437
|
-
var
|
|
15506
|
+
var FileAccessControl = class _FileAccessControl {
|
|
15507
|
+
static {
|
|
15508
|
+
__name(this, "FileAccessControl");
|
|
15509
|
+
}
|
|
15510
|
+
static ICACLS_PATH = `${process4.env.SYSTEMDRIVE}/windows/system32/icacls.exe`;
|
|
15511
|
+
static POWERSHELL_PATH = `${process4.env.SYSTEMDRIVE}/windows/system32/windowspowershell/v1.0/powershell.exe`;
|
|
15512
|
+
static ACLED_DIRECTORIES = {};
|
|
15513
|
+
static ACL_IDENTITY = null;
|
|
15514
|
+
static OS_FILE_PROTECTION_CHECKED = false;
|
|
15515
|
+
static OS_PROVIDES_FILE_PROTECTION = false;
|
|
15516
|
+
static USE_ICACLS = osType() === "Windows_NT";
|
|
15438
15517
|
// Check if file access control could be enabled
|
|
15439
15518
|
static checkFileProtection() {
|
|
15440
15519
|
if (!_FileAccessControl.OS_PROVIDES_FILE_PROTECTION && !_FileAccessControl.OS_FILE_PROTECTION_CHECKED) {
|
|
@@ -15568,15 +15647,6 @@ var _FileAccessControl = class _FileAccessControl {
|
|
|
15568
15647
|
];
|
|
15569
15648
|
}
|
|
15570
15649
|
};
|
|
15571
|
-
__name(_FileAccessControl, "FileAccessControl");
|
|
15572
|
-
__publicField(_FileAccessControl, "ICACLS_PATH", `${process4.env.SYSTEMDRIVE}/windows/system32/icacls.exe`);
|
|
15573
|
-
__publicField(_FileAccessControl, "POWERSHELL_PATH", `${process4.env.SYSTEMDRIVE}/windows/system32/windowspowershell/v1.0/powershell.exe`);
|
|
15574
|
-
__publicField(_FileAccessControl, "ACLED_DIRECTORIES", {});
|
|
15575
|
-
__publicField(_FileAccessControl, "ACL_IDENTITY", null);
|
|
15576
|
-
__publicField(_FileAccessControl, "OS_FILE_PROTECTION_CHECKED", false);
|
|
15577
|
-
__publicField(_FileAccessControl, "OS_PROVIDES_FILE_PROTECTION", false);
|
|
15578
|
-
__publicField(_FileAccessControl, "USE_ICACLS", osType() === "Windows_NT");
|
|
15579
|
-
var FileAccessControl = _FileAccessControl;
|
|
15580
15650
|
|
|
15581
15651
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/platform/nodejs/persist/fileSystemHelpers.js
|
|
15582
15652
|
init_esm();
|
|
@@ -15628,9 +15698,14 @@ var confirmDirExists = /* @__PURE__ */ __name(async (directory) => {
|
|
|
15628
15698
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/platform/nodejs/persist/fileSystemPersist.js
|
|
15629
15699
|
import { constants as fsConstants } from "node:fs";
|
|
15630
15700
|
import { open, readdir as readdir2, readFile, stat as stat2, unlink } from "node:fs/promises";
|
|
15631
|
-
var
|
|
15701
|
+
var FileSystemPersist = class _FileSystemPersist {
|
|
15702
|
+
static {
|
|
15703
|
+
__name(this, "FileSystemPersist");
|
|
15704
|
+
}
|
|
15632
15705
|
_options;
|
|
15633
15706
|
_customerSDKStatsMetrics;
|
|
15707
|
+
static TEMPDIR_PREFIX = "opentelemetry-nodejs-";
|
|
15708
|
+
static FILENAME_SUFFIX = ".ai.json";
|
|
15634
15709
|
fileRetemptionPeriod = 2 * 24 * 60 * 60 * 1e3;
|
|
15635
15710
|
// 2 days
|
|
15636
15711
|
cleanupTimeOut = 60 * 60 * 1e3;
|
|
@@ -15642,11 +15717,10 @@ var _FileSystemPersist = class _FileSystemPersist {
|
|
|
15642
15717
|
_fileCleanupTimer = null;
|
|
15643
15718
|
_instrumentationKey;
|
|
15644
15719
|
constructor(instrumentationKey, _options, _customerSDKStatsMetrics) {
|
|
15645
|
-
var _a3, _b2;
|
|
15646
15720
|
this._options = _options;
|
|
15647
15721
|
this._customerSDKStatsMetrics = _customerSDKStatsMetrics;
|
|
15648
15722
|
this._instrumentationKey = instrumentationKey;
|
|
15649
|
-
if (
|
|
15723
|
+
if (this._options?.disableOfflineStorage) {
|
|
15650
15724
|
this._enabled = false;
|
|
15651
15725
|
return;
|
|
15652
15726
|
}
|
|
@@ -15661,7 +15735,7 @@ var _FileSystemPersist = class _FileSystemPersist {
|
|
|
15661
15735
|
diag.error(`No instrumentation key was provided to FileSystemPersister. Files will not be persisted`);
|
|
15662
15736
|
}
|
|
15663
15737
|
if (this._enabled) {
|
|
15664
|
-
this._tempDirectory = getStorageDirectory(this._instrumentationKey,
|
|
15738
|
+
this._tempDirectory = getStorageDirectory(this._instrumentationKey, this._options?.storageDirectory);
|
|
15665
15739
|
if (!this._fileCleanupTimer) {
|
|
15666
15740
|
this._fileCleanupTimer = setTimeout(() => {
|
|
15667
15741
|
this._fileCleanupTask();
|
|
@@ -15671,12 +15745,11 @@ var _FileSystemPersist = class _FileSystemPersist {
|
|
|
15671
15745
|
}
|
|
15672
15746
|
}
|
|
15673
15747
|
push(value) {
|
|
15674
|
-
var _a3;
|
|
15675
15748
|
if (this._enabled) {
|
|
15676
15749
|
diag.debug("Pushing value to persistent storage", value.toString());
|
|
15677
15750
|
return this._storeToDisk(JSON.stringify(value), value);
|
|
15678
15751
|
}
|
|
15679
|
-
if (!
|
|
15752
|
+
if (!this._options?.disableOfflineStorage) {
|
|
15680
15753
|
return new Promise((resolve) => {
|
|
15681
15754
|
resolve(false);
|
|
15682
15755
|
});
|
|
@@ -15738,13 +15811,12 @@ var _FileSystemPersist = class _FileSystemPersist {
|
|
|
15738
15811
|
* @returns A promise that resolves to true if the data was stored successfully, false otherwise.
|
|
15739
15812
|
*/
|
|
15740
15813
|
async _storeToDisk(payload, envelopes) {
|
|
15741
|
-
var _a3, _b2, _c2;
|
|
15742
15814
|
try {
|
|
15743
15815
|
await confirmDirExists(this._tempDirectory);
|
|
15744
15816
|
} catch (error) {
|
|
15745
|
-
if (
|
|
15746
|
-
|
|
15747
|
-
diag.warn(`Permission denied while checking/creating directory: ${this._tempDirectory}`, error
|
|
15817
|
+
if (error?.code === "EACCES" || error?.code === "EPERM") {
|
|
15818
|
+
this._customerSDKStatsMetrics?.countDroppedItems(envelopes, DropCode.CLIENT_READONLY);
|
|
15819
|
+
diag.warn(`Permission denied while checking/creating directory: ${this._tempDirectory}`, error?.message);
|
|
15748
15820
|
} else {
|
|
15749
15821
|
diag.warn(`Error while checking/creating directory: `, error && error.message);
|
|
15750
15822
|
}
|
|
@@ -15753,7 +15825,7 @@ var _FileSystemPersist = class _FileSystemPersist {
|
|
|
15753
15825
|
try {
|
|
15754
15826
|
const size = await getShallowDirectorySize(this._tempDirectory);
|
|
15755
15827
|
if (size > this.maxBytesOnDisk) {
|
|
15756
|
-
|
|
15828
|
+
this._customerSDKStatsMetrics?.countDroppedItems(envelopes, DropCode.CLIENT_PERSISTENCE_CAPACITY);
|
|
15757
15829
|
diag.warn(`Not saving data due to max size limit being met. Directory size in bytes is: ${size}`);
|
|
15758
15830
|
return false;
|
|
15759
15831
|
}
|
|
@@ -15772,7 +15844,7 @@ var _FileSystemPersist = class _FileSystemPersist {
|
|
|
15772
15844
|
await handle.close();
|
|
15773
15845
|
}
|
|
15774
15846
|
} catch (writeError) {
|
|
15775
|
-
|
|
15847
|
+
this._customerSDKStatsMetrics?.countDroppedItems(envelopes, DropCode.CLIENT_EXCEPTION, writeError?.message, ExceptionType.STORAGE_EXCEPTION);
|
|
15776
15848
|
diag.warn(`Error writing file to persistent file storage`, writeError);
|
|
15777
15849
|
return false;
|
|
15778
15850
|
}
|
|
@@ -15805,10 +15877,6 @@ var _FileSystemPersist = class _FileSystemPersist {
|
|
|
15805
15877
|
}
|
|
15806
15878
|
}
|
|
15807
15879
|
};
|
|
15808
|
-
__name(_FileSystemPersist, "FileSystemPersist");
|
|
15809
|
-
__publicField(_FileSystemPersist, "TEMPDIR_PREFIX", "opentelemetry-nodejs-");
|
|
15810
|
-
__publicField(_FileSystemPersist, "FILENAME_SUFFIX", ".ai.json");
|
|
15811
|
-
var FileSystemPersist = _FileSystemPersist;
|
|
15812
15880
|
function getStorageDirectory(instrumentationKey, storageDirectory) {
|
|
15813
15881
|
let userSegment;
|
|
15814
15882
|
let processName;
|
|
@@ -15880,7 +15948,10 @@ var MicrosoftClientIp = "microsoft.client.ip";
|
|
|
15880
15948
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/export/statsbeat/statsbeatMetrics.js
|
|
15881
15949
|
init_esm();
|
|
15882
15950
|
import os2 from "node:os";
|
|
15883
|
-
var
|
|
15951
|
+
var StatsbeatMetrics = class {
|
|
15952
|
+
static {
|
|
15953
|
+
__name(this, "StatsbeatMetrics");
|
|
15954
|
+
}
|
|
15884
15955
|
resourceProvider = StatsbeatResourceProvider.unknown;
|
|
15885
15956
|
vmInfo = {};
|
|
15886
15957
|
os = os2.type();
|
|
@@ -15958,8 +16029,6 @@ var _StatsbeatMetrics = class _StatsbeatMetrics {
|
|
|
15958
16029
|
return NON_EU_CONNECTION_STRING;
|
|
15959
16030
|
}
|
|
15960
16031
|
};
|
|
15961
|
-
__name(_StatsbeatMetrics, "StatsbeatMetrics");
|
|
15962
|
-
var StatsbeatMetrics = _StatsbeatMetrics;
|
|
15963
16032
|
|
|
15964
16033
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/export/statsbeat/statsbeatExporter.js
|
|
15965
16034
|
init_esm();
|
|
@@ -16140,8 +16209,14 @@ var PerformanceToQuickPulseCounter = {
|
|
|
16140
16209
|
|
|
16141
16210
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/platform/nodejs/context/context.js
|
|
16142
16211
|
var instance = null;
|
|
16143
|
-
var
|
|
16212
|
+
var Context = class _Context {
|
|
16213
|
+
static {
|
|
16214
|
+
__name(this, "Context");
|
|
16215
|
+
}
|
|
16144
16216
|
tags;
|
|
16217
|
+
static sdkVersion = null;
|
|
16218
|
+
static opentelemetryVersion = null;
|
|
16219
|
+
static nodeVersion = "";
|
|
16145
16220
|
constructor() {
|
|
16146
16221
|
this.tags = {};
|
|
16147
16222
|
this._loadInternalContext();
|
|
@@ -16166,11 +16241,6 @@ var _Context = class _Context {
|
|
|
16166
16241
|
}
|
|
16167
16242
|
}
|
|
16168
16243
|
};
|
|
16169
|
-
__name(_Context, "Context");
|
|
16170
|
-
__publicField(_Context, "sdkVersion", null);
|
|
16171
|
-
__publicField(_Context, "opentelemetryVersion", null);
|
|
16172
|
-
__publicField(_Context, "nodeVersion", "");
|
|
16173
|
-
var Context = _Context;
|
|
16174
16244
|
function getInstance() {
|
|
16175
16245
|
if (!instance) {
|
|
16176
16246
|
instance = new Context();
|
|
@@ -16203,7 +16273,7 @@ var getTimeSinceEnqueued = /* @__PURE__ */ __name((span) => {
|
|
|
16203
16273
|
let sumEnqueueDiffs = 0;
|
|
16204
16274
|
const startTimeMs = (0, import_core2.hrTimeToMilliseconds)(span.startTime);
|
|
16205
16275
|
span.links.forEach(({ attributes }) => {
|
|
16206
|
-
const enqueuedTime = attributes
|
|
16276
|
+
const enqueuedTime = attributes?.[ENQUEUED_TIME];
|
|
16207
16277
|
if (enqueuedTime) {
|
|
16208
16278
|
countEnqueueDiffs += 1;
|
|
16209
16279
|
sumEnqueueDiffs += startTimeMs - (parseFloat(enqueuedTime.toString()) || 0);
|
|
@@ -16272,10 +16342,9 @@ __name(msToTimeSpan, "msToTimeSpan");
|
|
|
16272
16342
|
|
|
16273
16343
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/utils/spanUtils.js
|
|
16274
16344
|
function createTagsFromSpan(span) {
|
|
16275
|
-
var _a3;
|
|
16276
16345
|
const tags = createTagsFromResource(span.resource);
|
|
16277
16346
|
tags[KnownContextTagKeys.AiOperationId] = span.spanContext().traceId;
|
|
16278
|
-
if (
|
|
16347
|
+
if (span.parentSpanContext?.spanId) {
|
|
16279
16348
|
tags[KnownContextTagKeys.AiOperationParentId] = span.parentSpanContext.spanId;
|
|
16280
16349
|
}
|
|
16281
16350
|
const endUserId = span.attributes[experimentalOpenTelemetryValues.ATTR_ENDUSER_ID];
|
|
@@ -16355,12 +16424,11 @@ function createPropertiesFromSpan(span) {
|
|
|
16355
16424
|
}
|
|
16356
16425
|
__name(createPropertiesFromSpan, "createPropertiesFromSpan");
|
|
16357
16426
|
function createDependencyData(span) {
|
|
16358
|
-
var _a3;
|
|
16359
16427
|
const remoteDependencyData = {
|
|
16360
16428
|
name: span.name,
|
|
16361
16429
|
// Default
|
|
16362
16430
|
id: `${span.spanContext().spanId}`,
|
|
16363
|
-
success:
|
|
16431
|
+
success: span.status?.code !== SpanStatusCode.ERROR,
|
|
16364
16432
|
resultCode: "0",
|
|
16365
16433
|
type: "Dependency",
|
|
16366
16434
|
duration: msToTimeSpan((0, import_core3.hrTimeToMilliseconds)(span.duration)),
|
|
@@ -16740,7 +16808,7 @@ __name(hrTimeToDate, "hrTimeToDate");
|
|
|
16740
16808
|
function createTagsFromResource(resource) {
|
|
16741
16809
|
const context4 = getInstance();
|
|
16742
16810
|
const tags = { ...context4.tags };
|
|
16743
|
-
const attributes = resource
|
|
16811
|
+
const attributes = resource?.attributes;
|
|
16744
16812
|
if (attributes) {
|
|
16745
16813
|
tags[KnownContextTagKeys.AiCloudRole] = getCloudRole(resource);
|
|
16746
16814
|
tags[KnownContextTagKeys.AiCloudRoleInstance] = getCloudRoleInstance(resource);
|
|
@@ -16938,8 +17006,7 @@ function serializeAttribute(value) {
|
|
|
16938
17006
|
}
|
|
16939
17007
|
__name(serializeAttribute, "serializeAttribute");
|
|
16940
17008
|
function shouldCreateResourceMetric() {
|
|
16941
|
-
|
|
16942
|
-
return !(((_a3 = process.env[ENV_OPENTELEMETRY_RESOURCE_METRIC_DISABLED]) == null ? void 0 : _a3.toLowerCase()) === "true");
|
|
17009
|
+
return !(process.env[ENV_OPENTELEMETRY_RESOURCE_METRIC_DISABLED]?.toLowerCase() === "true");
|
|
16943
17010
|
}
|
|
16944
17011
|
__name(shouldCreateResourceMetric, "shouldCreateResourceMetric");
|
|
16945
17012
|
function isSyntheticSource(attributes) {
|
|
@@ -17051,13 +17118,11 @@ function isAksAttach() {
|
|
|
17051
17118
|
}
|
|
17052
17119
|
__name(isAksAttach, "isAksAttach");
|
|
17053
17120
|
function shouldSendToOtlp() {
|
|
17054
|
-
|
|
17055
|
-
return !!(process.env[ENV_OTLP_METRICS_ENDPOINT] && ((_a3 = process.env[ENV_OTEL_METRICS_EXPORTER]) == null ? void 0 : _a3.includes("otlp")));
|
|
17121
|
+
return !!(process.env[ENV_OTLP_METRICS_ENDPOINT] && process.env[ENV_OTEL_METRICS_EXPORTER]?.includes("otlp"));
|
|
17056
17122
|
}
|
|
17057
17123
|
__name(shouldSendToOtlp, "shouldSendToOtlp");
|
|
17058
17124
|
function isStandardMetric(dataPoint) {
|
|
17059
|
-
|
|
17060
|
-
return ((_a3 = dataPoint.attributes) == null ? void 0 : _a3["_MS.IsAutocollected"]) === "True";
|
|
17125
|
+
return dataPoint.attributes?.["_MS.IsAutocollected"] === "True";
|
|
17061
17126
|
}
|
|
17062
17127
|
__name(isStandardMetric, "isStandardMetric");
|
|
17063
17128
|
function getAttachType() {
|
|
@@ -17073,7 +17138,12 @@ init_esm();
|
|
|
17073
17138
|
|
|
17074
17139
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/utils/connectionStringParser.js
|
|
17075
17140
|
init_esm();
|
|
17076
|
-
var
|
|
17141
|
+
var ConnectionStringParser = class _ConnectionStringParser {
|
|
17142
|
+
static {
|
|
17143
|
+
__name(this, "ConnectionStringParser");
|
|
17144
|
+
}
|
|
17145
|
+
static FIELDS_SEPARATOR = ";";
|
|
17146
|
+
static FIELD_KEY_VALUE_SEPARATOR = "=";
|
|
17077
17147
|
static parse(connectionString) {
|
|
17078
17148
|
if (!connectionString) {
|
|
17079
17149
|
return {};
|
|
@@ -17128,13 +17198,12 @@ var _ConnectionStringParser = class _ConnectionStringParser {
|
|
|
17128
17198
|
return regexp.test(iKey);
|
|
17129
17199
|
}
|
|
17130
17200
|
};
|
|
17131
|
-
__name(_ConnectionStringParser, "ConnectionStringParser");
|
|
17132
|
-
__publicField(_ConnectionStringParser, "FIELDS_SEPARATOR", ";");
|
|
17133
|
-
__publicField(_ConnectionStringParser, "FIELD_KEY_VALUE_SEPARATOR", "=");
|
|
17134
|
-
var ConnectionStringParser = _ConnectionStringParser;
|
|
17135
17201
|
|
|
17136
17202
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/export/base.js
|
|
17137
|
-
var
|
|
17203
|
+
var AzureMonitorBaseExporter = class {
|
|
17204
|
+
static {
|
|
17205
|
+
__name(this, "AzureMonitorBaseExporter");
|
|
17206
|
+
}
|
|
17138
17207
|
/**
|
|
17139
17208
|
* Instrumentation key to be used for exported envelopes
|
|
17140
17209
|
*/
|
|
@@ -17164,7 +17233,6 @@ var _AzureMonitorBaseExporter = class _AzureMonitorBaseExporter {
|
|
|
17164
17233
|
* @param AzureMonitorExporterOptions - Exporter configuration.
|
|
17165
17234
|
*/
|
|
17166
17235
|
constructor(options = {}, isStatsbeatExporter) {
|
|
17167
|
-
var _a3;
|
|
17168
17236
|
this.options = options;
|
|
17169
17237
|
this.instrumentationKey = "";
|
|
17170
17238
|
this.endpointUrl = DEFAULT_BREEZE_ENDPOINT;
|
|
@@ -17173,7 +17241,7 @@ var _AzureMonitorBaseExporter = class _AzureMonitorBaseExporter {
|
|
|
17173
17241
|
if (connectionString) {
|
|
17174
17242
|
const parsedConnectionString = ConnectionStringParser.parse(connectionString);
|
|
17175
17243
|
this.instrumentationKey = parsedConnectionString.instrumentationkey || this.instrumentationKey;
|
|
17176
|
-
this.endpointUrl =
|
|
17244
|
+
this.endpointUrl = parsedConnectionString.ingestionendpoint?.trim() || this.endpointUrl;
|
|
17177
17245
|
this.aadAudience = parsedConnectionString.aadaudience;
|
|
17178
17246
|
}
|
|
17179
17247
|
if (!this.instrumentationKey) {
|
|
@@ -17190,11 +17258,12 @@ var _AzureMonitorBaseExporter = class _AzureMonitorBaseExporter {
|
|
|
17190
17258
|
diag.debug("AzureMonitorExporter was successfully setup");
|
|
17191
17259
|
}
|
|
17192
17260
|
};
|
|
17193
|
-
__name(_AzureMonitorBaseExporter, "AzureMonitorBaseExporter");
|
|
17194
|
-
var AzureMonitorBaseExporter = _AzureMonitorBaseExporter;
|
|
17195
17261
|
|
|
17196
17262
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/export/statsbeat/statsbeatExporter.js
|
|
17197
|
-
var
|
|
17263
|
+
var AzureMonitorStatsbeatExporter = class extends AzureMonitorBaseExporter {
|
|
17264
|
+
static {
|
|
17265
|
+
__name(this, "AzureMonitorStatsbeatExporter");
|
|
17266
|
+
}
|
|
17198
17267
|
/**
|
|
17199
17268
|
* Flag to determine if the Exporter is shutdown.
|
|
17200
17269
|
*/
|
|
@@ -17220,7 +17289,7 @@ var _AzureMonitorStatsbeatExporter = class _AzureMonitorStatsbeatExporter extend
|
|
|
17220
17289
|
*/
|
|
17221
17290
|
async _getSender() {
|
|
17222
17291
|
if (!this._sender) {
|
|
17223
|
-
const { HttpSender: HttpSender2 } = await import("./httpSender-
|
|
17292
|
+
const { HttpSender: HttpSender2 } = await import("./httpSender-LVAQHMJ5.js");
|
|
17224
17293
|
this._sender = new HttpSender2(this._senderOptions);
|
|
17225
17294
|
}
|
|
17226
17295
|
return this._sender;
|
|
@@ -17233,8 +17302,7 @@ var _AzureMonitorStatsbeatExporter = class _AzureMonitorStatsbeatExporter extend
|
|
|
17233
17302
|
*/
|
|
17234
17303
|
filterZeroValueMetrics(envelopes) {
|
|
17235
17304
|
return envelopes.filter((envelope) => {
|
|
17236
|
-
|
|
17237
|
-
if (((_a3 = envelope.data) == null ? void 0 : _a3.baseType) === "MetricData" && ((_c2 = (_b2 = envelope.data) == null ? void 0 : _b2.baseData) == null ? void 0 : _c2.metrics)) {
|
|
17305
|
+
if (envelope.data?.baseType === "MetricData" && envelope.data?.baseData?.metrics) {
|
|
17238
17306
|
const metrics = envelope.data.baseData.metrics;
|
|
17239
17307
|
return metrics.some((metric) => metric.value !== 0);
|
|
17240
17308
|
}
|
|
@@ -17272,11 +17340,13 @@ var _AzureMonitorStatsbeatExporter = class _AzureMonitorStatsbeatExporter extend
|
|
|
17272
17340
|
return Promise.resolve();
|
|
17273
17341
|
}
|
|
17274
17342
|
};
|
|
17275
|
-
__name(_AzureMonitorStatsbeatExporter, "AzureMonitorStatsbeatExporter");
|
|
17276
|
-
var AzureMonitorStatsbeatExporter = _AzureMonitorStatsbeatExporter;
|
|
17277
17343
|
|
|
17278
17344
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/export/statsbeat/networkStatsbeatMetrics.js
|
|
17279
|
-
var
|
|
17345
|
+
var NetworkStatsbeatMetrics = class _NetworkStatsbeatMetrics extends StatsbeatMetrics {
|
|
17346
|
+
static {
|
|
17347
|
+
__name(this, "NetworkStatsbeatMetrics");
|
|
17348
|
+
}
|
|
17349
|
+
static instance = null;
|
|
17280
17350
|
disableNonEssentialStatsbeat = !!process.env[ENV_DISABLE_STATSBEAT];
|
|
17281
17351
|
commonProperties;
|
|
17282
17352
|
networkProperties;
|
|
@@ -17359,7 +17429,6 @@ var _NetworkStatsbeatMetrics = class _NetworkStatsbeatMetrics extends StatsbeatM
|
|
|
17359
17429
|
return this.networkStatsbeatMeterProvider.shutdown();
|
|
17360
17430
|
}
|
|
17361
17431
|
async initialize() {
|
|
17362
|
-
var _a3, _b2;
|
|
17363
17432
|
try {
|
|
17364
17433
|
await super.getResourceProvider();
|
|
17365
17434
|
this.successCountGauge.addCallback(this.successCallback.bind(this));
|
|
@@ -17376,8 +17445,8 @@ var _NetworkStatsbeatMetrics = class _NetworkStatsbeatMetrics extends StatsbeatM
|
|
|
17376
17445
|
this.exceptionCountGauge
|
|
17377
17446
|
]);
|
|
17378
17447
|
if (!this.disableNonEssentialStatsbeat) {
|
|
17379
|
-
|
|
17380
|
-
|
|
17448
|
+
this.readFailureGauge?.addCallback(this.readFailureCallback.bind(this));
|
|
17449
|
+
this.writeFailureGauge?.addCallback(this.writeFailureCallback.bind(this));
|
|
17381
17450
|
}
|
|
17382
17451
|
this.averageDurationGauge.addCallback(this.durationCallback.bind(this));
|
|
17383
17452
|
} catch (error) {
|
|
@@ -17592,15 +17661,16 @@ var _NetworkStatsbeatMetrics = class _NetworkStatsbeatMetrics extends StatsbeatM
|
|
|
17592
17661
|
return _NetworkStatsbeatMetrics.instance;
|
|
17593
17662
|
}
|
|
17594
17663
|
};
|
|
17595
|
-
__name(_NetworkStatsbeatMetrics, "NetworkStatsbeatMetrics");
|
|
17596
|
-
__publicField(_NetworkStatsbeatMetrics, "instance", null);
|
|
17597
|
-
var NetworkStatsbeatMetrics = _NetworkStatsbeatMetrics;
|
|
17598
17664
|
|
|
17599
17665
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/export/statsbeat/longIntervalStatsbeatMetrics.js
|
|
17600
17666
|
init_esm();
|
|
17601
17667
|
var import_core6 = __toESM(require_src2(), 1);
|
|
17602
17668
|
var import_sdk_metrics3 = __toESM(require_src4(), 1);
|
|
17603
|
-
var
|
|
17669
|
+
var LongIntervalStatsbeatMetrics = class _LongIntervalStatsbeatMetrics extends StatsbeatMetrics {
|
|
17670
|
+
static {
|
|
17671
|
+
__name(this, "LongIntervalStatsbeatMetrics");
|
|
17672
|
+
}
|
|
17673
|
+
static instance = null;
|
|
17604
17674
|
statsCollectionLongInterval = 864e5;
|
|
17605
17675
|
// 1 day
|
|
17606
17676
|
// Custom dimensions
|
|
@@ -17737,13 +17807,13 @@ var _LongIntervalStatsbeatMetrics = class _LongIntervalStatsbeatMetrics extends
|
|
|
17737
17807
|
return _LongIntervalStatsbeatMetrics.instance;
|
|
17738
17808
|
}
|
|
17739
17809
|
};
|
|
17740
|
-
__name(_LongIntervalStatsbeatMetrics, "LongIntervalStatsbeatMetrics");
|
|
17741
|
-
__publicField(_LongIntervalStatsbeatMetrics, "instance", null);
|
|
17742
|
-
var LongIntervalStatsbeatMetrics = _LongIntervalStatsbeatMetrics;
|
|
17743
17810
|
|
|
17744
17811
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/platform/nodejs/baseSender.js
|
|
17745
17812
|
var DEFAULT_BATCH_SEND_RETRY_INTERVAL_MS = 6e4;
|
|
17746
|
-
var
|
|
17813
|
+
var BaseSender = class {
|
|
17814
|
+
static {
|
|
17815
|
+
__name(this, "BaseSender");
|
|
17816
|
+
}
|
|
17747
17817
|
persister;
|
|
17748
17818
|
numConsecutiveRedirects;
|
|
17749
17819
|
retryTimer;
|
|
@@ -17780,7 +17850,7 @@ var _BaseSender = class _BaseSender {
|
|
|
17780
17850
|
}
|
|
17781
17851
|
}
|
|
17782
17852
|
if (!this.customerSDKStatsMetrics) {
|
|
17783
|
-
import("./customerSDKStats-
|
|
17853
|
+
import("./customerSDKStats-JBHDMDFU.js").then((module) => module.CustomerSDKStatsMetrics.getInstance({
|
|
17784
17854
|
instrumentationKey: options.instrumentationKey,
|
|
17785
17855
|
endpointUrl: options.endpointUrl,
|
|
17786
17856
|
disableOfflineStorage: this.disableOfflineStorage,
|
|
@@ -17802,7 +17872,6 @@ var _BaseSender = class _BaseSender {
|
|
|
17802
17872
|
* Export envelopes
|
|
17803
17873
|
*/
|
|
17804
17874
|
async exportEnvelopes(envelopes) {
|
|
17805
|
-
var _a3, _b2, _c2, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y;
|
|
17806
17875
|
diag.info(`Exporting ${envelopes.length} envelope(s)`);
|
|
17807
17876
|
if (envelopes.length < 1) {
|
|
17808
17877
|
return { code: import_core7.ExportResultCode.SUCCESS };
|
|
@@ -17822,15 +17891,15 @@ var _BaseSender = class _BaseSender {
|
|
|
17822
17891
|
this.retryTimer.unref();
|
|
17823
17892
|
}
|
|
17824
17893
|
if (!this.isStatsbeatSender) {
|
|
17825
|
-
|
|
17826
|
-
|
|
17894
|
+
this.networkStatsbeatMetrics?.countSuccess(duration);
|
|
17895
|
+
this.customerSDKStatsMetrics?.countSuccessfulItems(envelopes);
|
|
17827
17896
|
}
|
|
17828
17897
|
return { code: import_core7.ExportResultCode.SUCCESS };
|
|
17829
17898
|
} else if (statusCode && isRetriable(statusCode)) {
|
|
17830
17899
|
if (statusCode === 429 || statusCode === 439) {
|
|
17831
17900
|
if (!this.isStatsbeatSender) {
|
|
17832
|
-
|
|
17833
|
-
|
|
17901
|
+
this.networkStatsbeatMetrics?.countThrottle(statusCode);
|
|
17902
|
+
this.customerSDKStatsMetrics?.countRetryItems(envelopes, statusCode);
|
|
17834
17903
|
}
|
|
17835
17904
|
return {
|
|
17836
17905
|
code: import_core7.ExportResultCode.SUCCESS
|
|
@@ -17842,7 +17911,7 @@ var _BaseSender = class _BaseSender {
|
|
|
17842
17911
|
const filteredEnvelopes = [];
|
|
17843
17912
|
const successfulEnvelopes = [...envelopes];
|
|
17844
17913
|
if (breezeResponse.itemsAccepted > 0 && statusCode === 206 && !this.isStatsbeatSender) {
|
|
17845
|
-
|
|
17914
|
+
this.networkStatsbeatMetrics?.countSuccess(duration);
|
|
17846
17915
|
}
|
|
17847
17916
|
if (breezeResponse.errors) {
|
|
17848
17917
|
breezeResponse.errors.forEach((error) => {
|
|
@@ -17854,29 +17923,29 @@ var _BaseSender = class _BaseSender {
|
|
|
17854
17923
|
}
|
|
17855
17924
|
if (breezeResponse.itemsAccepted > 0) {
|
|
17856
17925
|
if (!this.isStatsbeatSender) {
|
|
17857
|
-
|
|
17858
|
-
|
|
17926
|
+
this.networkStatsbeatMetrics?.countSuccess(duration);
|
|
17927
|
+
this.customerSDKStatsMetrics?.countSuccessfulItems(envelopes);
|
|
17859
17928
|
}
|
|
17860
17929
|
}
|
|
17861
17930
|
if (filteredEnvelopes.length > 0) {
|
|
17862
17931
|
if (!this.isStatsbeatSender) {
|
|
17863
|
-
|
|
17864
|
-
|
|
17932
|
+
this.networkStatsbeatMetrics?.countRetry(statusCode);
|
|
17933
|
+
this.customerSDKStatsMetrics?.countRetryItems(envelopes, statusCode);
|
|
17865
17934
|
}
|
|
17866
17935
|
return await this.persist(filteredEnvelopes);
|
|
17867
17936
|
}
|
|
17868
17937
|
if (!this.isStatsbeatSender) {
|
|
17869
|
-
|
|
17938
|
+
this.networkStatsbeatMetrics?.countFailure(duration, statusCode);
|
|
17870
17939
|
const filteredSuccessfulEnvelopes = successfulEnvelopes.filter(Boolean);
|
|
17871
|
-
|
|
17940
|
+
this.customerSDKStatsMetrics?.countDroppedItems(filteredSuccessfulEnvelopes, statusCode);
|
|
17872
17941
|
}
|
|
17873
17942
|
return this.buildExportResult({
|
|
17874
17943
|
code: import_core7.ExportResultCode.FAILED
|
|
17875
17944
|
});
|
|
17876
17945
|
} else {
|
|
17877
17946
|
if (!this.isStatsbeatSender) {
|
|
17878
|
-
|
|
17879
|
-
|
|
17947
|
+
this.networkStatsbeatMetrics?.countRetry(statusCode);
|
|
17948
|
+
this.customerSDKStatsMetrics?.countRetryItems(envelopes, statusCode);
|
|
17880
17949
|
}
|
|
17881
17950
|
return await this.persist(envelopes);
|
|
17882
17951
|
}
|
|
@@ -17884,11 +17953,11 @@ var _BaseSender = class _BaseSender {
|
|
|
17884
17953
|
if (this.networkStatsbeatMetrics && !this.isStatsbeatSender) {
|
|
17885
17954
|
if (statusCode) {
|
|
17886
17955
|
this.networkStatsbeatMetrics.countFailure(duration, statusCode);
|
|
17887
|
-
|
|
17956
|
+
this.customerSDKStatsMetrics?.countDroppedItems(envelopes, statusCode);
|
|
17888
17957
|
}
|
|
17889
17958
|
} else {
|
|
17890
17959
|
this.incrementStatsbeatFailure();
|
|
17891
|
-
|
|
17960
|
+
this.customerSDKStatsMetrics?.countDroppedItems(envelopes, DropCode.CLIENT_EXCEPTION);
|
|
17892
17961
|
}
|
|
17893
17962
|
return this.buildExportResult({
|
|
17894
17963
|
code: import_core7.ExportResultCode.FAILED
|
|
@@ -17910,14 +17979,14 @@ var _BaseSender = class _BaseSender {
|
|
|
17910
17979
|
} else {
|
|
17911
17980
|
const redirectError = new Error("Circular redirect");
|
|
17912
17981
|
if (!this.isStatsbeatSender) {
|
|
17913
|
-
|
|
17914
|
-
|
|
17982
|
+
this.networkStatsbeatMetrics?.countException(redirectError);
|
|
17983
|
+
this.customerSDKStatsMetrics?.countDroppedItems(envelopes, DropCode.CLIENT_EXCEPTION, redirectError.message, ExceptionType.CLIENT_EXCEPTION);
|
|
17915
17984
|
}
|
|
17916
17985
|
return this.buildExportResult({ code: import_core7.ExportResultCode.FAILED, error: redirectError });
|
|
17917
17986
|
}
|
|
17918
17987
|
} else if (restError.statusCode && isRetriable(restError.statusCode) && !this.isStatsbeatSender) {
|
|
17919
|
-
|
|
17920
|
-
|
|
17988
|
+
this.networkStatsbeatMetrics?.countRetry(restError.statusCode);
|
|
17989
|
+
this.customerSDKStatsMetrics?.countRetryItems(envelopes, restError.statusCode);
|
|
17921
17990
|
return this.persist(envelopes);
|
|
17922
17991
|
} else if (restError.statusCode === 400 && restError.message.includes("Invalid instrumentation key")) {
|
|
17923
17992
|
this.shutdownStatsbeat();
|
|
@@ -17927,19 +17996,19 @@ var _BaseSender = class _BaseSender {
|
|
|
17927
17996
|
return { code: import_core7.ExportResultCode.SUCCESS };
|
|
17928
17997
|
}
|
|
17929
17998
|
if (this.isRetriableRestError(restError) && !this.isStatsbeatSender) {
|
|
17930
|
-
if (
|
|
17931
|
-
|
|
17999
|
+
if (this.customerSDKStatsMetrics?.isTimeoutError(restError) && !this.isStatsbeatSender) {
|
|
18000
|
+
this.customerSDKStatsMetrics?.countRetryItems(envelopes, RetryCode.CLIENT_TIMEOUT, "timeout_exception", ExceptionType.TIMEOUT_EXCEPTION);
|
|
17932
18001
|
diag.error("Request timed out. Error message:", restError.message);
|
|
17933
18002
|
} else if (restError.statusCode) {
|
|
17934
|
-
|
|
17935
|
-
|
|
18003
|
+
this.networkStatsbeatMetrics?.countRetry(restError.statusCode);
|
|
18004
|
+
this.customerSDKStatsMetrics?.countRetryItems(envelopes, restError.statusCode);
|
|
17936
18005
|
}
|
|
17937
18006
|
diag.error("Retrying due to transient client side error. Error message:", restError.message);
|
|
17938
18007
|
return this.persist(envelopes);
|
|
17939
18008
|
}
|
|
17940
18009
|
if (!this.isStatsbeatSender) {
|
|
17941
|
-
|
|
17942
|
-
|
|
18010
|
+
this.networkStatsbeatMetrics?.countException(restError);
|
|
18011
|
+
this.customerSDKStatsMetrics?.countDroppedItems(envelopes, DropCode.CLIENT_EXCEPTION, restError.message);
|
|
17943
18012
|
diag.error("Envelopes could not be exported and are not retriable. Error message:", restError.message);
|
|
17944
18013
|
}
|
|
17945
18014
|
return this.buildExportResult({ code: import_core7.ExportResultCode.FAILED, error: restError });
|
|
@@ -17949,7 +18018,6 @@ var _BaseSender = class _BaseSender {
|
|
|
17949
18018
|
* Persist envelopes to disk
|
|
17950
18019
|
*/
|
|
17951
18020
|
async persist(envelopes) {
|
|
17952
|
-
var _a3, _b2;
|
|
17953
18021
|
try {
|
|
17954
18022
|
const success = await this.persister.push(envelopes);
|
|
17955
18023
|
return success ? { code: import_core7.ExportResultCode.SUCCESS } : this.buildExportResult({
|
|
@@ -17958,9 +18026,9 @@ var _BaseSender = class _BaseSender {
|
|
|
17958
18026
|
});
|
|
17959
18027
|
} catch (ex) {
|
|
17960
18028
|
if (!this.isStatsbeatSender) {
|
|
17961
|
-
|
|
18029
|
+
this.networkStatsbeatMetrics?.countWriteFailure();
|
|
17962
18030
|
if (this.disableOfflineStorage && envelopes) {
|
|
17963
|
-
|
|
18031
|
+
this.customerSDKStatsMetrics?.countDroppedItems(envelopes, DropCode.CLIENT_STORAGE_DISABLED);
|
|
17964
18032
|
}
|
|
17965
18033
|
}
|
|
17966
18034
|
return this.buildExportResult({ code: import_core7.ExportResultCode.FAILED, error: ex });
|
|
@@ -17979,12 +18047,11 @@ var _BaseSender = class _BaseSender {
|
|
|
17979
18047
|
* Shutdown statsbeat metrics
|
|
17980
18048
|
*/
|
|
17981
18049
|
shutdownStatsbeat() {
|
|
17982
|
-
var _a3;
|
|
17983
18050
|
if (this.networkStatsbeatMetrics) {
|
|
17984
18051
|
this.networkStatsbeatMetrics.shutdown();
|
|
17985
18052
|
}
|
|
17986
18053
|
if (this.longIntervalStatsbeatMetrics) {
|
|
17987
|
-
|
|
18054
|
+
this.longIntervalStatsbeatMetrics?.shutdown();
|
|
17988
18055
|
}
|
|
17989
18056
|
if (this.customerSDKStatsMetrics) {
|
|
17990
18057
|
this.customerSDKStatsMetrics.shutdown();
|
|
@@ -17992,7 +18059,6 @@ var _BaseSender = class _BaseSender {
|
|
|
17992
18059
|
this.statsbeatFailureCount = 0;
|
|
17993
18060
|
}
|
|
17994
18061
|
async sendFirstPersistedFile() {
|
|
17995
|
-
var _a3;
|
|
17996
18062
|
const envelopes = await this.persister.shift();
|
|
17997
18063
|
try {
|
|
17998
18064
|
if (envelopes) {
|
|
@@ -18000,7 +18066,7 @@ var _BaseSender = class _BaseSender {
|
|
|
18000
18066
|
}
|
|
18001
18067
|
} catch (err) {
|
|
18002
18068
|
if (!this.isStatsbeatSender) {
|
|
18003
|
-
|
|
18069
|
+
this.networkStatsbeatMetrics?.countReadFailure();
|
|
18004
18070
|
}
|
|
18005
18071
|
diag.warn(`Failed to fetch persisted file`, err);
|
|
18006
18072
|
}
|
|
@@ -18021,12 +18087,13 @@ var _BaseSender = class _BaseSender {
|
|
|
18021
18087
|
return result;
|
|
18022
18088
|
}
|
|
18023
18089
|
};
|
|
18024
|
-
__name(_BaseSender, "BaseSender");
|
|
18025
|
-
var BaseSender = _BaseSender;
|
|
18026
18090
|
|
|
18027
18091
|
// ../../node_modules/.store/@azure-monitor-opentelemetry-exporter-npm-1.0.0-beta.39-2525e0dfa0/package/dist/esm/platform/nodejs/httpSender.js
|
|
18028
18092
|
var applicationInsightsResource = "https://monitor.azure.com//.default";
|
|
18029
|
-
var
|
|
18093
|
+
var HttpSender = class extends BaseSender {
|
|
18094
|
+
static {
|
|
18095
|
+
__name(this, "HttpSender");
|
|
18096
|
+
}
|
|
18030
18097
|
appInsightsClient;
|
|
18031
18098
|
appInsightsClientOptions;
|
|
18032
18099
|
constructor(options) {
|
|
@@ -18063,7 +18130,7 @@ var _HttpSender = class _HttpSender extends BaseSender {
|
|
|
18063
18130
|
...options,
|
|
18064
18131
|
onResponse
|
|
18065
18132
|
});
|
|
18066
|
-
return { statusCode: response
|
|
18133
|
+
return { statusCode: response?.status, result: response?.bodyAsText ?? "" };
|
|
18067
18134
|
}
|
|
18068
18135
|
/**
|
|
18069
18136
|
* Shutdown sender
|
|
@@ -18081,8 +18148,6 @@ var _HttpSender = class _HttpSender extends BaseSender {
|
|
|
18081
18148
|
}
|
|
18082
18149
|
}
|
|
18083
18150
|
};
|
|
18084
|
-
__name(_HttpSender, "HttpSender");
|
|
18085
|
-
var HttpSender = _HttpSender;
|
|
18086
18151
|
|
|
18087
18152
|
export {
|
|
18088
18153
|
ATTR_SERVICE_INSTANCE_ID,
|