@8wave/ai-elements 0.104.0-beta.1 → 0.105.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_chunks/{Agent-DG4nPG72.js → Agent-VhugusRf.js} +2 -2
- package/dist/_chunks/Agent-VhugusRf.js.map +1 -0
- package/dist/_chunks/{Document-DXkvvAnt.js → Document-DjNrISX1.js} +2 -2
- package/dist/_chunks/{Document-DXkvvAnt.js.map → Document-DjNrISX1.js.map} +1 -1
- package/dist/_chunks/{Media-3Mo4NRj7.js → Media-hjgDyEMr.js} +2 -2
- package/dist/_chunks/Media-hjgDyEMr.js.map +1 -0
- package/dist/_chunks/{PkStreamingMarkdown-YKd9F3xU.js → PkStreamingMarkdown-B4eMb97I.js} +2 -2
- package/dist/_chunks/{PkStreamingMarkdown-YKd9F3xU.js.map → PkStreamingMarkdown-B4eMb97I.js.map} +1 -1
- package/dist/_chunks/{PkToolRequestGeolocation-sf6LpUN_.js → PkToolRequestGeolocation-Bp-D2nDb.js} +3 -3
- package/{dist-vue/_chunks/PkToolRequestGeolocation-BdX5DzEN.js.map → dist/_chunks/PkToolRequestGeolocation-Bp-D2nDb.js.map} +1 -1
- package/dist/_chunks/{PkToolRequestOAuthConnection-BB8mlQit.js → PkToolRequestOAuthConnection-CjjyDj9A.js} +3 -3
- package/dist/_chunks/{PkToolRequestOAuthConnection-BB8mlQit.js.map → PkToolRequestOAuthConnection-CjjyDj9A.js.map} +1 -1
- package/dist/_chunks/{PkToolShowArtifact-54saXXCe.js → PkToolShowArtifact-Dl8f7Q7q.js} +2 -2
- package/dist/_chunks/{PkToolShowArtifact-54saXXCe.js.map → PkToolShowArtifact-Dl8f7Q7q.js.map} +1 -1
- package/dist/_chunks/{PkToolShowCalendarEvent-B_HPVUDk.js → PkToolShowCalendarEvent-B_QmZrlZ.js} +2 -2
- package/dist/_chunks/{PkToolShowCalendarEvent-B_HPVUDk.js.map → PkToolShowCalendarEvent-B_QmZrlZ.js.map} +1 -1
- package/dist/_chunks/{PkToolShowContactForm-BtcNCixq.js → PkToolShowContactForm-CXE0485W.js} +14 -14
- package/dist/_chunks/{PkToolShowContactForm-BtcNCixq.js.map → PkToolShowContactForm-CXE0485W.js.map} +1 -1
- package/dist/_chunks/{PkToolShowDiagram-cA64c2_N.js → PkToolShowDiagram-D-TyCkCB.js} +2 -2
- package/dist/_chunks/{PkToolShowDiagram-cA64c2_N.js.map → PkToolShowDiagram-D-TyCkCB.js.map} +1 -1
- package/dist/_chunks/{PkToolShowForm-DdBAG0Qs.js → PkToolShowForm-BzaibKAz.js} +101 -115
- package/dist/_chunks/PkToolShowForm-BzaibKAz.js.map +1 -0
- package/dist/_chunks/{PkToolShowSources-0qudS-bu.js → PkToolShowSources-CoTIoupP.js} +3 -3
- package/dist/_chunks/{PkToolShowSources-0qudS-bu.js.map → PkToolShowSources-CoTIoupP.js.map} +1 -1
- package/dist/_chunks/{PkToolShowSuggestedReply-B2IB6ioR.js → PkToolShowSuggestedReply-DA2Bi7k4.js} +2 -2
- package/dist/_chunks/{PkToolShowSuggestedReply-B2IB6ioR.js.map → PkToolShowSuggestedReply-DA2Bi7k4.js.map} +1 -1
- package/dist/_chunks/{PkToolShowWeather-Bl3Yoscl.js → PkToolShowWeather-ChDHtOLz.js} +2 -2
- package/dist/_chunks/{PkToolShowWeather-Bl3Yoscl.js.map → PkToolShowWeather-ChDHtOLz.js.map} +1 -1
- package/dist/_chunks/{browser-DuzNfJq0.js → browser-BXy4OnXA.js} +804 -779
- package/dist/_chunks/browser-BXy4OnXA.js.map +1 -0
- package/dist/_chunks/index.es-CnpsLhp_.js +1006 -0
- package/dist/_chunks/index.es-CnpsLhp_.js.map +1 -0
- package/dist/_chunks/utils-DtJdKlnF.js +185 -0
- package/dist/_chunks/utils-DtJdKlnF.js.map +1 -0
- package/dist/_chunks/{vue-i18n-_ouwlDGE.js → vue-i18n-C3J36GV4.js} +2 -2
- package/dist/_chunks/{vue-i18n-_ouwlDGE.js.map → vue-i18n-C3J36GV4.js.map} +1 -1
- package/dist/_chunks/{web-DnPxEADy.js → web-CzR5jWfC.js} +46 -45
- package/dist/_chunks/{web-DnPxEADy.js.map → web-CzR5jWfC.js.map} +1 -1
- package/dist/ai-elements.es.js +2100 -2159
- package/dist/ai-elements.es.js.map +1 -1
- package/dist-vue/PkChatbot.js +1 -1
- package/dist-vue/PkChatbotMessages.js +1 -1
- package/dist-vue/PkChatbotStepPayload.js +1 -1
- package/dist-vue/PkChatbotStepToolDetail.js +1 -1
- package/dist-vue/PkChatbotSteps.js +1 -1
- package/dist-vue/PkChatbotViewChat.js +1 -1
- package/dist-vue/PkChatbotViewConversations.js +1 -1
- package/dist-vue/PkChatbotViewFiles.js +1 -1
- package/dist-vue/PkChatbotViewProfile.js +1 -1
- package/dist-vue/_chunks/{Agent-gCuDMxHN.js → Agent-CpIgGdU4.js} +2 -2
- package/dist-vue/_chunks/Agent-CpIgGdU4.js.map +1 -0
- package/dist-vue/_chunks/{Document-iH61Cw06.js → Document-CiaGPYTR.js} +2 -2
- package/dist-vue/_chunks/{Document-iH61Cw06.js.map → Document-CiaGPYTR.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbot-Bg9oercD.js → PkChatbot-xmjKbljL.js} +7 -7
- package/dist-vue/_chunks/{PkChatbot-Bg9oercD.js.map → PkChatbot-xmjKbljL.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotMessages-DUQxuYaG.js → PkChatbotMessages-tHQ2JQrb.js} +75 -75
- package/dist-vue/_chunks/{PkChatbotMessages-DUQxuYaG.js.map → PkChatbotMessages-tHQ2JQrb.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotStepPayload-hCmy4XG9.js → PkChatbotStepPayload-BtsnkJIV.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotStepPayload-hCmy4XG9.js.map → PkChatbotStepPayload-BtsnkJIV.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotStepToolDetail-B0WU0HcD.js → PkChatbotStepToolDetail-CCa95eBO.js} +116 -101
- package/dist-vue/_chunks/PkChatbotStepToolDetail-CCa95eBO.js.map +1 -0
- package/dist-vue/_chunks/PkChatbotSteps-CPBzs7Gi.js +180 -0
- package/dist-vue/_chunks/PkChatbotSteps-CPBzs7Gi.js.map +1 -0
- package/dist-vue/_chunks/{PkChatbotViewChat-YwjWNoqf.js → PkChatbotViewChat-CdiPjQLq.js} +6 -6
- package/dist-vue/_chunks/{PkChatbotViewChat-YwjWNoqf.js.map → PkChatbotViewChat-CdiPjQLq.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewConversations-vo57eSwy.js → PkChatbotViewConversations-BP-NJvlK.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewConversations-vo57eSwy.js.map → PkChatbotViewConversations-BP-NJvlK.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewFiles-DDPugn7F.js → PkChatbotViewFiles-DRUVmxU5.js} +3 -3
- package/dist-vue/_chunks/{PkChatbotViewFiles-DDPugn7F.js.map → PkChatbotViewFiles-DRUVmxU5.js.map} +1 -1
- package/dist-vue/_chunks/{PkChatbotViewProfile-Dww5KI21.js → PkChatbotViewProfile-ywvIs6N5.js} +2 -2
- package/dist-vue/_chunks/{PkChatbotViewProfile-Dww5KI21.js.map → PkChatbotViewProfile-ywvIs6N5.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolRequestGeolocation-BdX5DzEN.js → PkToolRequestGeolocation-BdIyXoPQ.js} +2 -2
- package/{dist/_chunks/PkToolRequestGeolocation-sf6LpUN_.js.map → dist-vue/_chunks/PkToolRequestGeolocation-BdIyXoPQ.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolRequestOAuthConnection-BUmnRgMi.js → PkToolRequestOAuthConnection-Dnch7xAB.js} +2 -2
- package/dist-vue/_chunks/{PkToolRequestOAuthConnection-BUmnRgMi.js.map → PkToolRequestOAuthConnection-Dnch7xAB.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowDiagram-YMo-iVWr.js → PkToolShowDiagram-DgLxNNp7.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowDiagram-YMo-iVWr.js.map → PkToolShowDiagram-DgLxNNp7.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowForm-D2n2rA6J.js → PkToolShowForm-6eLi6Wr0.js} +103 -117
- package/dist-vue/_chunks/PkToolShowForm-6eLi6Wr0.js.map +1 -0
- package/dist-vue/_chunks/{PkToolShowSources-DUAsrrzC.js → PkToolShowSources-DTJgvDiB.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowSources-DUAsrrzC.js.map → PkToolShowSources-DTJgvDiB.js.map} +1 -1
- package/dist-vue/_chunks/{PkToolShowSuggestedReply-Dm28RIJF.js → PkToolShowSuggestedReply-D9RY2h6Z.js} +2 -2
- package/dist-vue/_chunks/{PkToolShowSuggestedReply-Dm28RIJF.js.map → PkToolShowSuggestedReply-D9RY2h6Z.js.map} +1 -1
- package/dist-vue/_chunks/{createChatbotApiClient-CAX-3-oK.js → createChatbotApiClient-12eL7hul.js} +2 -2
- package/dist-vue/_chunks/{createChatbotApiClient-CAX-3-oK.js.map → createChatbotApiClient-12eL7hul.js.map} +1 -1
- package/dist-vue/_chunks/{useChatbotStore-Rj18hAUf.js → useChatbotStore-Chtzi5jc.js} +1086 -1016
- package/dist-vue/_chunks/useChatbotStore-Chtzi5jc.js.map +1 -0
- package/dist-vue/_chunks/{utils-B0jsOUqd.js → utils-DKNWwMTQ.js} +46 -23
- package/dist-vue/_chunks/utils-DKNWwMTQ.js.map +1 -0
- package/dist-vue/_chunks/{web-DnPxEADy.js → web-CzR5jWfC.js} +46 -45
- package/dist-vue/_chunks/{web-DnPxEADy.js.map → web-CzR5jWfC.js.map} +1 -1
- package/dist-vue/api.js +1 -1
- package/dist-vue/composables.js +3 -3
- package/dist-vue/index.js +261 -261
- package/dist-vue/index.js.map +1 -1
- package/dist-vue/locales.js +10 -4
- package/dist-vue/packages/components/src/PkEditorRepeater.d.ts +1 -1
- package/dist-vue/packages/components/src/chat/constants.d.ts +12 -0
- package/dist-vue/packages/components/src/chat/utils.d.ts +37 -0
- package/dist-vue/packages/models/src/schema/Agent.d.ts +24 -16
- package/dist-vue/packages/models/src/schema/AgentChatStatistics.d.ts +1 -1
- package/dist-vue/packages/models/src/schema/Chat.d.ts +9 -9
- package/dist-vue/packages/models/src/schema/Document.d.ts +6 -6
- package/dist-vue/packages/models/src/schema/DocumentFolder.d.ts +0 -1
- package/dist-vue/packages/models/src/schema/McpServer.d.ts +2 -2
- package/dist-vue/packages/models/src/schema/Member.d.ts +2 -2
- package/dist-vue/packages/models/src/schema/Organization.d.ts +4 -4
- package/dist-vue/packages/models/src/schema/ReasoningChat.d.ts +29 -29
- package/dist-vue/packages/models/src/schema/SubAgent.d.ts +20 -20
- package/dist-vue/packages/models/src/schema/User.d.ts +6 -6
- package/dist-vue/packages/models/src/schema/constants.d.ts +2 -0
- package/package.json +10 -5
- package/dist/_chunks/Agent-DG4nPG72.js.map +0 -1
- package/dist/_chunks/Media-3Mo4NRj7.js.map +0 -1
- package/dist/_chunks/PkToolShowForm-DdBAG0Qs.js.map +0 -1
- package/dist/_chunks/browser-DuzNfJq0.js.map +0 -1
- package/dist/_chunks/index.es-DXx8DNKf.js +0 -2986
- package/dist/_chunks/index.es-DXx8DNKf.js.map +0 -1
- package/dist-vue/_chunks/Agent-gCuDMxHN.js.map +0 -1
- package/dist-vue/_chunks/PkChatbotStepToolDetail-B0WU0HcD.js.map +0 -1
- package/dist-vue/_chunks/PkChatbotSteps-BrvTsAeZ.js +0 -177
- package/dist-vue/_chunks/PkChatbotSteps-BrvTsAeZ.js.map +0 -1
- package/dist-vue/_chunks/PkToolShowForm-D2n2rA6J.js.map +0 -1
- package/dist-vue/_chunks/useChatbotStore-Rj18hAUf.js.map +0 -1
- package/dist-vue/_chunks/utils-B0jsOUqd.js.map +0 -1
|
@@ -254,7 +254,7 @@ var Ae = {
|
|
|
254
254
|
disable() {
|
|
255
255
|
return this;
|
|
256
256
|
}
|
|
257
|
-
}, Ne = "context", Pe = new Me(),
|
|
257
|
+
}, Ne = "context", Pe = new Me(), Fe = class e {
|
|
258
258
|
constructor() {}
|
|
259
259
|
static getInstance() {
|
|
260
260
|
return this._instance ||= new e(), this._instance;
|
|
@@ -277,16 +277,16 @@ var Ae = {
|
|
|
277
277
|
disable() {
|
|
278
278
|
this._getContextManager().disable(), g(Ne, y.instance());
|
|
279
279
|
}
|
|
280
|
-
},
|
|
280
|
+
}, x;
|
|
281
281
|
(function(e) {
|
|
282
282
|
e[e.NONE = 0] = "NONE", e[e.SAMPLED = 1] = "SAMPLED";
|
|
283
|
-
})(
|
|
284
|
-
var
|
|
283
|
+
})(x ||= {});
|
|
284
|
+
var Ie = {
|
|
285
285
|
traceId: "00000000000000000000000000000000",
|
|
286
286
|
spanId: "0000000000000000",
|
|
287
|
-
traceFlags:
|
|
288
|
-
},
|
|
289
|
-
constructor(e =
|
|
287
|
+
traceFlags: x.NONE
|
|
288
|
+
}, S = class {
|
|
289
|
+
constructor(e = Ie) {
|
|
290
290
|
this._spanContext = e;
|
|
291
291
|
}
|
|
292
292
|
spanContext() {
|
|
@@ -318,28 +318,28 @@ var Fe = {
|
|
|
318
318
|
return !1;
|
|
319
319
|
}
|
|
320
320
|
recordException(e, t) {}
|
|
321
|
-
},
|
|
322
|
-
function
|
|
323
|
-
return e.getValue(
|
|
321
|
+
}, Le = ue("OpenTelemetry Context Key SPAN");
|
|
322
|
+
function Re(e) {
|
|
323
|
+
return e.getValue(Le) || void 0;
|
|
324
324
|
}
|
|
325
|
-
function
|
|
326
|
-
return
|
|
325
|
+
function ze() {
|
|
326
|
+
return Re(Fe.getInstance().active());
|
|
327
327
|
}
|
|
328
|
-
function
|
|
329
|
-
return e.setValue(
|
|
328
|
+
function Be(e, t) {
|
|
329
|
+
return e.setValue(Le, t);
|
|
330
330
|
}
|
|
331
|
-
function
|
|
332
|
-
return e.deleteValue(
|
|
331
|
+
function Ve(e) {
|
|
332
|
+
return e.deleteValue(Le);
|
|
333
333
|
}
|
|
334
|
-
function
|
|
335
|
-
return
|
|
334
|
+
function He(e, t) {
|
|
335
|
+
return Be(e, new S(t));
|
|
336
336
|
}
|
|
337
|
-
function
|
|
338
|
-
return
|
|
337
|
+
function Ue(e) {
|
|
338
|
+
return Re(e)?.spanContext();
|
|
339
339
|
}
|
|
340
340
|
//#endregion
|
|
341
341
|
//#region ../../node_modules/.pnpm/@opentelemetry+api@1.9.1/node_modules/@opentelemetry/api/build/esm/trace/spancontext-utils.js
|
|
342
|
-
var
|
|
342
|
+
var We = new Uint8Array([
|
|
343
343
|
0,
|
|
344
344
|
0,
|
|
345
345
|
0,
|
|
@@ -444,46 +444,46 @@ var Ue = new Uint8Array([
|
|
|
444
444
|
1,
|
|
445
445
|
1
|
|
446
446
|
]);
|
|
447
|
-
function
|
|
447
|
+
function Ge(e, t) {
|
|
448
448
|
if (typeof e != "string" || e.length !== t) return !1;
|
|
449
449
|
let n = 0;
|
|
450
|
-
for (let t = 0; t < e.length; t += 4) n += (
|
|
450
|
+
for (let t = 0; t < e.length; t += 4) n += (We[e.charCodeAt(t)] | 0) + (We[e.charCodeAt(t + 1)] | 0) + (We[e.charCodeAt(t + 2)] | 0) + (We[e.charCodeAt(t + 3)] | 0);
|
|
451
451
|
return n === t;
|
|
452
452
|
}
|
|
453
|
-
function Ge(e) {
|
|
454
|
-
return We(e, 32) && e !== "00000000000000000000000000000000";
|
|
455
|
-
}
|
|
456
453
|
function Ke(e) {
|
|
457
|
-
return
|
|
454
|
+
return Ge(e, 32) && e !== "00000000000000000000000000000000";
|
|
458
455
|
}
|
|
459
456
|
function qe(e) {
|
|
460
|
-
return Ge(e
|
|
457
|
+
return Ge(e, 16) && e !== "0000000000000000";
|
|
461
458
|
}
|
|
462
459
|
function Je(e) {
|
|
463
|
-
return
|
|
460
|
+
return Ke(e.traceId) && qe(e.spanId);
|
|
461
|
+
}
|
|
462
|
+
function Ye(e) {
|
|
463
|
+
return new S(e);
|
|
464
464
|
}
|
|
465
465
|
//#endregion
|
|
466
466
|
//#region ../../node_modules/.pnpm/@opentelemetry+api@1.9.1/node_modules/@opentelemetry/api/build/esm/trace/NoopTracer.js
|
|
467
|
-
var
|
|
468
|
-
startSpan(e, t, n =
|
|
469
|
-
if (t?.root) return new
|
|
470
|
-
let r = n &&
|
|
471
|
-
return
|
|
467
|
+
var Xe = Fe.getInstance(), Ze = class {
|
|
468
|
+
startSpan(e, t, n = Xe.active()) {
|
|
469
|
+
if (t?.root) return new S();
|
|
470
|
+
let r = n && Ue(n);
|
|
471
|
+
return Qe(r) && Je(r) ? new S(r) : new S();
|
|
472
472
|
}
|
|
473
473
|
startActiveSpan(e, t, n, r) {
|
|
474
474
|
let i, a, o;
|
|
475
475
|
if (arguments.length < 2) return;
|
|
476
476
|
arguments.length === 2 ? o = t : arguments.length === 3 ? (i = t, o = n) : (i = t, a = n, o = r);
|
|
477
|
-
let s = a ??
|
|
478
|
-
return
|
|
477
|
+
let s = a ?? Xe.active(), c = this.startSpan(e, i, s), l = Be(s, c);
|
|
478
|
+
return Xe.with(l, o, void 0, c);
|
|
479
479
|
}
|
|
480
480
|
};
|
|
481
|
-
function
|
|
481
|
+
function Qe(e) {
|
|
482
482
|
return typeof e == "object" && !!e && "spanId" in e && typeof e.spanId == "string" && "traceId" in e && typeof e.traceId == "string" && "traceFlags" in e && typeof e.traceFlags == "number";
|
|
483
483
|
}
|
|
484
484
|
//#endregion
|
|
485
485
|
//#region ../../node_modules/.pnpm/@opentelemetry+api@1.9.1/node_modules/@opentelemetry/api/build/esm/trace/ProxyTracer.js
|
|
486
|
-
var
|
|
486
|
+
var $e = new Ze(), et = class {
|
|
487
487
|
constructor(e, t, n, r) {
|
|
488
488
|
this._provider = e, this.name = t, this.version = n, this.options = r;
|
|
489
489
|
}
|
|
@@ -497,18 +497,18 @@ var Qe = new Xe(), $e = class {
|
|
|
497
497
|
_getTracer() {
|
|
498
498
|
if (this._delegate) return this._delegate;
|
|
499
499
|
let e = this._provider.getDelegateTracer(this.name, this.version, this.options);
|
|
500
|
-
return e ? (this._delegate = e, this._delegate) :
|
|
500
|
+
return e ? (this._delegate = e, this._delegate) : $e;
|
|
501
501
|
}
|
|
502
|
-
},
|
|
502
|
+
}, tt = new class {
|
|
503
503
|
getTracer(e, t, n) {
|
|
504
|
-
return new
|
|
504
|
+
return new Ze();
|
|
505
505
|
}
|
|
506
|
-
}(),
|
|
506
|
+
}(), nt = class {
|
|
507
507
|
getTracer(e, t, n) {
|
|
508
|
-
return this.getDelegateTracer(e, t, n) ?? new
|
|
508
|
+
return this.getDelegateTracer(e, t, n) ?? new et(this, e, t, n);
|
|
509
509
|
}
|
|
510
510
|
getDelegate() {
|
|
511
|
-
return this._delegate ??
|
|
511
|
+
return this._delegate ?? tt;
|
|
512
512
|
}
|
|
513
513
|
setDelegate(e) {
|
|
514
514
|
this._delegate = e;
|
|
@@ -516,46 +516,46 @@ var Qe = new Xe(), $e = class {
|
|
|
516
516
|
getDelegateTracer(e, t, n) {
|
|
517
517
|
return this._delegate?.getTracer(e, t, n);
|
|
518
518
|
}
|
|
519
|
-
},
|
|
519
|
+
}, rt;
|
|
520
520
|
(function(e) {
|
|
521
521
|
e[e.NOT_RECORD = 0] = "NOT_RECORD", e[e.RECORD = 1] = "RECORD", e[e.RECORD_AND_SAMPLED = 2] = "RECORD_AND_SAMPLED";
|
|
522
|
-
})(
|
|
522
|
+
})(rt ||= {});
|
|
523
523
|
//#endregion
|
|
524
524
|
//#region ../../node_modules/.pnpm/@opentelemetry+api@1.9.1/node_modules/@opentelemetry/api/build/esm/trace/span_kind.js
|
|
525
|
-
var
|
|
525
|
+
var it;
|
|
526
526
|
(function(e) {
|
|
527
527
|
e[e.INTERNAL = 0] = "INTERNAL", e[e.SERVER = 1] = "SERVER", e[e.CLIENT = 2] = "CLIENT", e[e.PRODUCER = 3] = "PRODUCER", e[e.CONSUMER = 4] = "CONSUMER";
|
|
528
|
-
})(
|
|
528
|
+
})(it ||= {});
|
|
529
529
|
//#endregion
|
|
530
530
|
//#region ../../node_modules/.pnpm/@opentelemetry+api@1.9.1/node_modules/@opentelemetry/api/build/esm/trace/status.js
|
|
531
|
-
var
|
|
531
|
+
var C;
|
|
532
532
|
(function(e) {
|
|
533
533
|
e[e.UNSET = 0] = "UNSET", e[e.OK = 1] = "OK", e[e.ERROR = 2] = "ERROR";
|
|
534
|
-
})(
|
|
534
|
+
})(C ||= {});
|
|
535
535
|
//#endregion
|
|
536
536
|
//#region ../../node_modules/.pnpm/@opentelemetry+api@1.9.1/node_modules/@opentelemetry/api/build/esm/context-api.js
|
|
537
|
-
var
|
|
537
|
+
var w = Fe.getInstance(), T = y.instance(), at = new class {
|
|
538
538
|
getMeter(e, t, n) {
|
|
539
539
|
return xe;
|
|
540
540
|
}
|
|
541
|
-
}(),
|
|
541
|
+
}(), ot = "metrics", st = class e {
|
|
542
542
|
constructor() {}
|
|
543
543
|
static getInstance() {
|
|
544
544
|
return this._instance ||= new e(), this._instance;
|
|
545
545
|
}
|
|
546
546
|
setGlobalMeterProvider(e) {
|
|
547
|
-
return m(
|
|
547
|
+
return m(ot, e, y.instance());
|
|
548
548
|
}
|
|
549
549
|
getMeterProvider() {
|
|
550
|
-
return h(
|
|
550
|
+
return h(ot) || at;
|
|
551
551
|
}
|
|
552
552
|
getMeter(e, t, n) {
|
|
553
553
|
return this.getMeterProvider().getMeter(e, t, n);
|
|
554
554
|
}
|
|
555
555
|
disable() {
|
|
556
|
-
g(
|
|
556
|
+
g(ot, y.instance());
|
|
557
557
|
}
|
|
558
|
-
}.getInstance(),
|
|
558
|
+
}.getInstance(), ct = class {
|
|
559
559
|
inject(e, t) {}
|
|
560
560
|
extract(e, t) {
|
|
561
561
|
return e;
|
|
@@ -563,30 +563,30 @@ var T = x.getInstance(), E = y.instance(), it = new class {
|
|
|
563
563
|
fields() {
|
|
564
564
|
return [];
|
|
565
565
|
}
|
|
566
|
-
},
|
|
567
|
-
function
|
|
568
|
-
return e.getValue(
|
|
566
|
+
}, lt = ue("OpenTelemetry Baggage Key");
|
|
567
|
+
function ut(e) {
|
|
568
|
+
return e.getValue(lt) || void 0;
|
|
569
569
|
}
|
|
570
|
-
function
|
|
571
|
-
return
|
|
570
|
+
function dt() {
|
|
571
|
+
return ut(Fe.getInstance().active());
|
|
572
572
|
}
|
|
573
|
-
function
|
|
574
|
-
return e.setValue(
|
|
573
|
+
function ft(e, t) {
|
|
574
|
+
return e.setValue(lt, t);
|
|
575
575
|
}
|
|
576
|
-
function
|
|
577
|
-
return e.deleteValue(
|
|
576
|
+
function pt(e) {
|
|
577
|
+
return e.deleteValue(lt);
|
|
578
578
|
}
|
|
579
579
|
//#endregion
|
|
580
580
|
//#region ../../node_modules/.pnpm/@opentelemetry+api@1.9.1/node_modules/@opentelemetry/api/build/esm/api/propagation.js
|
|
581
|
-
var
|
|
581
|
+
var mt = "propagation", ht = new ct(), E = class e {
|
|
582
582
|
constructor() {
|
|
583
|
-
this.createBaggage = ce, this.getBaggage =
|
|
583
|
+
this.createBaggage = ce, this.getBaggage = ut, this.getActiveBaggage = dt, this.setBaggage = ft, this.deleteBaggage = pt;
|
|
584
584
|
}
|
|
585
585
|
static getInstance() {
|
|
586
586
|
return this._instance ||= new e(), this._instance;
|
|
587
587
|
}
|
|
588
588
|
setGlobalPropagator(e) {
|
|
589
|
-
return m(
|
|
589
|
+
return m(mt, e, y.instance());
|
|
590
590
|
}
|
|
591
591
|
inject(e, t, n = je) {
|
|
592
592
|
return this._getGlobalPropagator().inject(e, t, n);
|
|
@@ -598,56 +598,56 @@ var pt = "propagation", mt = new st(), D = class e {
|
|
|
598
598
|
return this._getGlobalPropagator().fields();
|
|
599
599
|
}
|
|
600
600
|
disable() {
|
|
601
|
-
g(
|
|
601
|
+
g(mt, y.instance());
|
|
602
602
|
}
|
|
603
603
|
_getGlobalPropagator() {
|
|
604
|
-
return h(
|
|
604
|
+
return h(mt) || ht;
|
|
605
605
|
}
|
|
606
|
-
}.getInstance(),
|
|
606
|
+
}.getInstance(), gt = "trace", D = class e {
|
|
607
607
|
constructor() {
|
|
608
|
-
this._proxyTracerProvider = new
|
|
608
|
+
this._proxyTracerProvider = new nt(), this.wrapSpanContext = Ye, this.isSpanContextValid = Je, this.deleteSpan = Ve, this.getSpan = Re, this.getActiveSpan = ze, this.getSpanContext = Ue, this.setSpan = Be, this.setSpanContext = He;
|
|
609
609
|
}
|
|
610
610
|
static getInstance() {
|
|
611
611
|
return this._instance ||= new e(), this._instance;
|
|
612
612
|
}
|
|
613
613
|
setGlobalTracerProvider(e) {
|
|
614
|
-
let t = m(
|
|
614
|
+
let t = m(gt, this._proxyTracerProvider, y.instance());
|
|
615
615
|
return t && this._proxyTracerProvider.setDelegate(e), t;
|
|
616
616
|
}
|
|
617
617
|
getTracerProvider() {
|
|
618
|
-
return h(
|
|
618
|
+
return h(gt) || this._proxyTracerProvider;
|
|
619
619
|
}
|
|
620
620
|
getTracer(e, t) {
|
|
621
621
|
return this.getTracerProvider().getTracer(e, t);
|
|
622
622
|
}
|
|
623
623
|
disable() {
|
|
624
|
-
g(
|
|
624
|
+
g(gt, y.instance()), this._proxyTracerProvider = new nt();
|
|
625
625
|
}
|
|
626
|
-
}.getInstance(),
|
|
627
|
-
function _t(e) {
|
|
628
|
-
return e.setValue(gt, !0);
|
|
629
|
-
}
|
|
626
|
+
}.getInstance(), _t = ue("OpenTelemetry SDK Context Key SUPPRESS_TRACING");
|
|
630
627
|
function vt(e) {
|
|
631
|
-
return e.
|
|
628
|
+
return e.setValue(_t, !0);
|
|
629
|
+
}
|
|
630
|
+
function yt(e) {
|
|
631
|
+
return e.getValue(_t) === !0;
|
|
632
632
|
}
|
|
633
633
|
//#endregion
|
|
634
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
635
|
-
var
|
|
634
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/baggage/constants.js
|
|
635
|
+
var bt = "baggage", xt = 4096;
|
|
636
636
|
//#endregion
|
|
637
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
638
|
-
function
|
|
637
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/baggage/utils.js
|
|
638
|
+
function St(e) {
|
|
639
639
|
return e.reduce((e, t) => {
|
|
640
640
|
let n = `${e}${e === "" ? "" : ","}${t}`;
|
|
641
641
|
return n.length > 8192 ? e : n;
|
|
642
642
|
}, "");
|
|
643
643
|
}
|
|
644
|
-
function
|
|
644
|
+
function Ct(e) {
|
|
645
645
|
return e.getAllEntries().map(([e, t]) => {
|
|
646
646
|
let n = `${encodeURIComponent(e)}=${encodeURIComponent(t.value)}`;
|
|
647
647
|
return t.metadata !== void 0 && (n += ";" + t.metadata.toString()), n;
|
|
648
648
|
});
|
|
649
649
|
}
|
|
650
|
-
function
|
|
650
|
+
function wt(e) {
|
|
651
651
|
if (!e) return;
|
|
652
652
|
let t = e.indexOf(";"), n = t === -1 ? e : e.substring(0, t), r = n.indexOf("=");
|
|
653
653
|
if (r <= 0) return;
|
|
@@ -666,12 +666,12 @@ function Ct(e) {
|
|
|
666
666
|
metadata: c
|
|
667
667
|
};
|
|
668
668
|
}
|
|
669
|
-
function
|
|
669
|
+
function Tt(e, t, n, r) {
|
|
670
670
|
let i = 0;
|
|
671
671
|
for (; i < e.length && n < 180;) {
|
|
672
672
|
let a = e.indexOf(",", i), o = a === -1 ? e.length : a, s = o - i;
|
|
673
673
|
if (s <= 4096) {
|
|
674
|
-
let a =
|
|
674
|
+
let a = wt(e.substring(i, o));
|
|
675
675
|
if (a) {
|
|
676
676
|
let e = (n === 0 ? 0 : 1) + s;
|
|
677
677
|
if (r + e > 8192) break;
|
|
@@ -687,60 +687,60 @@ function wt(e, t, n, r) {
|
|
|
687
687
|
return [n, r];
|
|
688
688
|
}
|
|
689
689
|
//#endregion
|
|
690
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
691
|
-
var
|
|
690
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/baggage/propagation/W3CBaggagePropagator.js
|
|
691
|
+
var Et = class {
|
|
692
692
|
inject(e, t, n) {
|
|
693
|
-
let r =
|
|
694
|
-
if (!r ||
|
|
695
|
-
let i =
|
|
696
|
-
i.length > 0 && n.set(t,
|
|
693
|
+
let r = E.getBaggage(e);
|
|
694
|
+
if (!r || yt(e)) return;
|
|
695
|
+
let i = St(Ct(r).filter((e) => e.length <= xt).slice(0, 180));
|
|
696
|
+
i.length > 0 && n.set(t, bt, i);
|
|
697
697
|
}
|
|
698
698
|
extract(e, t, n) {
|
|
699
|
-
let r = n.get(t,
|
|
699
|
+
let r = n.get(t, bt);
|
|
700
700
|
if (!r) return e;
|
|
701
701
|
let i = {}, a = 0, o = 0;
|
|
702
|
-
if (Array.isArray(r)) for (let e = 0; e < r.length; e++) [a, o] =
|
|
703
|
-
else [a] =
|
|
704
|
-
return a === 0 ? e :
|
|
702
|
+
if (Array.isArray(r)) for (let e = 0; e < r.length; e++) [a, o] = Tt(r[e], i, a, o);
|
|
703
|
+
else [a] = Tt(r, i, a, o);
|
|
704
|
+
return a === 0 ? e : E.setBaggage(e, E.createBaggage(i));
|
|
705
705
|
}
|
|
706
706
|
fields() {
|
|
707
|
-
return [
|
|
707
|
+
return [bt];
|
|
708
708
|
}
|
|
709
709
|
};
|
|
710
710
|
//#endregion
|
|
711
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
712
|
-
function
|
|
711
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/common/attributes.js
|
|
712
|
+
function O(e) {
|
|
713
713
|
let t = {};
|
|
714
714
|
if (typeof e != "object" || !e) return t;
|
|
715
715
|
for (let n in e) {
|
|
716
716
|
if (!Object.prototype.hasOwnProperty.call(e, n)) continue;
|
|
717
|
-
if (!
|
|
718
|
-
|
|
717
|
+
if (!Dt(n)) {
|
|
718
|
+
T.warn(`Invalid attribute key: ${n}`);
|
|
719
719
|
continue;
|
|
720
720
|
}
|
|
721
721
|
let r = e[n];
|
|
722
|
-
if (!
|
|
723
|
-
|
|
722
|
+
if (!Ot(r)) {
|
|
723
|
+
T.warn(`Invalid attribute value set for key: ${n}`);
|
|
724
724
|
continue;
|
|
725
725
|
}
|
|
726
726
|
t[n] = Array.isArray(r) ? r.slice() : r;
|
|
727
727
|
}
|
|
728
728
|
return t;
|
|
729
729
|
}
|
|
730
|
-
function Et(e) {
|
|
731
|
-
return typeof e == "string" && e !== "";
|
|
732
|
-
}
|
|
733
730
|
function Dt(e) {
|
|
734
|
-
return e ==
|
|
731
|
+
return typeof e == "string" && e !== "";
|
|
735
732
|
}
|
|
736
733
|
function Ot(e) {
|
|
734
|
+
return e == null ? !0 : Array.isArray(e) ? kt(e) : At(typeof e);
|
|
735
|
+
}
|
|
736
|
+
function kt(e) {
|
|
737
737
|
let t;
|
|
738
738
|
for (let n of e) {
|
|
739
739
|
if (n == null) continue;
|
|
740
740
|
let e = typeof n;
|
|
741
741
|
if (e !== t) {
|
|
742
742
|
if (!t) {
|
|
743
|
-
if (
|
|
743
|
+
if (At(e)) {
|
|
744
744
|
t = e;
|
|
745
745
|
continue;
|
|
746
746
|
}
|
|
@@ -751,7 +751,7 @@ function Ot(e) {
|
|
|
751
751
|
}
|
|
752
752
|
return !0;
|
|
753
753
|
}
|
|
754
|
-
function
|
|
754
|
+
function At(e) {
|
|
755
755
|
switch (e) {
|
|
756
756
|
case "number":
|
|
757
757
|
case "boolean":
|
|
@@ -760,16 +760,16 @@ function kt(e) {
|
|
|
760
760
|
return !1;
|
|
761
761
|
}
|
|
762
762
|
//#endregion
|
|
763
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
764
|
-
function
|
|
763
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/common/logging-error-handler.js
|
|
764
|
+
function jt() {
|
|
765
765
|
return (e) => {
|
|
766
|
-
|
|
766
|
+
T.error(Mt(e));
|
|
767
767
|
};
|
|
768
768
|
}
|
|
769
|
-
function jt(e) {
|
|
770
|
-
return typeof e == "string" ? e : JSON.stringify(Mt(e));
|
|
771
|
-
}
|
|
772
769
|
function Mt(e) {
|
|
770
|
+
return typeof e == "string" ? e : JSON.stringify(Nt(e));
|
|
771
|
+
}
|
|
772
|
+
function Nt(e) {
|
|
773
773
|
let t = {}, n = e;
|
|
774
774
|
for (; n !== null;) Object.getOwnPropertyNames(n).forEach((e) => {
|
|
775
775
|
if (t[e]) return;
|
|
@@ -779,63 +779,63 @@ function Mt(e) {
|
|
|
779
779
|
return t;
|
|
780
780
|
}
|
|
781
781
|
//#endregion
|
|
782
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
783
|
-
var
|
|
784
|
-
function
|
|
782
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/common/global-error-handler.js
|
|
783
|
+
var Pt = jt();
|
|
784
|
+
function k(e) {
|
|
785
785
|
try {
|
|
786
|
-
|
|
786
|
+
Pt(e);
|
|
787
787
|
} catch {}
|
|
788
788
|
}
|
|
789
789
|
//#endregion
|
|
790
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
791
|
-
var
|
|
790
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/version.js
|
|
791
|
+
var Ft = "2.11.0", It = "process.runtime.name", Lt = {
|
|
792
792
|
[o]: "opentelemetry",
|
|
793
|
-
[
|
|
793
|
+
[It]: "browser",
|
|
794
794
|
[i]: a,
|
|
795
|
-
[s]:
|
|
796
|
-
},
|
|
797
|
-
function
|
|
795
|
+
[s]: Ft
|
|
796
|
+
}, A = performance, Rt = 9, zt = 10 ** 6, Bt = 10 ** Rt;
|
|
797
|
+
function j(e) {
|
|
798
798
|
let t = e / 1e3;
|
|
799
|
-
return [Math.trunc(t), Math.round(e % 1e3 *
|
|
799
|
+
return [Math.trunc(t), Math.round(e % 1e3 * zt)];
|
|
800
800
|
}
|
|
801
|
-
function
|
|
802
|
-
return
|
|
801
|
+
function M(e) {
|
|
802
|
+
return Gt(j(A.timeOrigin), j(typeof e == "number" ? e : A.now()));
|
|
803
803
|
}
|
|
804
|
-
function
|
|
805
|
-
if (
|
|
806
|
-
if (typeof e == "number") return e <
|
|
807
|
-
if (e instanceof Date) return
|
|
804
|
+
function N(e) {
|
|
805
|
+
if (Ut(e)) return e;
|
|
806
|
+
if (typeof e == "number") return e < A.timeOrigin / 2 ? M(e) : j(e);
|
|
807
|
+
if (e instanceof Date) return j(e.getTime());
|
|
808
808
|
throw TypeError("Invalid input type");
|
|
809
809
|
}
|
|
810
|
-
function
|
|
810
|
+
function Vt(e, t) {
|
|
811
811
|
let n = t[0] - e[0], r = t[1] - e[1];
|
|
812
|
-
return r < 0 && (--n, r +=
|
|
812
|
+
return r < 0 && (--n, r += Bt), [n, r];
|
|
813
813
|
}
|
|
814
|
-
function
|
|
815
|
-
return e[0] *
|
|
814
|
+
function P(e) {
|
|
815
|
+
return e[0] * Bt + e[1];
|
|
816
816
|
}
|
|
817
|
-
function
|
|
817
|
+
function Ht(e) {
|
|
818
818
|
return e[0] * 1e3 + e[1] / 1e6;
|
|
819
819
|
}
|
|
820
|
-
function
|
|
820
|
+
function Ut(e) {
|
|
821
821
|
return Array.isArray(e) && e.length === 2 && typeof e[0] == "number" && typeof e[1] == "number";
|
|
822
822
|
}
|
|
823
|
-
function
|
|
824
|
-
return
|
|
823
|
+
function Wt(e) {
|
|
824
|
+
return Ut(e) || typeof e == "number" || e instanceof Date;
|
|
825
825
|
}
|
|
826
|
-
function
|
|
826
|
+
function Gt(e, t) {
|
|
827
827
|
let n = [e[0] + t[0], e[1] + t[1]];
|
|
828
|
-
return n[1] >=
|
|
828
|
+
return n[1] >= Bt && (n[1] -= Bt, n[0] += 1), n;
|
|
829
829
|
}
|
|
830
830
|
//#endregion
|
|
831
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
832
|
-
var
|
|
831
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/ExportResult.js
|
|
832
|
+
var F;
|
|
833
833
|
(function(e) {
|
|
834
834
|
e[e.SUCCESS = 0] = "SUCCESS", e[e.FAILED = 1] = "FAILED";
|
|
835
|
-
})(
|
|
835
|
+
})(F ||= {});
|
|
836
836
|
//#endregion
|
|
837
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
838
|
-
var
|
|
837
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/propagation/composite.js
|
|
838
|
+
var Kt = class {
|
|
839
839
|
_propagators;
|
|
840
840
|
_fields;
|
|
841
841
|
constructor(e = {}) {
|
|
@@ -851,7 +851,7 @@ var Gt = class {
|
|
|
851
851
|
for (let r of this._propagators) try {
|
|
852
852
|
r.inject(e, t, n);
|
|
853
853
|
} catch (e) {
|
|
854
|
-
|
|
854
|
+
T.warn(`Failed to inject with ${r.constructor.name}. Err: ${e.message}`);
|
|
855
855
|
}
|
|
856
856
|
}
|
|
857
857
|
extract(e, t, n) {
|
|
@@ -859,7 +859,7 @@ var Gt = class {
|
|
|
859
859
|
try {
|
|
860
860
|
return r.extract(e, t, n);
|
|
861
861
|
} catch (e) {
|
|
862
|
-
|
|
862
|
+
T.warn(`Failed to extract with ${r.constructor.name}. Err: ${e.message}`);
|
|
863
863
|
}
|
|
864
864
|
return e;
|
|
865
865
|
}, e);
|
|
@@ -867,16 +867,16 @@ var Gt = class {
|
|
|
867
867
|
fields() {
|
|
868
868
|
return this._fields.slice();
|
|
869
869
|
}
|
|
870
|
-
},
|
|
871
|
-
function Xt(e) {
|
|
872
|
-
return qt.test(e);
|
|
873
|
-
}
|
|
870
|
+
}, qt = "[_0-9a-z-*/]", Jt = RegExp(`^(?:${`[a-z]${qt}{0,255}`}|${`[a-z0-9]${qt}{0,240}@[a-z]${qt}{0,13}`})$`), Yt = /^[ -~]{0,255}[!-~]$/, Xt = /,|=/;
|
|
874
871
|
function Zt(e) {
|
|
875
|
-
return Jt.test(e)
|
|
872
|
+
return Jt.test(e);
|
|
873
|
+
}
|
|
874
|
+
function Qt(e) {
|
|
875
|
+
return Yt.test(e) && !Xt.test(e);
|
|
876
876
|
}
|
|
877
877
|
//#endregion
|
|
878
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
879
|
-
var
|
|
878
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/trace/TraceState.js
|
|
879
|
+
var $t = 32, en = 512, tn = ",", nn = "=", rn = class e {
|
|
880
880
|
_length;
|
|
881
881
|
_rawTraceState;
|
|
882
882
|
_internalState;
|
|
@@ -884,9 +884,9 @@ var Qt = 32, $t = 512, en = ",", tn = "=", nn = class e {
|
|
|
884
884
|
this._rawTraceState = typeof e == "string" ? e : "", this._length = this._rawTraceState.length;
|
|
885
885
|
}
|
|
886
886
|
set(e, t) {
|
|
887
|
-
if (!
|
|
887
|
+
if (!Zt(e) || !Qt(t)) return this;
|
|
888
888
|
let n = this._getState(), r = n.get(e), i = this._length;
|
|
889
|
-
if (i += typeof r == "string" ? t.length - r.length : e.length + t.length + (n.size > 0 ? 2 : 1), i >
|
|
889
|
+
if (i += typeof r == "string" ? t.length - r.length : e.length + t.length + (n.size > 0 ? 2 : 1), i > en) return this;
|
|
890
890
|
let a = new Map(n);
|
|
891
891
|
return a.delete(e), a.set(e, t), this._fromState(a, i);
|
|
892
892
|
}
|
|
@@ -903,19 +903,19 @@ var Qt = 32, $t = 512, en = ",", tn = "=", nn = class e {
|
|
|
903
903
|
}
|
|
904
904
|
serialize() {
|
|
905
905
|
let e = "", t = 0;
|
|
906
|
-
for (let n of this._getState()) t > 0 && (e =
|
|
906
|
+
for (let n of this._getState()) t > 0 && (e = tn + e), e = `${n[0]}${nn}${n[1]}` + e, t++;
|
|
907
907
|
return e;
|
|
908
908
|
}
|
|
909
909
|
_getState() {
|
|
910
910
|
if (this._internalState) return this._internalState;
|
|
911
|
-
let e = this._rawTraceState.split(
|
|
911
|
+
let e = this._rawTraceState.split(tn), t = /* @__PURE__ */ new Map(), n = 0;
|
|
912
912
|
for (let r of e) {
|
|
913
|
-
let e = r.trim(), i = e.indexOf(
|
|
913
|
+
let e = r.trim(), i = e.indexOf(nn);
|
|
914
914
|
if (i === -1) continue;
|
|
915
915
|
let a = e.slice(0, i), o = e.slice(i + 1);
|
|
916
|
-
if (!
|
|
916
|
+
if (!Zt(a) || !Qt(o)) continue;
|
|
917
917
|
let s = n + e.length + +(t.size > 0);
|
|
918
|
-
if (!(s >
|
|
918
|
+
if (!(s > en) && (t.set(a, o), n = s, t.size >= $t)) break;
|
|
919
919
|
}
|
|
920
920
|
return this._length = n, this._internalState = new Map(Array.from(t.entries()).reverse()), this._internalState;
|
|
921
921
|
}
|
|
@@ -923,104 +923,104 @@ var Qt = 32, $t = 512, en = ",", tn = "=", nn = class e {
|
|
|
923
923
|
let r = Object.create(e.prototype);
|
|
924
924
|
return r._internalState = t, r._length = n, r;
|
|
925
925
|
}
|
|
926
|
-
},
|
|
927
|
-
function
|
|
928
|
-
let t =
|
|
926
|
+
}, an = "traceparent", on = "tracestate", sn = "00", cn = /* @__PURE__ */ RegExp("^\\s?((?!ff)[\\da-f]{2})-((?![0]{32})[\\da-f]{32})-((?![0]{16})[\\da-f]{16})-([\\da-f]{2})(-.*)?\\s?$");
|
|
927
|
+
function ln(e) {
|
|
928
|
+
let t = cn.exec(e);
|
|
929
929
|
return !t || t[1] === "00" && t[5] ? null : {
|
|
930
930
|
traceId: t[2],
|
|
931
931
|
spanId: t[3],
|
|
932
932
|
traceFlags: parseInt(t[4], 16)
|
|
933
933
|
};
|
|
934
934
|
}
|
|
935
|
-
var
|
|
935
|
+
var un = class {
|
|
936
936
|
inject(e, t, n) {
|
|
937
|
-
let r =
|
|
938
|
-
if (!r ||
|
|
939
|
-
let i = `${
|
|
940
|
-
n.set(t,
|
|
937
|
+
let r = D.getSpanContext(e);
|
|
938
|
+
if (!r || yt(e) || !Je(r)) return;
|
|
939
|
+
let i = `${sn}-${r.traceId}-${r.spanId}-0${Number(r.traceFlags || x.NONE).toString(16)}`;
|
|
940
|
+
n.set(t, an, i), r.traceState && n.set(t, on, r.traceState.serialize());
|
|
941
941
|
}
|
|
942
942
|
extract(e, t, n) {
|
|
943
|
-
let r = n.get(t,
|
|
943
|
+
let r = n.get(t, an);
|
|
944
944
|
if (!r) return e;
|
|
945
945
|
let i = Array.isArray(r) ? r[0] : r;
|
|
946
946
|
if (typeof i != "string") return e;
|
|
947
|
-
let a =
|
|
947
|
+
let a = ln(i);
|
|
948
948
|
if (!a) return e;
|
|
949
949
|
a.isRemote = !0;
|
|
950
|
-
let o = n.get(t,
|
|
950
|
+
let o = n.get(t, on);
|
|
951
951
|
if (o) {
|
|
952
952
|
let e = Array.isArray(o) ? o.join(",") : o;
|
|
953
|
-
a.traceState = new
|
|
953
|
+
a.traceState = new rn(typeof e == "string" ? e : void 0);
|
|
954
954
|
}
|
|
955
|
-
return
|
|
955
|
+
return D.setSpanContext(e, a);
|
|
956
956
|
}
|
|
957
957
|
fields() {
|
|
958
|
-
return [
|
|
958
|
+
return [an, on];
|
|
959
959
|
}
|
|
960
|
-
},
|
|
961
|
-
function yn(e) {
|
|
962
|
-
if (!bn(e) || xn(e) !== un) return !1;
|
|
963
|
-
let t = hn(e);
|
|
964
|
-
if (t === null) return !0;
|
|
965
|
-
let n = _n.call(t, "constructor") && t.constructor;
|
|
966
|
-
return typeof n == "function" && n instanceof n && pn.call(n) === mn;
|
|
967
|
-
}
|
|
960
|
+
}, dn = "[object Object]", fn = "[object Null]", pn = "[object Undefined]", mn = Function.prototype.toString, hn = mn.call(Object), gn = Object.getPrototypeOf, _n = Object.prototype, vn = _n.hasOwnProperty, I = Symbol ? Symbol.toStringTag : void 0, yn = _n.toString;
|
|
968
961
|
function bn(e) {
|
|
969
|
-
|
|
962
|
+
if (!xn(e) || Sn(e) !== dn) return !1;
|
|
963
|
+
let t = gn(e);
|
|
964
|
+
if (t === null) return !0;
|
|
965
|
+
let n = vn.call(t, "constructor") && t.constructor;
|
|
966
|
+
return typeof n == "function" && n instanceof n && mn.call(n) === hn;
|
|
970
967
|
}
|
|
971
968
|
function xn(e) {
|
|
972
|
-
return e ==
|
|
969
|
+
return typeof e == "object" && !!e;
|
|
973
970
|
}
|
|
974
971
|
function Sn(e) {
|
|
975
|
-
|
|
972
|
+
return e == null ? e === void 0 ? pn : fn : I && I in Object(e) ? Cn(e) : wn(e);
|
|
973
|
+
}
|
|
974
|
+
function Cn(e) {
|
|
975
|
+
let t = vn.call(e, I), n = e[I], r = !1;
|
|
976
976
|
try {
|
|
977
|
-
e[
|
|
977
|
+
e[I] = void 0, r = !0;
|
|
978
978
|
} catch {}
|
|
979
|
-
let i =
|
|
980
|
-
return r && (t ? e[
|
|
979
|
+
let i = yn.call(e);
|
|
980
|
+
return r && (t ? e[I] = n : delete e[I]), i;
|
|
981
981
|
}
|
|
982
|
-
function
|
|
983
|
-
return
|
|
982
|
+
function wn(e) {
|
|
983
|
+
return yn.call(e);
|
|
984
984
|
}
|
|
985
985
|
//#endregion
|
|
986
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
987
|
-
var
|
|
988
|
-
function
|
|
986
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/utils/merge.js
|
|
987
|
+
var Tn = 20;
|
|
988
|
+
function En(...e) {
|
|
989
989
|
let t = e.shift(), n = /* @__PURE__ */ new WeakMap();
|
|
990
|
-
for (; e.length > 0;) t =
|
|
990
|
+
for (; e.length > 0;) t = On(t, e.shift(), 0, n);
|
|
991
991
|
return t;
|
|
992
992
|
}
|
|
993
|
-
function
|
|
994
|
-
return
|
|
993
|
+
function Dn(e) {
|
|
994
|
+
return An(e) ? e.slice() : e;
|
|
995
995
|
}
|
|
996
|
-
function
|
|
996
|
+
function On(e, t, n = 0, r) {
|
|
997
997
|
let i;
|
|
998
|
-
if (!(n >
|
|
999
|
-
if (n++,
|
|
1000
|
-
else if (
|
|
1001
|
-
if (i = e.slice(),
|
|
1002
|
-
else if (
|
|
998
|
+
if (!(n > Tn)) {
|
|
999
|
+
if (n++, Mn(e) || Mn(t) || jn(t)) i = Dn(t);
|
|
1000
|
+
else if (An(e)) {
|
|
1001
|
+
if (i = e.slice(), An(t)) for (let e = 0, n = t.length; e < n; e++) i.push(Dn(t[e]));
|
|
1002
|
+
else if (L(t)) {
|
|
1003
1003
|
let e = Object.keys(t);
|
|
1004
1004
|
for (let n = 0, r = e.length; n < r; n++) {
|
|
1005
1005
|
let r = e[n];
|
|
1006
|
-
r !== "__proto__" && r !== "constructor" && r !== "prototype" && (i[r] =
|
|
1006
|
+
r !== "__proto__" && r !== "constructor" && r !== "prototype" && (i[r] = Dn(t[r]));
|
|
1007
1007
|
}
|
|
1008
1008
|
}
|
|
1009
|
-
} else if (
|
|
1010
|
-
if (
|
|
1011
|
-
if (!
|
|
1009
|
+
} else if (L(e)) {
|
|
1010
|
+
if (L(t)) {
|
|
1011
|
+
if (!Nn(e, t)) return t;
|
|
1012
1012
|
i = Object.assign({}, e);
|
|
1013
1013
|
let a = Object.keys(t);
|
|
1014
1014
|
for (let o = 0, s = a.length; o < s; o++) {
|
|
1015
1015
|
let s = a[o];
|
|
1016
1016
|
if (s === "__proto__" || s === "constructor" || s === "prototype") continue;
|
|
1017
1017
|
let c = t[s];
|
|
1018
|
-
if (
|
|
1018
|
+
if (Mn(c)) c === void 0 ? delete i[s] : i[s] = c;
|
|
1019
1019
|
else {
|
|
1020
1020
|
let a = i[s], o = c;
|
|
1021
|
-
if (
|
|
1021
|
+
if (kn(e, s, r) || kn(t, s, r)) delete i[s];
|
|
1022
1022
|
else {
|
|
1023
|
-
if (
|
|
1023
|
+
if (L(a) && L(o)) {
|
|
1024
1024
|
let n = r.get(a) || [], i = r.get(o) || [];
|
|
1025
1025
|
n.push({
|
|
1026
1026
|
obj: e,
|
|
@@ -1030,7 +1030,7 @@ function Dn(e, t, n = 0, r) {
|
|
|
1030
1030
|
key: s
|
|
1031
1031
|
}), r.set(a, n), r.set(o, i);
|
|
1032
1032
|
}
|
|
1033
|
-
i[s] =
|
|
1033
|
+
i[s] = On(i[s], c, n, r);
|
|
1034
1034
|
}
|
|
1035
1035
|
}
|
|
1036
1036
|
}
|
|
@@ -1039,7 +1039,7 @@ function Dn(e, t, n = 0, r) {
|
|
|
1039
1039
|
return i;
|
|
1040
1040
|
}
|
|
1041
1041
|
}
|
|
1042
|
-
function
|
|
1042
|
+
function kn(e, t, n) {
|
|
1043
1043
|
let r = n.get(e[t]) || [];
|
|
1044
1044
|
for (let n = 0, i = r.length; n < i; n++) {
|
|
1045
1045
|
let i = r[n];
|
|
@@ -1047,34 +1047,34 @@ function On(e, t, n) {
|
|
|
1047
1047
|
}
|
|
1048
1048
|
return !1;
|
|
1049
1049
|
}
|
|
1050
|
-
function
|
|
1050
|
+
function An(e) {
|
|
1051
1051
|
return Array.isArray(e);
|
|
1052
1052
|
}
|
|
1053
|
-
function
|
|
1053
|
+
function jn(e) {
|
|
1054
1054
|
return typeof e == "function";
|
|
1055
1055
|
}
|
|
1056
|
-
function
|
|
1057
|
-
return !
|
|
1056
|
+
function L(e) {
|
|
1057
|
+
return !Mn(e) && !An(e) && !jn(e) && typeof e == "object";
|
|
1058
1058
|
}
|
|
1059
|
-
function
|
|
1059
|
+
function Mn(e) {
|
|
1060
1060
|
return typeof e == "string" || typeof e == "number" || typeof e == "boolean" || e === void 0 || e instanceof Date || e instanceof RegExp || e === null;
|
|
1061
1061
|
}
|
|
1062
|
-
function
|
|
1063
|
-
return !(!
|
|
1062
|
+
function Nn(e, t) {
|
|
1063
|
+
return !(!bn(e) || !bn(t));
|
|
1064
1064
|
}
|
|
1065
1065
|
//#endregion
|
|
1066
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
1067
|
-
function
|
|
1066
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/utils/url.js
|
|
1067
|
+
function Pn(e, t) {
|
|
1068
1068
|
return typeof t == "string" ? e === t : !!e.match(t);
|
|
1069
1069
|
}
|
|
1070
|
-
function
|
|
1070
|
+
function Fn(e, t) {
|
|
1071
1071
|
if (!t) return !1;
|
|
1072
|
-
for (let n of t) if (
|
|
1072
|
+
for (let n of t) if (Pn(e, n)) return !0;
|
|
1073
1073
|
return !1;
|
|
1074
1074
|
}
|
|
1075
1075
|
//#endregion
|
|
1076
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.
|
|
1077
|
-
var
|
|
1076
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+core@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/core/build/esm/utils/promise.js
|
|
1077
|
+
var In = class {
|
|
1078
1078
|
_promise;
|
|
1079
1079
|
_resolve;
|
|
1080
1080
|
_reject;
|
|
@@ -1092,9 +1092,9 @@ var Fn = class {
|
|
|
1092
1092
|
reject(e) {
|
|
1093
1093
|
this._reject(e);
|
|
1094
1094
|
}
|
|
1095
|
-
},
|
|
1095
|
+
}, Ln = class {
|
|
1096
1096
|
_isCalled = !1;
|
|
1097
|
-
_deferred = new
|
|
1097
|
+
_deferred = new In();
|
|
1098
1098
|
_callback;
|
|
1099
1099
|
_that;
|
|
1100
1100
|
constructor(e, t) {
|
|
@@ -1117,30 +1117,30 @@ var Fn = class {
|
|
|
1117
1117
|
}
|
|
1118
1118
|
return this._deferred.promise;
|
|
1119
1119
|
}
|
|
1120
|
-
},
|
|
1121
|
-
function
|
|
1122
|
-
if (
|
|
1120
|
+
}, Rn;
|
|
1121
|
+
function zn() {
|
|
1122
|
+
if (Rn === void 0) try {
|
|
1123
1123
|
let e = globalThis.process.argv0;
|
|
1124
|
-
|
|
1124
|
+
Rn = e ? `unknown_service:${e}` : "unknown_service";
|
|
1125
1125
|
} catch {
|
|
1126
|
-
|
|
1126
|
+
Rn = "unknown_service";
|
|
1127
1127
|
}
|
|
1128
|
-
return
|
|
1128
|
+
return Rn;
|
|
1129
1129
|
}
|
|
1130
1130
|
//#endregion
|
|
1131
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.
|
|
1132
|
-
var
|
|
1131
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+resources@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/resources/build/esm/utils.js
|
|
1132
|
+
var R = (e) => typeof e == "object" && !!e && typeof e.then == "function", Bn = class e {
|
|
1133
1133
|
_rawAttributes;
|
|
1134
1134
|
_asyncAttributesPending = !1;
|
|
1135
1135
|
_schemaUrl;
|
|
1136
1136
|
_memoizedAttributes;
|
|
1137
1137
|
static FromAttributeList(t, n) {
|
|
1138
1138
|
let r = new e({}, n);
|
|
1139
|
-
return r._rawAttributes =
|
|
1139
|
+
return r._rawAttributes = Un(t), r._asyncAttributesPending = t.filter(([e, t]) => R(t)).length > 0, r;
|
|
1140
1140
|
}
|
|
1141
1141
|
constructor(e, t) {
|
|
1142
1142
|
let n = e.attributes ?? {};
|
|
1143
|
-
this._rawAttributes = Object.entries(n).map(([e, t]) => (
|
|
1143
|
+
this._rawAttributes = Object.entries(n).map(([e, t]) => (R(t) && (this._asyncAttributesPending = !0), [e, t])), this._rawAttributes = Un(this._rawAttributes), this._schemaUrl = Wn(t?.schemaUrl);
|
|
1144
1144
|
}
|
|
1145
1145
|
get asyncAttributesPending() {
|
|
1146
1146
|
return this._asyncAttributesPending;
|
|
@@ -1149,17 +1149,17 @@ var z = (e) => typeof e == "object" && !!e && typeof e.then == "function", zn =
|
|
|
1149
1149
|
if (this.asyncAttributesPending) {
|
|
1150
1150
|
for (let e = 0; e < this._rawAttributes.length; e++) {
|
|
1151
1151
|
let [t, n] = this._rawAttributes[e];
|
|
1152
|
-
this._rawAttributes[e] = [t,
|
|
1152
|
+
this._rawAttributes[e] = [t, R(n) ? await n : n];
|
|
1153
1153
|
}
|
|
1154
1154
|
this._asyncAttributesPending = !1;
|
|
1155
1155
|
}
|
|
1156
1156
|
}
|
|
1157
1157
|
get attributes() {
|
|
1158
|
-
if (this.asyncAttributesPending &&
|
|
1158
|
+
if (this.asyncAttributesPending && T.error("Accessing resource attributes before async attributes settled"), this._memoizedAttributes) return this._memoizedAttributes;
|
|
1159
1159
|
let e = {};
|
|
1160
1160
|
for (let [t, n] of this._rawAttributes) {
|
|
1161
|
-
if (
|
|
1162
|
-
|
|
1161
|
+
if (R(n)) {
|
|
1162
|
+
T.debug(`Unsettled resource attribute ${t} skipped`);
|
|
1163
1163
|
continue;
|
|
1164
1164
|
}
|
|
1165
1165
|
n != null && (e[t] ??= n);
|
|
@@ -1174,45 +1174,45 @@ var z = (e) => typeof e == "object" && !!e && typeof e.then == "function", zn =
|
|
|
1174
1174
|
}
|
|
1175
1175
|
merge(t) {
|
|
1176
1176
|
if (t == null) return this;
|
|
1177
|
-
let n =
|
|
1177
|
+
let n = Gn(this, t), r = n ? { schemaUrl: n } : void 0;
|
|
1178
1178
|
return e.FromAttributeList([...t.getRawAttributes(), ...this.getRawAttributes()], r);
|
|
1179
1179
|
}
|
|
1180
1180
|
};
|
|
1181
|
-
function
|
|
1182
|
-
return
|
|
1183
|
-
}
|
|
1184
|
-
function
|
|
1185
|
-
return
|
|
1186
|
-
[r]:
|
|
1187
|
-
[i]:
|
|
1188
|
-
[o]:
|
|
1189
|
-
[s]:
|
|
1181
|
+
function Vn(e, t) {
|
|
1182
|
+
return Bn.FromAttributeList(Object.entries(e), t);
|
|
1183
|
+
}
|
|
1184
|
+
function Hn() {
|
|
1185
|
+
return Vn({
|
|
1186
|
+
[r]: zn(),
|
|
1187
|
+
[i]: Lt[i],
|
|
1188
|
+
[o]: Lt[o],
|
|
1189
|
+
[s]: Lt[s]
|
|
1190
1190
|
});
|
|
1191
1191
|
}
|
|
1192
|
-
function
|
|
1193
|
-
return e.map(([e, t]) =>
|
|
1194
|
-
|
|
1192
|
+
function Un(e) {
|
|
1193
|
+
return e.map(([e, t]) => R(t) ? [e, t.catch((t) => {
|
|
1194
|
+
T.debug("promise rejection for resource attribute: %s - %s", e, t);
|
|
1195
1195
|
})] : [e, t]);
|
|
1196
1196
|
}
|
|
1197
|
-
function
|
|
1197
|
+
function Wn(e) {
|
|
1198
1198
|
if (typeof e == "string" || e === void 0) return e;
|
|
1199
|
-
|
|
1199
|
+
T.warn("Schema URL must be string or undefined, got %s. Schema URL will be ignored.", e);
|
|
1200
1200
|
}
|
|
1201
|
-
function
|
|
1201
|
+
function Gn(e, t) {
|
|
1202
1202
|
let n = e?.schemaUrl, r = t?.schemaUrl, i = n === void 0 || n === "", a = r === void 0 || r === "";
|
|
1203
1203
|
if (i) return r;
|
|
1204
1204
|
if (a || n === r) return n;
|
|
1205
|
-
|
|
1205
|
+
T.warn("Schema URL merge conflict: old resource has \"%s\", updating resource has \"%s\". Resulting resource will have undefined Schema URL.", n, r);
|
|
1206
1206
|
}
|
|
1207
1207
|
//#endregion
|
|
1208
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.
|
|
1209
|
-
var
|
|
1210
|
-
function
|
|
1208
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace/build/esm/enums.js
|
|
1209
|
+
var Kn = "exception", qn = Symbol.for("nodejs.util.inspect.custom");
|
|
1210
|
+
function Jn(e) {
|
|
1211
1211
|
let t = {};
|
|
1212
1212
|
for (let [n, r] of e.getRawAttributes()) typeof r?.then != "function" && r != null && (t[n] ??= r);
|
|
1213
1213
|
return t;
|
|
1214
1214
|
}
|
|
1215
|
-
function
|
|
1215
|
+
function Yn(e, t, n, r, i) {
|
|
1216
1216
|
if (typeof n == "number" && n < 0) {
|
|
1217
1217
|
let t = `[${e}]`;
|
|
1218
1218
|
return r?.stylize ? r.stylize(t, "special") : t;
|
|
@@ -1223,8 +1223,8 @@ function Jn(e, t, n, r, i) {
|
|
|
1223
1223
|
})}`;
|
|
1224
1224
|
}
|
|
1225
1225
|
//#endregion
|
|
1226
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.
|
|
1227
|
-
var
|
|
1226
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace/build/esm/Span.js
|
|
1227
|
+
var Xn = class {
|
|
1228
1228
|
_spanContext;
|
|
1229
1229
|
kind;
|
|
1230
1230
|
parentSpanContext;
|
|
@@ -1239,7 +1239,7 @@ var Yn = class {
|
|
|
1239
1239
|
_droppedLinksCount = 0;
|
|
1240
1240
|
_attributesCount = 0;
|
|
1241
1241
|
name;
|
|
1242
|
-
status = { code:
|
|
1242
|
+
status = { code: C.UNSET };
|
|
1243
1243
|
endTime = [0, 0];
|
|
1244
1244
|
_ended = !1;
|
|
1245
1245
|
_duration = [-1, -1];
|
|
@@ -1252,7 +1252,7 @@ var Yn = class {
|
|
|
1252
1252
|
_startTimeProvided;
|
|
1253
1253
|
constructor(e) {
|
|
1254
1254
|
let t = Date.now();
|
|
1255
|
-
if (this._spanContext = e.spanContext, this._performanceStartTime =
|
|
1255
|
+
if (this._spanContext = e.spanContext, this._performanceStartTime = A.now(), this._performanceOffset = t - (this._performanceStartTime + A.timeOrigin), this._startTimeProvided = e.startTime != null, this._spanLimits = e.spanLimits, this._attributeValueLengthLimit = this._spanLimits.attributeValueLengthLimit ?? 0, this._spanProcessor = e.spanProcessor, this.name = e.name, this.parentSpanContext = e.parentSpanContext, this.kind = e.kind, e.links) for (let t of e.links) this.addLink(t);
|
|
1256
1256
|
this.startTime = this._getTime(e.startTime ?? t), this.resource = e.resource, this.instrumentationScope = e.scope, this._recordEndMetrics = e.recordEndMetrics, e.attributes != null && this.setAttributes(e.attributes), this._spanProcessor.onStart(this, e.context);
|
|
1257
1257
|
}
|
|
1258
1258
|
spanContext() {
|
|
@@ -1260,8 +1260,8 @@ var Yn = class {
|
|
|
1260
1260
|
}
|
|
1261
1261
|
setAttribute(e, t) {
|
|
1262
1262
|
if (t == null || this._isSpanEnded()) return this;
|
|
1263
|
-
if (e.length === 0) return
|
|
1264
|
-
if (!
|
|
1263
|
+
if (e.length === 0) return T.warn(`Invalid attribute key: ${e}`), this;
|
|
1264
|
+
if (!Ot(t)) return T.warn(`Invalid attribute value set for key: ${e}`), this;
|
|
1265
1265
|
let { attributeCountLimit: n } = this._spanLimits, r = !Object.prototype.hasOwnProperty.call(this.attributes, e);
|
|
1266
1266
|
return n !== void 0 && this._attributesCount >= n && r ? (this._droppedAttributesCount++, this) : (this.attributes[e] = this._truncateToSize(t), r && this._attributesCount++, this);
|
|
1267
1267
|
}
|
|
@@ -1272,9 +1272,9 @@ var Yn = class {
|
|
|
1272
1272
|
addEvent(e, t, n) {
|
|
1273
1273
|
if (this._isSpanEnded()) return this;
|
|
1274
1274
|
let { eventCountLimit: r } = this._spanLimits;
|
|
1275
|
-
if (r === 0) return
|
|
1276
|
-
r !== void 0 && this.events.length >= r && (this._droppedEventsCount === 0 &&
|
|
1277
|
-
let i =
|
|
1275
|
+
if (r === 0) return T.warn("No events allowed."), this._droppedEventsCount++, this;
|
|
1276
|
+
r !== void 0 && this.events.length >= r && (this._droppedEventsCount === 0 && T.debug("Dropping extra events."), this.events.shift(), this._droppedEventsCount++), Wt(t) && (Wt(n) || (n = t), t = void 0);
|
|
1277
|
+
let i = O(t), { attributePerEventCountLimit: a } = this._spanLimits, o = {}, s = 0, c = 0;
|
|
1278
1278
|
for (let e in i) {
|
|
1279
1279
|
if (!Object.prototype.hasOwnProperty.call(i, e)) continue;
|
|
1280
1280
|
let t = i[e];
|
|
@@ -1295,8 +1295,8 @@ var Yn = class {
|
|
|
1295
1295
|
if (this._isSpanEnded()) return this;
|
|
1296
1296
|
let { linkCountLimit: t } = this._spanLimits;
|
|
1297
1297
|
if (t === 0) return this._droppedLinksCount++, this;
|
|
1298
|
-
t !== void 0 && this.links.length >= t && (this._droppedLinksCount === 0 &&
|
|
1299
|
-
let { attributePerLinkCountLimit: n } = this._spanLimits, r =
|
|
1298
|
+
t !== void 0 && this.links.length >= t && (this._droppedLinksCount === 0 && T.debug("Dropping extra links."), this.links.shift(), this._droppedLinksCount++);
|
|
1299
|
+
let { attributePerLinkCountLimit: n } = this._spanLimits, r = O(e.attributes), i = {}, a = 0, o = 0;
|
|
1300
1300
|
for (let e in r) {
|
|
1301
1301
|
if (!Object.prototype.hasOwnProperty.call(r, e)) continue;
|
|
1302
1302
|
let t = r[e];
|
|
@@ -1314,35 +1314,35 @@ var Yn = class {
|
|
|
1314
1314
|
return this;
|
|
1315
1315
|
}
|
|
1316
1316
|
setStatus(e) {
|
|
1317
|
-
if (this._isSpanEnded() || e.code ===
|
|
1317
|
+
if (this._isSpanEnded() || e.code === C.UNSET || this.status.code === C.OK) return this;
|
|
1318
1318
|
let t = { code: e.code };
|
|
1319
|
-
return e.code ===
|
|
1319
|
+
return e.code === C.ERROR && (typeof e.message == "string" ? t.message = e.message : e.message != null && T.warn(`Dropping invalid status.message of type '${typeof e.message}', expected 'string'`)), this.status = t, this;
|
|
1320
1320
|
}
|
|
1321
1321
|
updateName(e) {
|
|
1322
1322
|
return this._isSpanEnded() || (this.name = e), this;
|
|
1323
1323
|
}
|
|
1324
1324
|
end(e) {
|
|
1325
1325
|
if (this._isSpanEnded()) {
|
|
1326
|
-
|
|
1326
|
+
T.error(`${this.name} ${this._spanContext.traceId}-${this._spanContext.spanId} - You can only call end() on a span once.`);
|
|
1327
1327
|
return;
|
|
1328
1328
|
}
|
|
1329
|
-
this.endTime = this._getTime(e), this._duration =
|
|
1329
|
+
this.endTime = this._getTime(e), this._duration = Vt(this.startTime, this.endTime), this._duration[0] < 0 && (T.warn("Inconsistent start and end time, startTime > endTime. Setting span duration to 0ms.", this.startTime, this.endTime), this.endTime = this.startTime.slice(), this._duration = [0, 0]), this._droppedEventsCount > 0 && T.warn(`Dropped ${this._droppedEventsCount} events because eventCountLimit reached`), this._droppedLinksCount > 0 && T.warn(`Dropped ${this._droppedLinksCount} links because linkCountLimit reached`), this._spanProcessor.onEnding && this._spanProcessor.onEnding(this), this._recordEndMetrics?.(), this._ended = !0, this._spanProcessor.onEnd(this);
|
|
1330
1330
|
}
|
|
1331
1331
|
_getTime(e) {
|
|
1332
|
-
if (typeof e == "number" && e <=
|
|
1333
|
-
if (typeof e == "number") return
|
|
1334
|
-
if (e instanceof Date) return
|
|
1335
|
-
if (
|
|
1336
|
-
if (this._startTimeProvided) return
|
|
1337
|
-
let t =
|
|
1338
|
-
return
|
|
1332
|
+
if (typeof e == "number" && e <= A.now()) return M(e + this._performanceOffset);
|
|
1333
|
+
if (typeof e == "number") return j(e);
|
|
1334
|
+
if (e instanceof Date) return j(e.getTime());
|
|
1335
|
+
if (Ut(e)) return e;
|
|
1336
|
+
if (this._startTimeProvided) return j(Date.now());
|
|
1337
|
+
let t = A.now() - this._performanceStartTime;
|
|
1338
|
+
return Gt(this.startTime, j(t));
|
|
1339
1339
|
}
|
|
1340
1340
|
isRecording() {
|
|
1341
1341
|
return this._ended === !1;
|
|
1342
1342
|
}
|
|
1343
1343
|
recordException(e, r) {
|
|
1344
1344
|
let i = {};
|
|
1345
|
-
typeof e == "string" ? i[t] = e : e && (e.code ? i[n] = e.code.toString() : e.name && (i[n] = e.name), e.message && (i[t] = e.message), e.stack && (i["exception.stacktrace"] = e.stack)), i["exception.type"] || i["exception.message"] ? this.addEvent(
|
|
1345
|
+
typeof e == "string" ? i[t] = e : e && (e.code ? i[n] = e.code.toString() : e.name && (i[n] = e.name), e.message && (i[t] = e.message), e.stack && (i["exception.stacktrace"] = e.stack)), i["exception.type"] || i["exception.message"] ? this.addEvent(Kn, i, r) : T.warn(`Failed to record an exception ${e}`);
|
|
1346
1346
|
}
|
|
1347
1347
|
get duration() {
|
|
1348
1348
|
return this._duration;
|
|
@@ -1362,7 +1362,7 @@ var Yn = class {
|
|
|
1362
1362
|
_isSpanEnded() {
|
|
1363
1363
|
if (this._ended) {
|
|
1364
1364
|
let e = /* @__PURE__ */ Error(`Operation attempted on ended Span {traceId: ${this._spanContext.traceId}, spanId: ${this._spanContext.spanId}}`);
|
|
1365
|
-
|
|
1365
|
+
T.warn(`Cannot execute the operation on ended Span {traceId: ${this._spanContext.traceId}, spanId: ${this._spanContext.spanId}}`, e);
|
|
1366
1366
|
}
|
|
1367
1367
|
return this._ended;
|
|
1368
1368
|
}
|
|
@@ -1371,10 +1371,10 @@ var Yn = class {
|
|
|
1371
1371
|
}
|
|
1372
1372
|
_truncateToSize(e) {
|
|
1373
1373
|
let t = this._attributeValueLengthLimit;
|
|
1374
|
-
return t <= 0 ? (
|
|
1374
|
+
return t <= 0 ? (T.warn(`Attribute value limit must be positive, got ${t}`), e) : typeof e == "string" ? this._truncateToLimitUtil(e, t) : Array.isArray(e) ? e.map((e) => typeof e == "string" ? this._truncateToLimitUtil(e, t) : e) : e;
|
|
1375
1375
|
}
|
|
1376
|
-
[
|
|
1377
|
-
return
|
|
1376
|
+
[qn](e, t, n) {
|
|
1377
|
+
return Yn("SpanImpl", {
|
|
1378
1378
|
name: this.name,
|
|
1379
1379
|
kind: this.kind,
|
|
1380
1380
|
spanContext: this._spanContext,
|
|
@@ -1391,52 +1391,52 @@ var Yn = class {
|
|
|
1391
1391
|
droppedEventsCount: this._droppedEventsCount,
|
|
1392
1392
|
droppedLinksCount: this._droppedLinksCount,
|
|
1393
1393
|
instrumentationScope: this.instrumentationScope,
|
|
1394
|
-
resource: { attributes:
|
|
1394
|
+
resource: { attributes: Jn(this.resource) }
|
|
1395
1395
|
}, e, t, n);
|
|
1396
1396
|
}
|
|
1397
|
-
},
|
|
1397
|
+
}, z;
|
|
1398
1398
|
(function(e) {
|
|
1399
1399
|
e[e.NOT_RECORD = 0] = "NOT_RECORD", e[e.RECORD = 1] = "RECORD", e[e.RECORD_AND_SAMPLED = 2] = "RECORD_AND_SAMPLED";
|
|
1400
|
-
})(
|
|
1400
|
+
})(z ||= {});
|
|
1401
1401
|
//#endregion
|
|
1402
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.
|
|
1403
|
-
var
|
|
1402
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace/build/esm/semconv.js
|
|
1403
|
+
var Zn = "otel.component.name", Qn = "otel.component.type", $n = "otel.span.parent.origin", er = "otel.span.sampling_result", tr = "otel.sdk.processor.span.processed", nr = "otel.sdk.processor.span.queue.capacity", rr = "otel.sdk.processor.span.queue.size", ir = "otel.sdk.span.live", ar = "otel.sdk.span.started", or = "batching_span_processor", sr = class {
|
|
1404
1404
|
startedSpans;
|
|
1405
1405
|
liveSpans;
|
|
1406
1406
|
constructor(e) {
|
|
1407
|
-
this.startedSpans = e.createCounter(
|
|
1407
|
+
this.startedSpans = e.createCounter(ar, {
|
|
1408
1408
|
unit: "{span}",
|
|
1409
1409
|
description: "The number of created spans."
|
|
1410
|
-
}), this.liveSpans = e.createUpDownCounter(
|
|
1410
|
+
}), this.liveSpans = e.createUpDownCounter(ir, {
|
|
1411
1411
|
unit: "{span}",
|
|
1412
1412
|
description: "The number of currently live spans."
|
|
1413
1413
|
});
|
|
1414
1414
|
}
|
|
1415
1415
|
startSpan(e, t) {
|
|
1416
|
-
let n =
|
|
1416
|
+
let n = lr(t);
|
|
1417
1417
|
if (this.startedSpans.add(1, {
|
|
1418
|
-
[
|
|
1419
|
-
[
|
|
1420
|
-
}), t ===
|
|
1421
|
-
let r = { [
|
|
1418
|
+
[$n]: cr(e),
|
|
1419
|
+
[er]: n
|
|
1420
|
+
}), t === z.NOT_RECORD) return () => {};
|
|
1421
|
+
let r = { [er]: n };
|
|
1422
1422
|
return this.liveSpans.add(1, r), () => {
|
|
1423
1423
|
this.liveSpans.add(-1, r);
|
|
1424
1424
|
};
|
|
1425
1425
|
}
|
|
1426
1426
|
};
|
|
1427
|
-
function
|
|
1427
|
+
function cr(e) {
|
|
1428
1428
|
return e ? e.isRemote ? "remote" : "local" : "none";
|
|
1429
1429
|
}
|
|
1430
|
-
function
|
|
1430
|
+
function lr(e) {
|
|
1431
1431
|
switch (e) {
|
|
1432
|
-
case
|
|
1433
|
-
case
|
|
1434
|
-
case
|
|
1432
|
+
case z.RECORD_AND_SAMPLED: return "RECORD_AND_SAMPLE";
|
|
1433
|
+
case z.RECORD: return "RECORD_ONLY";
|
|
1434
|
+
case z.NOT_RECORD: return "DROP";
|
|
1435
1435
|
}
|
|
1436
1436
|
}
|
|
1437
1437
|
//#endregion
|
|
1438
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.
|
|
1439
|
-
var
|
|
1438
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace/build/esm/version.js
|
|
1439
|
+
var ur = "2.11.0", dr = class {
|
|
1440
1440
|
_sampler;
|
|
1441
1441
|
_spanLimits;
|
|
1442
1442
|
_idGenerator;
|
|
@@ -1446,29 +1446,29 @@ var lr = "2.10.0", ur = class {
|
|
|
1446
1446
|
_tracerMetrics;
|
|
1447
1447
|
constructor(e, t) {
|
|
1448
1448
|
this.instrumentationScope = e, this._sampler = t.sampler, this._spanLimits = t.spanLimits, this._resource = t.resource, this._idGenerator = t.idGenerator, this._spanProcessor = t.spanProcessor;
|
|
1449
|
-
let n = t.meterProvider.getMeter("@opentelemetry/sdk-trace",
|
|
1450
|
-
this._tracerMetrics = new
|
|
1449
|
+
let n = t.meterProvider.getMeter("@opentelemetry/sdk-trace", ur);
|
|
1450
|
+
this._tracerMetrics = new sr(n);
|
|
1451
1451
|
}
|
|
1452
|
-
startSpan(e, t = {}, n =
|
|
1453
|
-
t.root && (n =
|
|
1454
|
-
let r =
|
|
1455
|
-
if (
|
|
1452
|
+
startSpan(e, t = {}, n = w.active()) {
|
|
1453
|
+
t.root && (n = D.deleteSpan(n));
|
|
1454
|
+
let r = D.getSpan(n);
|
|
1455
|
+
if (yt(n)) return T.debug("Instrumentation suppressed, returning Noop Span"), D.wrapSpanContext(Ie);
|
|
1456
1456
|
let i = r?.spanContext(), a = this._idGenerator.generateSpanId(), o, s, c;
|
|
1457
|
-
!i || !
|
|
1458
|
-
let l = t.kind ??
|
|
1457
|
+
!i || !D.isSpanContextValid(i) ? s = this._idGenerator.generateTraceId() : (s = i.traceId, c = i.traceState, o = i);
|
|
1458
|
+
let l = t.kind ?? it.INTERNAL, u = (t.links ?? []).map((e) => ({
|
|
1459
1459
|
context: e.context,
|
|
1460
|
-
attributes:
|
|
1461
|
-
})), ee =
|
|
1460
|
+
attributes: O(e.attributes)
|
|
1461
|
+
})), ee = O(t.attributes), d = this._sampler.shouldSample(n, s, e, l, ee, u), te = this._tracerMetrics.startSpan(i, d.decision);
|
|
1462
1462
|
c = d.traceState ?? c;
|
|
1463
|
-
let f = d.decision ===
|
|
1463
|
+
let f = d.decision === rt.RECORD_AND_SAMPLED ? x.SAMPLED : x.NONE, p = {
|
|
1464
1464
|
traceId: s,
|
|
1465
1465
|
spanId: a,
|
|
1466
1466
|
traceFlags: f,
|
|
1467
1467
|
traceState: c
|
|
1468
1468
|
};
|
|
1469
|
-
if (d.decision ===
|
|
1470
|
-
let m =
|
|
1471
|
-
return new
|
|
1469
|
+
if (d.decision === rt.NOT_RECORD) return T.debug("Recording is off, propagating context in a non-recording span"), D.wrapSpanContext(p);
|
|
1470
|
+
let m = O(Object.assign(ee, d.attributes));
|
|
1471
|
+
return new Xn({
|
|
1472
1472
|
resource: this._resource,
|
|
1473
1473
|
scope: this.instrumentationScope,
|
|
1474
1474
|
context: n,
|
|
@@ -1488,17 +1488,17 @@ var lr = "2.10.0", ur = class {
|
|
|
1488
1488
|
let i, a, o;
|
|
1489
1489
|
if (arguments.length < 2) return;
|
|
1490
1490
|
arguments.length === 2 ? o = t : arguments.length === 3 ? (i = t, o = n) : (i = t, a = n, o = r);
|
|
1491
|
-
let s = a ??
|
|
1492
|
-
return
|
|
1491
|
+
let s = a ?? w.active(), c = this.startSpan(e, i, s), l = D.setSpan(s, c);
|
|
1492
|
+
return w.with(l, o, void 0, c);
|
|
1493
1493
|
}
|
|
1494
|
-
[
|
|
1495
|
-
return
|
|
1494
|
+
[qn](e, t, n) {
|
|
1495
|
+
return Yn("Tracer", {
|
|
1496
1496
|
instrumentationScope: this.instrumentationScope,
|
|
1497
|
-
resource: { attributes:
|
|
1497
|
+
resource: { attributes: Jn(this._resource) },
|
|
1498
1498
|
spanLimits: this._spanLimits
|
|
1499
1499
|
}, e, t, n);
|
|
1500
1500
|
}
|
|
1501
|
-
},
|
|
1501
|
+
}, fr = class {
|
|
1502
1502
|
_spanProcessors;
|
|
1503
1503
|
constructor(e) {
|
|
1504
1504
|
this._spanProcessors = e;
|
|
@@ -1510,7 +1510,7 @@ var lr = "2.10.0", ur = class {
|
|
|
1510
1510
|
Promise.all(e).then(() => {
|
|
1511
1511
|
t();
|
|
1512
1512
|
}).catch((e) => {
|
|
1513
|
-
|
|
1513
|
+
k(e || /* @__PURE__ */ Error("MultiSpanProcessor: forceFlush failed")), t();
|
|
1514
1514
|
});
|
|
1515
1515
|
});
|
|
1516
1516
|
}
|
|
@@ -1532,59 +1532,59 @@ var lr = "2.10.0", ur = class {
|
|
|
1532
1532
|
}, n);
|
|
1533
1533
|
});
|
|
1534
1534
|
}
|
|
1535
|
-
},
|
|
1535
|
+
}, pr = class {
|
|
1536
1536
|
shouldSample() {
|
|
1537
|
-
return { decision:
|
|
1537
|
+
return { decision: z.NOT_RECORD };
|
|
1538
1538
|
}
|
|
1539
1539
|
toString() {
|
|
1540
1540
|
return "AlwaysOffSampler";
|
|
1541
1541
|
}
|
|
1542
|
-
},
|
|
1542
|
+
}, B = class {
|
|
1543
1543
|
shouldSample() {
|
|
1544
|
-
return { decision:
|
|
1544
|
+
return { decision: z.RECORD_AND_SAMPLED };
|
|
1545
1545
|
}
|
|
1546
1546
|
toString() {
|
|
1547
1547
|
return "AlwaysOnSampler";
|
|
1548
1548
|
}
|
|
1549
|
-
},
|
|
1549
|
+
}, V = class {
|
|
1550
1550
|
_root;
|
|
1551
1551
|
_remoteParentSampled;
|
|
1552
1552
|
_remoteParentNotSampled;
|
|
1553
1553
|
_localParentSampled;
|
|
1554
1554
|
_localParentNotSampled;
|
|
1555
1555
|
constructor(e) {
|
|
1556
|
-
this._root = e.root, this._root ||= (
|
|
1556
|
+
this._root = e.root, this._root ||= (k(/* @__PURE__ */ Error("ParentBasedSampler must have a root sampler configured")), new B()), this._remoteParentSampled = e.remoteParentSampled ?? new B(), this._remoteParentNotSampled = e.remoteParentNotSampled ?? new pr(), this._localParentSampled = e.localParentSampled ?? new B(), this._localParentNotSampled = e.localParentNotSampled ?? new pr();
|
|
1557
1557
|
}
|
|
1558
1558
|
shouldSample(e, t, n, r, i, a) {
|
|
1559
|
-
let o =
|
|
1560
|
-
return !o || !
|
|
1559
|
+
let o = D.getSpanContext(e);
|
|
1560
|
+
return !o || !Je(o) ? this._root.shouldSample(e, t, n, r, i, a) : o.isRemote ? o.traceFlags & x.SAMPLED ? this._remoteParentSampled.shouldSample(e, t, n, r, i, a) : this._remoteParentNotSampled.shouldSample(e, t, n, r, i, a) : o.traceFlags & x.SAMPLED ? this._localParentSampled.shouldSample(e, t, n, r, i, a) : this._localParentNotSampled.shouldSample(e, t, n, r, i, a);
|
|
1561
1561
|
}
|
|
1562
1562
|
toString() {
|
|
1563
1563
|
return `ParentBased{root=${this._root.toString()}, remoteParentSampled=${this._remoteParentSampled.toString()}, remoteParentNotSampled=${this._remoteParentNotSampled.toString()}, localParentSampled=${this._localParentSampled.toString()}, localParentNotSampled=${this._localParentNotSampled.toString()}}`;
|
|
1564
1564
|
}
|
|
1565
|
-
},
|
|
1565
|
+
}, mr = /* @__PURE__ */ new Map(), hr = class {
|
|
1566
1566
|
processedSpans;
|
|
1567
1567
|
queueSize;
|
|
1568
1568
|
queueSizeCallback;
|
|
1569
1569
|
standardAttrs;
|
|
1570
1570
|
droppedAttrs;
|
|
1571
1571
|
constructor(t, n, r) {
|
|
1572
|
-
let i =
|
|
1573
|
-
if (
|
|
1574
|
-
[
|
|
1575
|
-
[
|
|
1572
|
+
let i = mr.get(t) ?? 0;
|
|
1573
|
+
if (mr.set(t, i + 1), this.standardAttrs = {
|
|
1574
|
+
[Qn]: t,
|
|
1575
|
+
[Zn]: `${t}/${i}`
|
|
1576
1576
|
}, this.droppedAttrs = {
|
|
1577
1577
|
...this.standardAttrs,
|
|
1578
1578
|
[e]: "queue_full"
|
|
1579
|
-
}, this.processedSpans = n.createCounter(
|
|
1579
|
+
}, this.processedSpans = n.createCounter(tr, {
|
|
1580
1580
|
unit: "{span}",
|
|
1581
1581
|
description: "The number of spans for which the processing has finished, either successful or failed."
|
|
1582
1582
|
}), r) {
|
|
1583
1583
|
let { capacity: e, getQueueSize: t } = r;
|
|
1584
|
-
n.createUpDownCounter(
|
|
1584
|
+
n.createUpDownCounter(nr, {
|
|
1585
1585
|
unit: "{span}",
|
|
1586
1586
|
description: "The maximum number of spans the queue of a given instance of an SDK span processor can hold."
|
|
1587
|
-
}).add(e, this.standardAttrs), this.queueSize = n.createObservableUpDownCounter(
|
|
1587
|
+
}).add(e, this.standardAttrs), this.queueSize = n.createObservableUpDownCounter(rr, {
|
|
1588
1588
|
unit: "{span}",
|
|
1589
1589
|
description: "The number of spans in the queue of a given instance of an SDK span processor."
|
|
1590
1590
|
}), this.queueSizeCallback = (e) => e.observe(t(), this.standardAttrs), this.queueSize.addCallback(this.queueSizeCallback);
|
|
@@ -1607,7 +1607,7 @@ var lr = "2.10.0", ur = class {
|
|
|
1607
1607
|
shutdown() {
|
|
1608
1608
|
this.queueSize && this.queueSizeCallback && this.queueSize.removeCallback(this.queueSizeCallback);
|
|
1609
1609
|
}
|
|
1610
|
-
},
|
|
1610
|
+
}, gr = class {
|
|
1611
1611
|
_maxExportBatchSize;
|
|
1612
1612
|
_maxQueueSize;
|
|
1613
1613
|
_scheduledDelayMillis;
|
|
@@ -1620,9 +1620,9 @@ var lr = "2.10.0", ur = class {
|
|
|
1620
1620
|
_shutdownOnce;
|
|
1621
1621
|
_droppedSpansCount = 0;
|
|
1622
1622
|
constructor(e) {
|
|
1623
|
-
this._exporter = e.exporter, this._maxExportBatchSize = e.maxExportBatchSize ?? 512, this._maxQueueSize = e.maxQueueSize ?? 2048, this._scheduledDelayMillis = e.scheduledDelayMillis ?? 5e3, this._exportTimeoutMillis = e.exportTimeoutMillis ?? 3e4, this._shutdownOnce = new
|
|
1623
|
+
this._exporter = e.exporter, this._maxExportBatchSize = e.maxExportBatchSize ?? 512, this._maxQueueSize = e.maxQueueSize ?? 2048, this._scheduledDelayMillis = e.scheduledDelayMillis ?? 5e3, this._exportTimeoutMillis = e.exportTimeoutMillis ?? 3e4, this._shutdownOnce = new Ln(this._shutdown, this), this._maxExportBatchSize > this._maxQueueSize && (T.warn("BatchSpanProcessor: maxExportBatchSize must be smaller or equal to maxQueueSize, setting maxExportBatchSize to match maxQueueSize"), this._maxExportBatchSize = this._maxQueueSize);
|
|
1624
1624
|
let t = e.selfObsMeterProvider ? e.selfObsMeterProvider.getMeter("@opentelemetry/sdk-trace") : ke();
|
|
1625
|
-
this._metrics = new
|
|
1625
|
+
this._metrics = new hr(or, t, {
|
|
1626
1626
|
capacity: this._maxQueueSize,
|
|
1627
1627
|
getQueueSize: () => this._finishedSpans.length
|
|
1628
1628
|
});
|
|
@@ -1632,7 +1632,7 @@ var lr = "2.10.0", ur = class {
|
|
|
1632
1632
|
}
|
|
1633
1633
|
onStart(e, t) {}
|
|
1634
1634
|
onEnd(e) {
|
|
1635
|
-
this._shutdownOnce.isCalled || (e.spanContext().traceFlags &
|
|
1635
|
+
this._shutdownOnce.isCalled || (e.spanContext().traceFlags & x.SAMPLED) !== 0 && this._addToBuffer(e);
|
|
1636
1636
|
}
|
|
1637
1637
|
shutdown() {
|
|
1638
1638
|
return this._shutdownOnce.call();
|
|
@@ -1642,10 +1642,10 @@ var lr = "2.10.0", ur = class {
|
|
|
1642
1642
|
}
|
|
1643
1643
|
_addToBuffer(e) {
|
|
1644
1644
|
if (this._finishedSpans.length >= this._maxQueueSize) {
|
|
1645
|
-
this._droppedSpansCount === 0 &&
|
|
1645
|
+
this._droppedSpansCount === 0 && T.debug("maxQueueSize reached, dropping spans"), this._droppedSpansCount++, this._metrics.dropSpans(1);
|
|
1646
1646
|
return;
|
|
1647
1647
|
}
|
|
1648
|
-
this._droppedSpansCount > 0 && (
|
|
1648
|
+
this._droppedSpansCount > 0 && (T.warn(`Dropped ${this._droppedSpansCount} spans because maxQueueSize reached`), this._droppedSpansCount = 0), this._finishedSpans.push(e), this._maybeStartTimer();
|
|
1649
1649
|
}
|
|
1650
1650
|
_flushAll() {
|
|
1651
1651
|
return new Promise((e, t) => {
|
|
@@ -1661,18 +1661,18 @@ var lr = "2.10.0", ur = class {
|
|
|
1661
1661
|
let n = setTimeout(() => {
|
|
1662
1662
|
t(/* @__PURE__ */ Error("Timeout"));
|
|
1663
1663
|
}, this._exportTimeoutMillis);
|
|
1664
|
-
|
|
1664
|
+
w.with(vt(w.active()), () => {
|
|
1665
1665
|
let r;
|
|
1666
1666
|
this._finishedSpans.length <= this._maxExportBatchSize ? (r = this._finishedSpans, this._finishedSpans = []) : r = this._finishedSpans.splice(0, this._maxExportBatchSize);
|
|
1667
1667
|
let i = () => this._exporter.export(r, (i) => {
|
|
1668
|
-
clearTimeout(n), this._metrics.finishSpans(r.length, i.error), i.code ===
|
|
1668
|
+
clearTimeout(n), this._metrics.finishSpans(r.length, i.error), i.code === F.SUCCESS ? e() : t(i.error ?? /* @__PURE__ */ Error("BatchSpanProcessor: span export failed"));
|
|
1669
1669
|
}), a = null;
|
|
1670
1670
|
for (let e = 0, t = r.length; e < t; e++) {
|
|
1671
1671
|
let t = r[e];
|
|
1672
1672
|
t.resource.asyncAttributesPending && t.resource.waitForAsyncAttributes && (a ??= [], a.push(t.resource.waitForAsyncAttributes()));
|
|
1673
1673
|
}
|
|
1674
1674
|
a === null ? i() : Promise.all(a).then(i, (e) => {
|
|
1675
|
-
|
|
1675
|
+
k(e), t(e);
|
|
1676
1676
|
});
|
|
1677
1677
|
});
|
|
1678
1678
|
});
|
|
@@ -1683,7 +1683,7 @@ var lr = "2.10.0", ur = class {
|
|
|
1683
1683
|
this._isExporting = !0, this._flushOneBatch().finally(() => {
|
|
1684
1684
|
this._isExporting = !1, this._finishedSpans.length > 0 && (this._clearTimer(), this._maybeStartTimer());
|
|
1685
1685
|
}).catch((e) => {
|
|
1686
|
-
this._isExporting = !1,
|
|
1686
|
+
this._isExporting = !1, k(e);
|
|
1687
1687
|
});
|
|
1688
1688
|
};
|
|
1689
1689
|
if (this._finishedSpans.length >= this._maxExportBatchSize) return e();
|
|
@@ -1692,7 +1692,7 @@ var lr = "2.10.0", ur = class {
|
|
|
1692
1692
|
_clearTimer() {
|
|
1693
1693
|
this._timer !== void 0 && (clearTimeout(this._timer), this._timer = void 0);
|
|
1694
1694
|
}
|
|
1695
|
-
},
|
|
1695
|
+
}, _r = class extends gr {
|
|
1696
1696
|
_visibilityChangeListener;
|
|
1697
1697
|
_pageHideListener;
|
|
1698
1698
|
constructor(e) {
|
|
@@ -1701,51 +1701,51 @@ var lr = "2.10.0", ur = class {
|
|
|
1701
1701
|
onInit(e) {
|
|
1702
1702
|
e.disableAutoFlushOnDocumentHide !== !0 && typeof document < "u" && (this._visibilityChangeListener = () => {
|
|
1703
1703
|
document.visibilityState === "hidden" && this.forceFlush().catch((e) => {
|
|
1704
|
-
|
|
1704
|
+
k(e);
|
|
1705
1705
|
});
|
|
1706
1706
|
}, this._pageHideListener = () => {
|
|
1707
1707
|
this.forceFlush().catch((e) => {
|
|
1708
|
-
|
|
1708
|
+
k(e);
|
|
1709
1709
|
});
|
|
1710
1710
|
}, document.addEventListener("visibilitychange", this._visibilityChangeListener), document.addEventListener("pagehide", this._pageHideListener));
|
|
1711
1711
|
}
|
|
1712
1712
|
onShutdown() {
|
|
1713
1713
|
typeof document < "u" && (this._visibilityChangeListener && document.removeEventListener("visibilitychange", this._visibilityChangeListener), this._pageHideListener && document.removeEventListener("pagehide", this._pageHideListener));
|
|
1714
1714
|
}
|
|
1715
|
-
},
|
|
1716
|
-
function
|
|
1715
|
+
}, vr = 16, yr = 8, br = new Uint8Array(vr), xr = new Uint8Array(yr), Sr = Array.from({ length: 256 }, (e, t) => t.toString(16).padStart(2, "0"));
|
|
1716
|
+
function Cr(e) {
|
|
1717
1717
|
for (let t = 0; t < e.length; t++) e[t] = Math.random() * 256 >>> 0;
|
|
1718
1718
|
for (let t = 0; t < e.length; t++) if (e[t] > 0) return;
|
|
1719
1719
|
e[e.length - 1] = 1;
|
|
1720
1720
|
}
|
|
1721
|
-
function
|
|
1721
|
+
function wr(e) {
|
|
1722
1722
|
let t = "";
|
|
1723
|
-
for (let n = 0; n < e.length; n++) t +=
|
|
1723
|
+
for (let n = 0; n < e.length; n++) t += Sr[e[n]];
|
|
1724
1724
|
return t;
|
|
1725
1725
|
}
|
|
1726
|
-
var
|
|
1726
|
+
var Tr = class {
|
|
1727
1727
|
generateTraceId() {
|
|
1728
|
-
return
|
|
1728
|
+
return Cr(br), wr(br);
|
|
1729
1729
|
}
|
|
1730
1730
|
generateSpanId() {
|
|
1731
|
-
return
|
|
1731
|
+
return Cr(xr), wr(xr);
|
|
1732
1732
|
}
|
|
1733
|
-
},
|
|
1733
|
+
}, H;
|
|
1734
1734
|
(function(e) {
|
|
1735
1735
|
e[e.resolved = 0] = "resolved", e[e.timeout = 1] = "timeout", e[e.error = 2] = "error", e[e.unresolved = 3] = "unresolved";
|
|
1736
|
-
})(
|
|
1737
|
-
var
|
|
1736
|
+
})(H ||= {});
|
|
1737
|
+
var Er = class {
|
|
1738
1738
|
_resource;
|
|
1739
1739
|
_activeSpanProcessor;
|
|
1740
1740
|
_forceFlushTimeoutMillis;
|
|
1741
1741
|
_tracerOptions;
|
|
1742
1742
|
_tracers = /* @__PURE__ */ new Map();
|
|
1743
1743
|
constructor(e = {}) {
|
|
1744
|
-
this._forceFlushTimeoutMillis = e.forceFlushTimeoutMillis ?? 3e4, this._resource = e.resource ??
|
|
1744
|
+
this._forceFlushTimeoutMillis = e.forceFlushTimeoutMillis ?? 3e4, this._resource = e.resource ?? Hn();
|
|
1745
1745
|
let t = e.spanProcessors ?? [];
|
|
1746
|
-
this._activeSpanProcessor = new
|
|
1746
|
+
this._activeSpanProcessor = new fr(t), this._tracerOptions = {
|
|
1747
1747
|
resource: this._resource,
|
|
1748
|
-
sampler: e.sampler ?? new
|
|
1748
|
+
sampler: e.sampler ?? new V({ root: new B() }),
|
|
1749
1749
|
spanLimits: {
|
|
1750
1750
|
attributeCountLimit: e.spanLimits?.attributeCountLimit ?? 128,
|
|
1751
1751
|
attributeValueLengthLimit: e.spanLimits?.attributeValueLengthLimit ?? Infinity,
|
|
@@ -1754,7 +1754,7 @@ var Tr = class {
|
|
|
1754
1754
|
attributePerEventCountLimit: e.spanLimits?.attributePerEventCountLimit ?? 128,
|
|
1755
1755
|
attributePerLinkCountLimit: e.spanLimits?.attributePerLinkCountLimit ?? 128
|
|
1756
1756
|
},
|
|
1757
|
-
idGenerator: e.idGenerator || new
|
|
1757
|
+
idGenerator: e.idGenerator || new Tr(),
|
|
1758
1758
|
spanProcessor: this._activeSpanProcessor,
|
|
1759
1759
|
meterProvider: e.meterProvider ?? { getMeter() {
|
|
1760
1760
|
return ke();
|
|
@@ -1763,49 +1763,49 @@ var Tr = class {
|
|
|
1763
1763
|
}
|
|
1764
1764
|
getTracer(e, t, n) {
|
|
1765
1765
|
let r = `${e}@${t || ""}:${n?.schemaUrl || ""}`;
|
|
1766
|
-
return this._tracers.has(r) || this._tracers.set(r, new
|
|
1766
|
+
return this._tracers.has(r) || this._tracers.set(r, new dr({
|
|
1767
1767
|
name: e,
|
|
1768
1768
|
version: t,
|
|
1769
1769
|
schemaUrl: n?.schemaUrl
|
|
1770
1770
|
}, this._tracerOptions)), this._tracers.get(r);
|
|
1771
1771
|
}
|
|
1772
|
-
forceFlush() {
|
|
1773
|
-
let
|
|
1772
|
+
forceFlush(e) {
|
|
1773
|
+
let t = e?.timeoutMillis ?? this._forceFlushTimeoutMillis, n = this._activeSpanProcessor._spanProcessors.map((e) => new Promise((n) => {
|
|
1774
1774
|
let r, i = setTimeout(() => {
|
|
1775
|
-
n(/* @__PURE__ */ Error(`Span processor did not completed within timeout period of ${
|
|
1776
|
-
},
|
|
1777
|
-
|
|
1778
|
-
clearTimeout(i), r !==
|
|
1775
|
+
n(/* @__PURE__ */ Error(`Span processor did not completed within timeout period of ${t} ms`)), r = H.timeout;
|
|
1776
|
+
}, t);
|
|
1777
|
+
e.forceFlush().then(() => {
|
|
1778
|
+
clearTimeout(i), r !== H.timeout && (r = H.resolved, n(r));
|
|
1779
1779
|
}).catch((e) => {
|
|
1780
|
-
clearTimeout(i), r =
|
|
1780
|
+
clearTimeout(i), r = H.error, n(e);
|
|
1781
1781
|
});
|
|
1782
1782
|
}));
|
|
1783
|
-
return new Promise((e,
|
|
1784
|
-
Promise.all(
|
|
1785
|
-
let r =
|
|
1786
|
-
r.length > 0 ?
|
|
1787
|
-
}).catch((e) =>
|
|
1783
|
+
return new Promise((e, t) => {
|
|
1784
|
+
Promise.all(n).then((n) => {
|
|
1785
|
+
let r = n.filter((e) => e !== H.resolved);
|
|
1786
|
+
r.length > 0 ? t(r) : e();
|
|
1787
|
+
}).catch((e) => t([e]));
|
|
1788
1788
|
});
|
|
1789
1789
|
}
|
|
1790
1790
|
shutdown() {
|
|
1791
1791
|
return this._activeSpanProcessor.shutdown();
|
|
1792
1792
|
}
|
|
1793
|
-
[
|
|
1793
|
+
[qn](e, t, n) {
|
|
1794
1794
|
let r = this._activeSpanProcessor._spanProcessors;
|
|
1795
|
-
return
|
|
1796
|
-
resource: { attributes:
|
|
1795
|
+
return Yn("TracerProvider", {
|
|
1796
|
+
resource: { attributes: Jn(this._resource) },
|
|
1797
1797
|
tracers: Array.from(this._tracers.keys()),
|
|
1798
1798
|
spanProcessors: r.map((e) => e.constructor?.name ?? "SpanProcessor")
|
|
1799
1799
|
}, e, t, n);
|
|
1800
1800
|
}
|
|
1801
|
-
},
|
|
1801
|
+
}, Dr = class {
|
|
1802
1802
|
_ratio;
|
|
1803
1803
|
_upperBound;
|
|
1804
1804
|
constructor(e = 0) {
|
|
1805
1805
|
this._ratio = this._normalize(e), this._upperBound = this._ratio === 1 ? 4294967296 : Math.floor(this._ratio * 4294967295);
|
|
1806
1806
|
}
|
|
1807
1807
|
shouldSample(e, t) {
|
|
1808
|
-
return { decision:
|
|
1808
|
+
return { decision: Ke(t) && this._accumulate(t) < this._upperBound ? z.RECORD_AND_SAMPLED : z.NOT_RECORD };
|
|
1809
1809
|
}
|
|
1810
1810
|
toString() {
|
|
1811
1811
|
return `TraceIdRatioBased{${this._ratio}}`;
|
|
@@ -1825,14 +1825,14 @@ var Tr = class {
|
|
|
1825
1825
|
}
|
|
1826
1826
|
return t;
|
|
1827
1827
|
}
|
|
1828
|
-
},
|
|
1828
|
+
}, U;
|
|
1829
1829
|
(function(e) {
|
|
1830
1830
|
e.AlwaysOff = "always_off", e.AlwaysOn = "always_on", e.ParentBasedAlwaysOff = "parentbased_always_off", e.ParentBasedAlwaysOn = "parentbased_always_on", e.ParentBasedTraceIdRatio = "parentbased_traceidratio", e.TraceIdRatio = "traceidratio";
|
|
1831
|
-
})(
|
|
1832
|
-
var
|
|
1833
|
-
function
|
|
1831
|
+
})(U ||= {});
|
|
1832
|
+
var Or = 1;
|
|
1833
|
+
function kr() {
|
|
1834
1834
|
return {
|
|
1835
|
-
sampler:
|
|
1835
|
+
sampler: Ar(),
|
|
1836
1836
|
forceFlushTimeoutMillis: 3e4,
|
|
1837
1837
|
generalLimits: {
|
|
1838
1838
|
attributeValueLengthLimit: Infinity,
|
|
@@ -1848,33 +1848,33 @@ function Or() {
|
|
|
1848
1848
|
}
|
|
1849
1849
|
};
|
|
1850
1850
|
}
|
|
1851
|
-
function
|
|
1852
|
-
let e =
|
|
1851
|
+
function Ar() {
|
|
1852
|
+
let e = U.ParentBasedAlwaysOn;
|
|
1853
1853
|
switch (e) {
|
|
1854
|
-
case
|
|
1855
|
-
case
|
|
1856
|
-
case
|
|
1857
|
-
case
|
|
1858
|
-
case
|
|
1859
|
-
case
|
|
1860
|
-
default: return
|
|
1854
|
+
case U.AlwaysOn: return new B();
|
|
1855
|
+
case U.AlwaysOff: return new pr();
|
|
1856
|
+
case U.ParentBasedAlwaysOn: return new V({ root: new B() });
|
|
1857
|
+
case U.ParentBasedAlwaysOff: return new V({ root: new pr() });
|
|
1858
|
+
case U.TraceIdRatio: return new Dr(jr());
|
|
1859
|
+
case U.ParentBasedTraceIdRatio: return new V({ root: new Dr(jr()) });
|
|
1860
|
+
default: return T.error(`OTEL_TRACES_SAMPLER value "${e}" invalid, defaulting to "${U.ParentBasedAlwaysOn}".`), new V({ root: new B() });
|
|
1861
1861
|
}
|
|
1862
1862
|
}
|
|
1863
|
-
function
|
|
1864
|
-
return
|
|
1863
|
+
function jr() {
|
|
1864
|
+
return T.error(`OTEL_TRACES_SAMPLER_ARG is blank, defaulting to ${Or}.`), Or;
|
|
1865
1865
|
}
|
|
1866
|
-
function
|
|
1866
|
+
function Mr(e) {
|
|
1867
1867
|
let t = Object.assign({}, e.spanLimits);
|
|
1868
1868
|
return t.attributeCountLimit = e.spanLimits?.attributeCountLimit ?? e.generalLimits?.attributeCountLimit ?? void 0 ?? void 0 ?? 128, t.attributeValueLengthLimit = e.spanLimits?.attributeValueLengthLimit ?? e.generalLimits?.attributeValueLengthLimit ?? void 0 ?? void 0 ?? Infinity, Object.assign({}, e, { spanLimits: t });
|
|
1869
1869
|
}
|
|
1870
1870
|
//#endregion
|
|
1871
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-base@2.
|
|
1872
|
-
var
|
|
1871
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-base@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace-base/build/esm/BasicTracerProvider-shim.js
|
|
1872
|
+
var Nr = class extends Er {
|
|
1873
1873
|
constructor(e = {}) {
|
|
1874
|
-
let t =
|
|
1874
|
+
let t = En({}, kr(), Mr(e));
|
|
1875
1875
|
delete t.generalLimits, super(t);
|
|
1876
1876
|
}
|
|
1877
|
-
},
|
|
1877
|
+
}, Pr = class extends _r {
|
|
1878
1878
|
constructor(e, t) {
|
|
1879
1879
|
t ||= {};
|
|
1880
1880
|
for (let [e, n] of [
|
|
@@ -1888,7 +1888,7 @@ var Mr = class extends Tr {
|
|
|
1888
1888
|
...t
|
|
1889
1889
|
});
|
|
1890
1890
|
}
|
|
1891
|
-
},
|
|
1891
|
+
}, Fr = class {
|
|
1892
1892
|
_enabled = !1;
|
|
1893
1893
|
_currentContext = b;
|
|
1894
1894
|
_bindFunction(e = b, t) {
|
|
@@ -1925,109 +1925,109 @@ var Mr = class extends Tr {
|
|
|
1925
1925
|
}
|
|
1926
1926
|
};
|
|
1927
1927
|
//#endregion
|
|
1928
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-web@2.
|
|
1929
|
-
function
|
|
1928
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-web@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace-web/build/esm/WebTracerProvider.js
|
|
1929
|
+
function Ir(e) {
|
|
1930
1930
|
if (e !== null) {
|
|
1931
1931
|
if (e === void 0) {
|
|
1932
|
-
let e = new
|
|
1933
|
-
e.enable(),
|
|
1932
|
+
let e = new Fr();
|
|
1933
|
+
e.enable(), w.setGlobalContextManager(e);
|
|
1934
1934
|
return;
|
|
1935
1935
|
}
|
|
1936
|
-
e.enable(),
|
|
1936
|
+
e.enable(), w.setGlobalContextManager(e);
|
|
1937
1937
|
}
|
|
1938
1938
|
}
|
|
1939
|
-
function
|
|
1939
|
+
function Lr(e) {
|
|
1940
1940
|
if (e !== null) {
|
|
1941
1941
|
if (e === void 0) {
|
|
1942
|
-
|
|
1942
|
+
E.setGlobalPropagator(new Kt({ propagators: [new un(), new Et()] }));
|
|
1943
1943
|
return;
|
|
1944
1944
|
}
|
|
1945
|
-
|
|
1945
|
+
E.setGlobalPropagator(e);
|
|
1946
1946
|
}
|
|
1947
1947
|
}
|
|
1948
|
-
var
|
|
1948
|
+
var Rr = class extends Nr {
|
|
1949
1949
|
constructor(e = {}) {
|
|
1950
1950
|
super(e);
|
|
1951
1951
|
}
|
|
1952
1952
|
register(e = {}) {
|
|
1953
|
-
|
|
1953
|
+
D.setGlobalTracerProvider(this), Lr(e.propagator), Ir(e.contextManager);
|
|
1954
1954
|
}
|
|
1955
|
-
},
|
|
1955
|
+
}, W;
|
|
1956
1956
|
(function(e) {
|
|
1957
1957
|
e.CONNECT_END = "connectEnd", e.CONNECT_START = "connectStart", e.DECODED_BODY_SIZE = "decodedBodySize", e.DOM_COMPLETE = "domComplete", e.DOM_CONTENT_LOADED_EVENT_END = "domContentLoadedEventEnd", e.DOM_CONTENT_LOADED_EVENT_START = "domContentLoadedEventStart", e.DOM_INTERACTIVE = "domInteractive", e.DOMAIN_LOOKUP_END = "domainLookupEnd", e.DOMAIN_LOOKUP_START = "domainLookupStart", e.ENCODED_BODY_SIZE = "encodedBodySize", e.FETCH_START = "fetchStart", e.LOAD_EVENT_END = "loadEventEnd", e.LOAD_EVENT_START = "loadEventStart", e.NAVIGATION_START = "navigationStart", e.REDIRECT_END = "redirectEnd", e.REDIRECT_START = "redirectStart", e.REQUEST_START = "requestStart", e.RESPONSE_END = "responseEnd", e.RESPONSE_START = "responseStart", e.SECURE_CONNECTION_START = "secureConnectionStart", e.START_TIME = "startTime", e.UNLOAD_EVENT_END = "unloadEventEnd", e.UNLOAD_EVENT_START = "unloadEventStart";
|
|
1958
|
-
})(
|
|
1958
|
+
})(W ||= {});
|
|
1959
1959
|
//#endregion
|
|
1960
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-web@2.
|
|
1961
|
-
var
|
|
1962
|
-
function
|
|
1963
|
-
return
|
|
1960
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-web@2.11.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace-web/build/esm/semconv.js
|
|
1961
|
+
var zr = "http.response_content_length", Br = "http.response_content_length_uncompressed", Vr;
|
|
1962
|
+
function Hr() {
|
|
1963
|
+
return Vr ||= document.createElement("a"), Vr;
|
|
1964
1964
|
}
|
|
1965
|
-
function
|
|
1965
|
+
function Ur(e, t) {
|
|
1966
1966
|
return t in e;
|
|
1967
1967
|
}
|
|
1968
|
-
function
|
|
1969
|
-
if (
|
|
1968
|
+
function G(e, t, n, r = !0) {
|
|
1969
|
+
if (Ur(n, t) && typeof n[t] == "number" && !(r && n[t] === 0)) return e.addEvent(t, n[t]);
|
|
1970
1970
|
}
|
|
1971
|
-
function
|
|
1972
|
-
if (r === void 0 && (r = t[
|
|
1973
|
-
let n = t[
|
|
1974
|
-
n !== void 0 && e.setAttribute(
|
|
1975
|
-
let r = t[
|
|
1976
|
-
r !== void 0 && n !== r && e.setAttribute(
|
|
1971
|
+
function Wr(e, t, n = !1, r, i) {
|
|
1972
|
+
if (r === void 0 && (r = t[W.START_TIME] !== 0), n || (G(e, W.FETCH_START, t, r), G(e, W.DOMAIN_LOOKUP_START, t, r), G(e, W.DOMAIN_LOOKUP_END, t, r), G(e, W.CONNECT_START, t, r), G(e, W.SECURE_CONNECTION_START, t, r), G(e, W.CONNECT_END, t, r), G(e, W.REQUEST_START, t, r), G(e, W.RESPONSE_START, t, r), G(e, W.RESPONSE_END, t, r)), !i) {
|
|
1973
|
+
let n = t[W.ENCODED_BODY_SIZE];
|
|
1974
|
+
n !== void 0 && e.setAttribute(zr, n);
|
|
1975
|
+
let r = t[W.DECODED_BODY_SIZE];
|
|
1976
|
+
r !== void 0 && n !== r && e.setAttribute(Br, r);
|
|
1977
1977
|
}
|
|
1978
1978
|
}
|
|
1979
|
-
function
|
|
1979
|
+
function Gr(e) {
|
|
1980
1980
|
return e.slice().sort((e, t) => {
|
|
1981
|
-
let n = e[
|
|
1981
|
+
let n = e[W.FETCH_START], r = t[W.FETCH_START];
|
|
1982
1982
|
return n > r ? 1 : n < r ? -1 : 0;
|
|
1983
1983
|
});
|
|
1984
1984
|
}
|
|
1985
|
-
function
|
|
1985
|
+
function Kr() {
|
|
1986
1986
|
return typeof location < "u" ? location.origin : void 0;
|
|
1987
1987
|
}
|
|
1988
|
-
function
|
|
1989
|
-
let o =
|
|
1988
|
+
function qr(e, t, n, r, i = /* @__PURE__ */ new WeakSet(), a) {
|
|
1989
|
+
let o = Xr(e);
|
|
1990
1990
|
e = o.toString();
|
|
1991
|
-
let s =
|
|
1991
|
+
let s = Yr(e, t, n, r, i, a);
|
|
1992
1992
|
if (s.length === 0) return { mainRequest: void 0 };
|
|
1993
1993
|
if (s.length === 1) return { mainRequest: s[0] };
|
|
1994
|
-
let c =
|
|
1995
|
-
if (o.origin !==
|
|
1996
|
-
let e = c[0], t =
|
|
1997
|
-
return t[
|
|
1994
|
+
let c = Gr(s);
|
|
1995
|
+
if (o.origin !== Kr() && c.length > 1) {
|
|
1996
|
+
let e = c[0], t = Jr(c, e[W.RESPONSE_END], n), r = e[W.RESPONSE_END];
|
|
1997
|
+
return t[W.FETCH_START] < r && (t = e, e = void 0), {
|
|
1998
1998
|
corsPreFlightRequest: e,
|
|
1999
1999
|
mainRequest: t
|
|
2000
2000
|
};
|
|
2001
2001
|
}
|
|
2002
2002
|
return { mainRequest: s[0] };
|
|
2003
2003
|
}
|
|
2004
|
-
function
|
|
2005
|
-
let r =
|
|
2004
|
+
function Jr(e, t, n) {
|
|
2005
|
+
let r = P(n), i = P(N(t)), a = e[1], o, s = e.length;
|
|
2006
2006
|
for (let t = 1; t < s; t++) {
|
|
2007
|
-
let n = e[t], s =
|
|
2007
|
+
let n = e[t], s = P(N(n[W.FETCH_START])), c = r - P(N(n[W.RESPONSE_END]));
|
|
2008
2008
|
s >= i && (!o || c < o) && (o = c, a = n);
|
|
2009
2009
|
}
|
|
2010
2010
|
return a;
|
|
2011
2011
|
}
|
|
2012
|
-
function
|
|
2013
|
-
let o =
|
|
2014
|
-
let n =
|
|
2012
|
+
function Yr(e, t, n, r, i, a) {
|
|
2013
|
+
let o = P(t), s = P(n), c = r.filter((t) => {
|
|
2014
|
+
let n = P(N(t[W.FETCH_START])), r = P(N(t[W.RESPONSE_END]));
|
|
2015
2015
|
return t.initiatorType.toLowerCase() === (a || "xmlhttprequest") && t.name === e && n >= o && r <= s;
|
|
2016
2016
|
});
|
|
2017
2017
|
return c.length > 0 && (c = c.filter((e) => !i.has(e))), c;
|
|
2018
2018
|
}
|
|
2019
|
-
function
|
|
2019
|
+
function Xr(e) {
|
|
2020
2020
|
if (typeof URL == "function") return new URL(e, typeof document < "u" ? document.baseURI : typeof location < "u" ? location.href : void 0);
|
|
2021
|
-
let t =
|
|
2021
|
+
let t = Hr();
|
|
2022
2022
|
return t.href = e, t;
|
|
2023
2023
|
}
|
|
2024
|
-
function
|
|
2024
|
+
function Zr(e, t) {
|
|
2025
2025
|
let n = t || [];
|
|
2026
|
-
return (typeof n == "string" || n instanceof RegExp) && (n = [n]),
|
|
2026
|
+
return (typeof n == "string" || n instanceof RegExp) && (n = [n]), Xr(e).origin === Kr() || n.some((t) => Pn(e, t));
|
|
2027
2027
|
}
|
|
2028
2028
|
//#endregion
|
|
2029
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2030
|
-
var
|
|
2029
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/OTLPExporterBase.js
|
|
2030
|
+
var Qr = class {
|
|
2031
2031
|
_delegate;
|
|
2032
2032
|
constructor(e) {
|
|
2033
2033
|
this._delegate = e;
|
|
@@ -2044,7 +2044,7 @@ var Xr = class {
|
|
|
2044
2044
|
setMetrics(e) {
|
|
2045
2045
|
this._delegate.setMetrics(e);
|
|
2046
2046
|
}
|
|
2047
|
-
},
|
|
2047
|
+
}, $r = class extends Error {
|
|
2048
2048
|
code;
|
|
2049
2049
|
name = "OTLPExporterError";
|
|
2050
2050
|
data;
|
|
@@ -2053,22 +2053,22 @@ var Xr = class {
|
|
|
2053
2053
|
}
|
|
2054
2054
|
};
|
|
2055
2055
|
//#endregion
|
|
2056
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2057
|
-
function
|
|
2056
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/configuration/shared-configuration.js
|
|
2057
|
+
function ei(e) {
|
|
2058
2058
|
if (Number.isFinite(e) && e > 0) return e;
|
|
2059
2059
|
throw Error(`Configuration: timeoutMillis is invalid, expected number greater than 0 (actual: '${e}')`);
|
|
2060
2060
|
}
|
|
2061
|
-
function
|
|
2061
|
+
function ti(e) {
|
|
2062
2062
|
if (e != null) return async () => e;
|
|
2063
2063
|
}
|
|
2064
|
-
function
|
|
2064
|
+
function ni(e, t, n) {
|
|
2065
2065
|
return {
|
|
2066
|
-
timeoutMillis:
|
|
2066
|
+
timeoutMillis: ei(e.timeoutMillis ?? t.timeoutMillis ?? n.timeoutMillis),
|
|
2067
2067
|
concurrencyLimit: e.concurrencyLimit ?? t.concurrencyLimit ?? n.concurrencyLimit,
|
|
2068
2068
|
compression: e.compression ?? t.compression ?? n.compression
|
|
2069
2069
|
};
|
|
2070
2070
|
}
|
|
2071
|
-
function
|
|
2071
|
+
function ri() {
|
|
2072
2072
|
return {
|
|
2073
2073
|
timeoutMillis: 1e4,
|
|
2074
2074
|
concurrencyLimit: 30,
|
|
@@ -2076,8 +2076,8 @@ function ti() {
|
|
|
2076
2076
|
};
|
|
2077
2077
|
}
|
|
2078
2078
|
//#endregion
|
|
2079
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2080
|
-
var
|
|
2079
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/bounded-queue-export-promise-handler.js
|
|
2080
|
+
var ii = class {
|
|
2081
2081
|
_concurrencyLimit;
|
|
2082
2082
|
_sendingPromises = [];
|
|
2083
2083
|
constructor(e) {
|
|
@@ -2099,22 +2099,22 @@ var ni = class {
|
|
|
2099
2099
|
await Promise.all(this._sendingPromises);
|
|
2100
2100
|
}
|
|
2101
2101
|
};
|
|
2102
|
-
function
|
|
2103
|
-
return new
|
|
2102
|
+
function ai(e) {
|
|
2103
|
+
return new ii(e.concurrencyLimit);
|
|
2104
2104
|
}
|
|
2105
2105
|
//#endregion
|
|
2106
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2107
|
-
function
|
|
2106
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/logging-response-handler.js
|
|
2107
|
+
function oi(e) {
|
|
2108
2108
|
return Object.prototype.hasOwnProperty.call(e, "partialSuccess");
|
|
2109
2109
|
}
|
|
2110
|
-
function
|
|
2110
|
+
function si() {
|
|
2111
2111
|
return { handleResponse(e) {
|
|
2112
|
-
e == null || !
|
|
2112
|
+
e == null || !oi(e) || e.partialSuccess == null || Object.keys(e.partialSuccess).length === 0 || T.warn("Received Partial Success response:", JSON.stringify(e.partialSuccess));
|
|
2113
2113
|
} };
|
|
2114
2114
|
}
|
|
2115
2115
|
//#endregion
|
|
2116
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2117
|
-
var
|
|
2116
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/otlp-export-delegate.js
|
|
2117
|
+
var ci = class {
|
|
2118
2118
|
_metrics;
|
|
2119
2119
|
_diagLogger;
|
|
2120
2120
|
_transport;
|
|
@@ -2123,12 +2123,12 @@ var oi = class {
|
|
|
2123
2123
|
_promiseQueue;
|
|
2124
2124
|
_timeout;
|
|
2125
2125
|
constructor(e, t, n, r, i, a) {
|
|
2126
|
-
this._transport = e, this._serializer = t, this._responseHandler = n, this._promiseQueue = r, this._timeout = a, this._diagLogger =
|
|
2126
|
+
this._transport = e, this._serializer = t, this._responseHandler = n, this._promiseQueue = r, this._timeout = a, this._diagLogger = T.createComponentLogger({ namespace: "OTLPExportDelegate" }), this._metrics = i;
|
|
2127
2127
|
}
|
|
2128
2128
|
export(e, t) {
|
|
2129
2129
|
if (this._diagLogger.debug("items to be sent", e), this._promiseQueue.hasReachedLimit()) {
|
|
2130
2130
|
t({
|
|
2131
|
-
code:
|
|
2131
|
+
code: F.FAILED,
|
|
2132
2132
|
error: /* @__PURE__ */ Error("Concurrent export limit reached")
|
|
2133
2133
|
});
|
|
2134
2134
|
return;
|
|
@@ -2136,7 +2136,7 @@ var oi = class {
|
|
|
2136
2136
|
let n = this._serializer.serializeRequest(e);
|
|
2137
2137
|
if (n == null) {
|
|
2138
2138
|
t({
|
|
2139
|
-
code:
|
|
2139
|
+
code: F.FAILED,
|
|
2140
2140
|
error: /* @__PURE__ */ Error("Nothing to send")
|
|
2141
2141
|
});
|
|
2142
2142
|
return;
|
|
@@ -2149,26 +2149,26 @@ var oi = class {
|
|
|
2149
2149
|
} catch (t) {
|
|
2150
2150
|
this._diagLogger.warn("Export succeeded but could not deserialize response - is the response specification compliant?", t, e.data);
|
|
2151
2151
|
}
|
|
2152
|
-
t({ code:
|
|
2152
|
+
t({ code: F.SUCCESS });
|
|
2153
2153
|
return;
|
|
2154
2154
|
}
|
|
2155
2155
|
if (e.status === "failure" && e.error) {
|
|
2156
2156
|
r(e.error), t({
|
|
2157
|
-
code:
|
|
2157
|
+
code: F.FAILED,
|
|
2158
2158
|
error: e.error
|
|
2159
2159
|
});
|
|
2160
2160
|
return;
|
|
2161
2161
|
}
|
|
2162
2162
|
e.status === "retryable" ? (r("export_max_retries"), t({
|
|
2163
|
-
code:
|
|
2164
|
-
error: e.error ?? new
|
|
2163
|
+
code: F.FAILED,
|
|
2164
|
+
error: e.error ?? new $r("Export failed with retryable status")
|
|
2165
2165
|
})) : (r("export_failed"), t({
|
|
2166
|
-
code:
|
|
2167
|
-
error: new
|
|
2166
|
+
code: F.FAILED,
|
|
2167
|
+
error: new $r("Export failed with unknown error")
|
|
2168
2168
|
}));
|
|
2169
2169
|
}, (e) => {
|
|
2170
2170
|
r(e), t({
|
|
2171
|
-
code:
|
|
2171
|
+
code: F.FAILED,
|
|
2172
2172
|
error: e
|
|
2173
2173
|
});
|
|
2174
2174
|
}));
|
|
@@ -2183,22 +2183,22 @@ var oi = class {
|
|
|
2183
2183
|
this._diagLogger.debug("shutdown started"), await this.forceFlush(), this._transport.shutdown();
|
|
2184
2184
|
}
|
|
2185
2185
|
};
|
|
2186
|
-
function
|
|
2187
|
-
return new
|
|
2186
|
+
function li(e, t) {
|
|
2187
|
+
return new ci(e.transport, e.serializer, si(), e.promiseHandler, e.metrics, t.timeout);
|
|
2188
2188
|
}
|
|
2189
2189
|
//#endregion
|
|
2190
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2191
|
-
function
|
|
2192
|
-
return
|
|
2190
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/otlp-network-export-delegate.js
|
|
2191
|
+
function ui(e, t, n, r) {
|
|
2192
|
+
return li({
|
|
2193
2193
|
transport: r,
|
|
2194
2194
|
serializer: t,
|
|
2195
|
-
promiseHandler:
|
|
2195
|
+
promiseHandler: ai(e),
|
|
2196
2196
|
metrics: n
|
|
2197
2197
|
}, { timeout: e.timeoutMillis });
|
|
2198
2198
|
}
|
|
2199
2199
|
//#endregion
|
|
2200
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2201
|
-
var
|
|
2200
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/semconv.js
|
|
2201
|
+
var di = "http.response.status_code", fi = "otel.component.name", pi = "otel.component.type", mi = "server.address", hi = "server.port", gi = "error.type", _i = "0.222.0", vi = /* @__PURE__ */ new Map(), yi = class {
|
|
2202
2202
|
inflight;
|
|
2203
2203
|
exported;
|
|
2204
2204
|
duration;
|
|
@@ -2208,18 +2208,18 @@ var li = "http.response.status_code", ui = "otel.component.name", di = "otel.com
|
|
|
2208
2208
|
constructor(e) {
|
|
2209
2209
|
let { componentType: t, metricsHelper: n, meterProvider: r, url: i, responseAttributesFromError: a } = e;
|
|
2210
2210
|
this.responseAttributesFromError = a;
|
|
2211
|
-
let o = r ? r.getMeter("@opentelemetry/otlp-exporter",
|
|
2212
|
-
if (
|
|
2213
|
-
[
|
|
2214
|
-
[
|
|
2211
|
+
let o = r ? r.getMeter("@opentelemetry/otlp-exporter", _i) : ke(), s = vi.get(t) ?? 0;
|
|
2212
|
+
if (vi.set(t, s + 1), this.standardAttrs = {
|
|
2213
|
+
[pi]: t,
|
|
2214
|
+
[fi]: `${t}/${s}`
|
|
2215
2215
|
}, i) {
|
|
2216
2216
|
let e = i;
|
|
2217
2217
|
i.includes("://") || (e = `http://${i}`);
|
|
2218
2218
|
try {
|
|
2219
2219
|
let t = new URL(e);
|
|
2220
|
-
this.standardAttrs[
|
|
2220
|
+
this.standardAttrs[mi] = t.hostname;
|
|
2221
2221
|
let n;
|
|
2222
|
-
t.port ? n = Number(t.port) : t.protocol === "http:" ? n = 80 : t.protocol === "https:" && (n = 443), typeof n == "number" && (this.standardAttrs[
|
|
2222
|
+
t.port ? n = Number(t.port) : t.protocol === "http:" ? n = 80 : t.protocol === "https:" && (n = 443), typeof n == "number" && (this.standardAttrs[hi] = n);
|
|
2223
2223
|
} catch {}
|
|
2224
2224
|
}
|
|
2225
2225
|
this.helper = n, this.inflight = o.createUpDownCounter(`otel.sdk.exporter.${this.helper.name}.inflight`, {
|
|
@@ -2235,39 +2235,39 @@ var li = "http.response.status_code", ui = "otel.component.name", di = "otel.com
|
|
|
2235
2235
|
});
|
|
2236
2236
|
}
|
|
2237
2237
|
startExport(e) {
|
|
2238
|
-
let t = this.helper.countItems(e), n =
|
|
2238
|
+
let t = this.helper.countItems(e), n = M();
|
|
2239
2239
|
return this.inflight.add(t, this.standardAttrs), (e) => {
|
|
2240
|
-
let r =
|
|
2240
|
+
let r = M();
|
|
2241
2241
|
this.inflight.add(-t, this.standardAttrs);
|
|
2242
2242
|
let i = e ? {
|
|
2243
2243
|
...this.standardAttrs,
|
|
2244
|
-
[
|
|
2244
|
+
[gi]: e instanceof Error ? e.name : "export_failed"
|
|
2245
2245
|
} : this.standardAttrs;
|
|
2246
2246
|
this.exported.add(t, i);
|
|
2247
2247
|
let a = {
|
|
2248
2248
|
...i,
|
|
2249
2249
|
...this.responseAttributesFromError(e)
|
|
2250
|
-
}, o = Vt(
|
|
2250
|
+
}, o = Ht(Vt(n, r)) / 1e3;
|
|
2251
2251
|
this.duration.record(o, a);
|
|
2252
2252
|
};
|
|
2253
2253
|
}
|
|
2254
|
-
},
|
|
2254
|
+
}, bi = {
|
|
2255
2255
|
name: "span",
|
|
2256
2256
|
countItems: (e) => e.length
|
|
2257
|
-
},
|
|
2257
|
+
}, xi = class {
|
|
2258
2258
|
emit(e) {}
|
|
2259
2259
|
enabled() {
|
|
2260
2260
|
return !1;
|
|
2261
2261
|
}
|
|
2262
|
-
},
|
|
2263
|
-
function
|
|
2262
|
+
}, Si = new xi(), Ci = Symbol.for("io.opentelemetry.js.api.logs"), K = globalThis;
|
|
2263
|
+
function wi(e, t, n) {
|
|
2264
2264
|
return (r) => r === e ? t : n;
|
|
2265
2265
|
}
|
|
2266
|
-
var
|
|
2266
|
+
var Ti = new class {
|
|
2267
2267
|
getLogger(e, t, n) {
|
|
2268
|
-
return new
|
|
2268
|
+
return new xi();
|
|
2269
2269
|
}
|
|
2270
|
-
}(),
|
|
2270
|
+
}(), Ei = class {
|
|
2271
2271
|
constructor(e, t, n, r) {
|
|
2272
2272
|
this._provider = e, this.name = t, this.version = n, this.options = r;
|
|
2273
2273
|
}
|
|
@@ -2280,14 +2280,14 @@ var Ci = new class {
|
|
|
2280
2280
|
_getLogger() {
|
|
2281
2281
|
if (this._delegate) return this._delegate;
|
|
2282
2282
|
let e = this._provider._getDelegateLogger(this.name, this.version, this.options);
|
|
2283
|
-
return e ? (this._delegate = e, this._delegate) :
|
|
2283
|
+
return e ? (this._delegate = e, this._delegate) : Si;
|
|
2284
2284
|
}
|
|
2285
|
-
},
|
|
2285
|
+
}, Di = class {
|
|
2286
2286
|
getLogger(e, t, n) {
|
|
2287
|
-
return this._getDelegateLogger(e, t, n) ?? new
|
|
2287
|
+
return this._getDelegateLogger(e, t, n) ?? new Ei(this, e, t, n);
|
|
2288
2288
|
}
|
|
2289
2289
|
_getDelegate() {
|
|
2290
|
-
return this._delegate ??
|
|
2290
|
+
return this._delegate ?? Ti;
|
|
2291
2291
|
}
|
|
2292
2292
|
_setDelegate(e) {
|
|
2293
2293
|
this._delegate = e;
|
|
@@ -2295,52 +2295,52 @@ var Ci = new class {
|
|
|
2295
2295
|
_getDelegateLogger(e, t, n) {
|
|
2296
2296
|
return this._delegate?.getLogger(e, t, n);
|
|
2297
2297
|
}
|
|
2298
|
-
},
|
|
2298
|
+
}, Oi = class e {
|
|
2299
2299
|
constructor() {
|
|
2300
|
-
this._proxyLoggerProvider = new
|
|
2300
|
+
this._proxyLoggerProvider = new Di();
|
|
2301
2301
|
}
|
|
2302
2302
|
static getInstance() {
|
|
2303
2303
|
return this._instance ||= new e(), this._instance;
|
|
2304
2304
|
}
|
|
2305
2305
|
setGlobalLoggerProvider(e) {
|
|
2306
|
-
return
|
|
2306
|
+
return K[Ci] ? this.getLoggerProvider() : (K[Ci] = wi(1, e, Ti), this._proxyLoggerProvider._setDelegate(e), e);
|
|
2307
2307
|
}
|
|
2308
2308
|
getLoggerProvider() {
|
|
2309
|
-
return
|
|
2309
|
+
return K[Ci]?.call(K, 1) ?? this._proxyLoggerProvider;
|
|
2310
2310
|
}
|
|
2311
2311
|
getLogger(e, t, n) {
|
|
2312
2312
|
return this.getLoggerProvider().getLogger(e, t, n);
|
|
2313
2313
|
}
|
|
2314
2314
|
disable() {
|
|
2315
|
-
delete
|
|
2315
|
+
delete K[Ci], this._proxyLoggerProvider = new Di();
|
|
2316
2316
|
}
|
|
2317
2317
|
}.getInstance();
|
|
2318
2318
|
//#endregion
|
|
2319
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-transformer@0.
|
|
2320
|
-
function
|
|
2319
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-transformer@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-transformer/build/esm/common/internal.js
|
|
2320
|
+
function ki(e, t) {
|
|
2321
2321
|
let n = {
|
|
2322
|
-
attributes:
|
|
2322
|
+
attributes: q(e.attributes, t),
|
|
2323
2323
|
droppedAttributesCount: 0
|
|
2324
2324
|
}, r = e.schemaUrl;
|
|
2325
2325
|
return r && r !== "" && (n.schemaUrl = r), n;
|
|
2326
2326
|
}
|
|
2327
|
-
function
|
|
2327
|
+
function Ai(e, t) {
|
|
2328
2328
|
let n = {
|
|
2329
2329
|
name: e.name,
|
|
2330
2330
|
version: e.version
|
|
2331
2331
|
};
|
|
2332
|
-
return e.attributes && Object.keys(e.attributes).length > 0 && (n.attributes =
|
|
2332
|
+
return e.attributes && Object.keys(e.attributes).length > 0 && (n.attributes = q(e.attributes, t), n.droppedAttributesCount = e.droppedAttributesCount ?? 0), n;
|
|
2333
2333
|
}
|
|
2334
|
-
function
|
|
2335
|
-
return Object.keys(e).map((n) =>
|
|
2334
|
+
function q(e, t) {
|
|
2335
|
+
return Object.keys(e).map((n) => ji(n, e[n], t));
|
|
2336
2336
|
}
|
|
2337
|
-
function
|
|
2337
|
+
function ji(e, t, n) {
|
|
2338
2338
|
return {
|
|
2339
2339
|
key: e,
|
|
2340
|
-
value:
|
|
2340
|
+
value: Mi(t, n)
|
|
2341
2341
|
};
|
|
2342
2342
|
}
|
|
2343
|
-
function
|
|
2343
|
+
function Mi(e, t) {
|
|
2344
2344
|
let n = typeof e;
|
|
2345
2345
|
if (n === "string") return { stringValue: e };
|
|
2346
2346
|
if (n === "number") return Number.isInteger(e) ? { intValue: e } : { doubleValue: e };
|
|
@@ -2348,48 +2348,48 @@ function Ai(e, t) {
|
|
|
2348
2348
|
if (e instanceof Uint8Array) return { bytesValue: t.encodeUint8Array(e) };
|
|
2349
2349
|
if (Array.isArray(e)) {
|
|
2350
2350
|
let n = Array(e.length);
|
|
2351
|
-
for (let r = 0; r < e.length; r++) n[r] =
|
|
2351
|
+
for (let r = 0; r < e.length; r++) n[r] = Mi(e[r], t);
|
|
2352
2352
|
return { arrayValue: { values: n } };
|
|
2353
2353
|
}
|
|
2354
2354
|
if (n === "object" && e != null) {
|
|
2355
2355
|
let n = Object.keys(e), r = Array(n.length);
|
|
2356
2356
|
for (let i = 0; i < n.length; i++) r[i] = {
|
|
2357
2357
|
key: n[i],
|
|
2358
|
-
value:
|
|
2358
|
+
value: Mi(e[n[i]], t)
|
|
2359
2359
|
};
|
|
2360
2360
|
return { kvlistValue: { values: r } };
|
|
2361
2361
|
}
|
|
2362
2362
|
return {};
|
|
2363
2363
|
}
|
|
2364
2364
|
//#endregion
|
|
2365
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-transformer@0.
|
|
2366
|
-
function
|
|
2365
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-transformer@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-transformer/build/esm/common/utils.js
|
|
2366
|
+
function Ni(e) {
|
|
2367
2367
|
let t = BigInt(1e9);
|
|
2368
2368
|
return BigInt(Math.trunc(e[0])) * t + BigInt(Math.trunc(e[1]));
|
|
2369
2369
|
}
|
|
2370
|
-
function Mi(e) {
|
|
2371
|
-
return ji(e).toString();
|
|
2372
|
-
}
|
|
2373
|
-
var Ni = typeof BigInt < "u" ? Mi : F;
|
|
2374
2370
|
function Pi(e) {
|
|
2371
|
+
return Ni(e).toString();
|
|
2372
|
+
}
|
|
2373
|
+
var Fi = typeof BigInt < "u" ? Pi : P;
|
|
2374
|
+
function Ii(e) {
|
|
2375
2375
|
return e;
|
|
2376
2376
|
}
|
|
2377
|
-
var
|
|
2378
|
-
encodeHrTime:
|
|
2379
|
-
encodeSpanContext:
|
|
2380
|
-
encodeOptionalSpanContext:
|
|
2377
|
+
var Li = {
|
|
2378
|
+
encodeHrTime: Fi,
|
|
2379
|
+
encodeSpanContext: Ii,
|
|
2380
|
+
encodeOptionalSpanContext: Ii,
|
|
2381
2381
|
encodeUint8Array: (e) => {
|
|
2382
2382
|
if (typeof Buffer < "u") return Buffer.from(e).toString("base64");
|
|
2383
2383
|
let t = Array(e.length);
|
|
2384
2384
|
for (let n = 0; n < e.length; n++) t[n] = String.fromCharCode(e[n]);
|
|
2385
2385
|
return btoa(t.join(""));
|
|
2386
2386
|
}
|
|
2387
|
-
},
|
|
2388
|
-
function
|
|
2389
|
-
let n = e & 255 |
|
|
2390
|
-
return t && (n |=
|
|
2387
|
+
}, Ri = 256, zi = 512;
|
|
2388
|
+
function Bi(e, t) {
|
|
2389
|
+
let n = e & 255 | Ri;
|
|
2390
|
+
return t && (n |= zi), n;
|
|
2391
2391
|
}
|
|
2392
|
-
function
|
|
2392
|
+
function Vi(e, t) {
|
|
2393
2393
|
let n = e.spanContext(), r = e.status, i = e.parentSpanContext?.spanId ? t.encodeSpanContext(e.parentSpanContext?.spanId) : void 0;
|
|
2394
2394
|
return {
|
|
2395
2395
|
traceId: t.encodeSpanContext(n.traceId),
|
|
@@ -2400,41 +2400,41 @@ function zi(e, t) {
|
|
|
2400
2400
|
kind: e.kind == null ? 0 : e.kind + 1,
|
|
2401
2401
|
startTimeUnixNano: t.encodeHrTime(e.startTime),
|
|
2402
2402
|
endTimeUnixNano: t.encodeHrTime(e.endTime),
|
|
2403
|
-
attributes:
|
|
2403
|
+
attributes: q(e.attributes, t),
|
|
2404
2404
|
droppedAttributesCount: e.droppedAttributesCount,
|
|
2405
|
-
events: e.events.map((e) =>
|
|
2405
|
+
events: e.events.map((e) => Ui(e, t)),
|
|
2406
2406
|
droppedEventsCount: e.droppedEventsCount,
|
|
2407
2407
|
status: {
|
|
2408
2408
|
code: r.code,
|
|
2409
2409
|
message: r.message
|
|
2410
2410
|
},
|
|
2411
|
-
links: e.links.map((e) =>
|
|
2411
|
+
links: e.links.map((e) => Hi(e, t)),
|
|
2412
2412
|
droppedLinksCount: e.droppedLinksCount,
|
|
2413
|
-
flags:
|
|
2413
|
+
flags: Bi(n.traceFlags, e.parentSpanContext?.isRemote)
|
|
2414
2414
|
};
|
|
2415
2415
|
}
|
|
2416
|
-
function
|
|
2416
|
+
function Hi(e, t) {
|
|
2417
2417
|
return {
|
|
2418
|
-
attributes: e.attributes ?
|
|
2418
|
+
attributes: e.attributes ? q(e.attributes, t) : [],
|
|
2419
2419
|
spanId: t.encodeSpanContext(e.context.spanId),
|
|
2420
2420
|
traceId: t.encodeSpanContext(e.context.traceId),
|
|
2421
2421
|
traceState: e.context.traceState?.serialize(),
|
|
2422
2422
|
droppedAttributesCount: e.droppedAttributesCount || 0,
|
|
2423
|
-
flags:
|
|
2423
|
+
flags: Bi(e.context.traceFlags, e.context.isRemote)
|
|
2424
2424
|
};
|
|
2425
2425
|
}
|
|
2426
|
-
function
|
|
2426
|
+
function Ui(e, t) {
|
|
2427
2427
|
return {
|
|
2428
|
-
attributes: e.attributes ?
|
|
2428
|
+
attributes: e.attributes ? q(e.attributes, t) : [],
|
|
2429
2429
|
name: e.name,
|
|
2430
2430
|
timeUnixNano: t.encodeHrTime(e.time),
|
|
2431
2431
|
droppedAttributesCount: e.droppedAttributesCount || 0
|
|
2432
2432
|
};
|
|
2433
2433
|
}
|
|
2434
|
-
function
|
|
2435
|
-
return { resourceSpans:
|
|
2434
|
+
function Wi(e, t) {
|
|
2435
|
+
return { resourceSpans: Ki(e, t) };
|
|
2436
2436
|
}
|
|
2437
|
-
function
|
|
2437
|
+
function Gi(e) {
|
|
2438
2438
|
let t = /* @__PURE__ */ new Map();
|
|
2439
2439
|
for (let n of e) {
|
|
2440
2440
|
let e = t.get(n.resource);
|
|
@@ -2444,23 +2444,23 @@ function Ui(e) {
|
|
|
2444
2444
|
}
|
|
2445
2445
|
return t;
|
|
2446
2446
|
}
|
|
2447
|
-
function
|
|
2448
|
-
let n =
|
|
2447
|
+
function Ki(e, t) {
|
|
2448
|
+
let n = Gi(e), r = [], i = n.entries(), a = i.next();
|
|
2449
2449
|
for (; !a.done;) {
|
|
2450
2450
|
let [e, n] = a.value, o = [], s = n.values(), c = s.next();
|
|
2451
2451
|
for (; !c.done;) {
|
|
2452
2452
|
let e = c.value;
|
|
2453
2453
|
if (e.length > 0) {
|
|
2454
|
-
let n = e.map((e) =>
|
|
2454
|
+
let n = e.map((e) => Vi(e, t));
|
|
2455
2455
|
o.push({
|
|
2456
|
-
scope:
|
|
2456
|
+
scope: Ai(e[0].instrumentationScope, t),
|
|
2457
2457
|
spans: n,
|
|
2458
2458
|
schemaUrl: e[0].instrumentationScope.schemaUrl
|
|
2459
2459
|
});
|
|
2460
2460
|
}
|
|
2461
2461
|
c = s.next();
|
|
2462
2462
|
}
|
|
2463
|
-
let l =
|
|
2463
|
+
let l = ki(e, t), u = {
|
|
2464
2464
|
resource: l,
|
|
2465
2465
|
scopeSpans: o,
|
|
2466
2466
|
schemaUrl: l.schemaUrl
|
|
@@ -2470,10 +2470,10 @@ function Wi(e, t) {
|
|
|
2470
2470
|
return r;
|
|
2471
2471
|
}
|
|
2472
2472
|
//#endregion
|
|
2473
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-transformer@0.
|
|
2474
|
-
var
|
|
2473
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-transformer@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-transformer/build/esm/trace/json/trace.js
|
|
2474
|
+
var qi = {
|
|
2475
2475
|
serializeRequest: (e) => {
|
|
2476
|
-
let t =
|
|
2476
|
+
let t = Wi(e, Li);
|
|
2477
2477
|
return new TextEncoder().encode(JSON.stringify(t));
|
|
2478
2478
|
},
|
|
2479
2479
|
deserializeResponse: (e) => {
|
|
@@ -2482,14 +2482,14 @@ var Gi = {
|
|
|
2482
2482
|
try {
|
|
2483
2483
|
return JSON.parse(t.decode(e));
|
|
2484
2484
|
} catch (e) {
|
|
2485
|
-
return
|
|
2485
|
+
return T.warn(`Failed to parse trace export response: ${e.message}. Returning empty response`), {};
|
|
2486
2486
|
}
|
|
2487
2487
|
}
|
|
2488
|
-
},
|
|
2489
|
-
function
|
|
2490
|
-
return 2 *
|
|
2488
|
+
}, Ji = 5, Yi = 1e3, Xi = 5e3, Zi = 1.5, Qi = .2;
|
|
2489
|
+
function $i() {
|
|
2490
|
+
return 2 * Qi * Math.random() - Qi;
|
|
2491
2491
|
}
|
|
2492
|
-
var
|
|
2492
|
+
var ea = class {
|
|
2493
2493
|
_transport;
|
|
2494
2494
|
constructor(e) {
|
|
2495
2495
|
this._transport = e;
|
|
@@ -2502,30 +2502,30 @@ var Qi = class {
|
|
|
2502
2502
|
});
|
|
2503
2503
|
}
|
|
2504
2504
|
async send(e, t) {
|
|
2505
|
-
let n =
|
|
2505
|
+
let n = Ji, r = Yi, i = Date.now() + t, a = await this._transport.send(e, t);
|
|
2506
2506
|
for (; a.status === "retryable" && n > 0;) {
|
|
2507
2507
|
n--;
|
|
2508
|
-
let t = Math.max(Math.min(r * (1 +
|
|
2509
|
-
r *=
|
|
2508
|
+
let t = Math.max(Math.min(r * (1 + $i()), Xi), 0);
|
|
2509
|
+
r *= Zi;
|
|
2510
2510
|
let o = a.retryInMillis ?? t, s = i - Date.now();
|
|
2511
|
-
if (o > s) return
|
|
2512
|
-
|
|
2511
|
+
if (o > s) return T.info(`Export retry time ${Math.round(o)}ms exceeds remaining timeout ${Math.round(s)}ms, not retrying further.`), a;
|
|
2512
|
+
T.verbose(`Scheduling export retry in ${Math.round(o)}ms`), a = await this.retry(e, s, o);
|
|
2513
2513
|
}
|
|
2514
|
-
return a.status === "success" ?
|
|
2514
|
+
return a.status === "success" ? T.verbose(`Export succeeded after ${Ji - n} retry attempts.`) : a.status === "retryable" ? T.info(`Export failed after maximum retry attempts (${Ji}).`) : T.info(`Export failed with non-retryable error: ${a.error}`), a;
|
|
2515
2515
|
}
|
|
2516
2516
|
shutdown() {
|
|
2517
2517
|
return this._transport.shutdown();
|
|
2518
2518
|
}
|
|
2519
2519
|
};
|
|
2520
|
-
function
|
|
2521
|
-
return new
|
|
2520
|
+
function ta(e) {
|
|
2521
|
+
return new ea(e.transport);
|
|
2522
2522
|
}
|
|
2523
2523
|
//#endregion
|
|
2524
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2525
|
-
function
|
|
2524
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/is-export-retryable.js
|
|
2525
|
+
function na(e) {
|
|
2526
2526
|
return e === 429 || e === 502 || e === 503 || e === 504;
|
|
2527
2527
|
}
|
|
2528
|
-
function
|
|
2528
|
+
function ra(e) {
|
|
2529
2529
|
if (e == null) return;
|
|
2530
2530
|
let t = Number.parseInt(e, 10);
|
|
2531
2531
|
if (Number.isInteger(t)) return t > 0 ? t * 1e3 : -1;
|
|
@@ -2533,8 +2533,8 @@ function ta(e) {
|
|
|
2533
2533
|
return n >= 0 ? n : 0;
|
|
2534
2534
|
}
|
|
2535
2535
|
//#endregion
|
|
2536
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2537
|
-
var
|
|
2536
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/transport/fetch-transport.js
|
|
2537
|
+
var ia = 61440, aa = 9, oa = 0, sa = 0, ca = class {
|
|
2538
2538
|
_parameters;
|
|
2539
2539
|
constructor(e) {
|
|
2540
2540
|
this._parameters = e;
|
|
@@ -2542,11 +2542,11 @@ var na = 61440, ra = 9, ia = 0, aa = 0, oa = class {
|
|
|
2542
2542
|
async send(e, t) {
|
|
2543
2543
|
let n = new AbortController(), r = setTimeout(() => n.abort(), t), i = globalThis.fetch;
|
|
2544
2544
|
typeof i.__original == "function" && (i = i.__original);
|
|
2545
|
-
let a = e.byteLength, o =
|
|
2546
|
-
if (s)
|
|
2545
|
+
let a = e.byteLength, o = oa + a > ia, s = !o && !(sa >= aa);
|
|
2546
|
+
if (s) oa += a, sa++;
|
|
2547
2547
|
else {
|
|
2548
2548
|
let e = o ? "size limit" : "count limit";
|
|
2549
|
-
|
|
2549
|
+
T.debug(`keepalive disabled: ${(a / 1024).toFixed(1)}KB payload, ${sa} pending (${e})`);
|
|
2550
2550
|
}
|
|
2551
2551
|
try {
|
|
2552
2552
|
let t = new URL(this._parameters.url), r = await i(t.href, {
|
|
@@ -2557,55 +2557,55 @@ var na = 61440, ra = 9, ia = 0, aa = 0, oa = class {
|
|
|
2557
2557
|
keepalive: s,
|
|
2558
2558
|
mode: globalThis.location ? globalThis.location.origin === t.origin ? "same-origin" : "cors" : "no-cors"
|
|
2559
2559
|
});
|
|
2560
|
-
return r.status >= 200 && r.status <= 299 ? (
|
|
2560
|
+
return r.status >= 200 && r.status <= 299 ? (T.debug(`export response success (status: ${r.status})`), { status: "success" }) : na(r.status) ? (T.warn(`export response retryable (status: ${r.status})`), {
|
|
2561
2561
|
status: "retryable",
|
|
2562
|
-
retryInMillis:
|
|
2563
|
-
}) : (
|
|
2562
|
+
retryInMillis: ra(r.headers.get("Retry-After"))
|
|
2563
|
+
}) : (T.error(`export response failure (status: ${r.status})`), {
|
|
2564
2564
|
status: "failure",
|
|
2565
2565
|
error: /* @__PURE__ */ Error(`Fetch request failed with non-retryable status ${r.status}`)
|
|
2566
2566
|
});
|
|
2567
2567
|
} catch (e) {
|
|
2568
|
-
return
|
|
2568
|
+
return ua(e) ? (T.warn(`export request retryable (network error: ${e})`), {
|
|
2569
2569
|
status: "retryable",
|
|
2570
2570
|
error: Error("Fetch request encountered a network error", { cause: e })
|
|
2571
|
-
}) : (
|
|
2571
|
+
}) : (T.error(`export request failure (error: ${e})`), {
|
|
2572
2572
|
status: "failure",
|
|
2573
2573
|
error: Error("Fetch request errored", { cause: e })
|
|
2574
2574
|
});
|
|
2575
2575
|
} finally {
|
|
2576
|
-
clearTimeout(r), s && (
|
|
2576
|
+
clearTimeout(r), s && (oa -= a, sa--);
|
|
2577
2577
|
}
|
|
2578
2578
|
}
|
|
2579
2579
|
shutdown() {}
|
|
2580
2580
|
};
|
|
2581
|
-
function
|
|
2582
|
-
return new
|
|
2581
|
+
function la(e) {
|
|
2582
|
+
return new ca(e);
|
|
2583
2583
|
}
|
|
2584
|
-
function
|
|
2584
|
+
function ua(e) {
|
|
2585
2585
|
return e instanceof TypeError && !e.cause;
|
|
2586
2586
|
}
|
|
2587
2587
|
//#endregion
|
|
2588
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2589
|
-
function
|
|
2590
|
-
return
|
|
2588
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/otlp-browser-http-export-delegate.js
|
|
2589
|
+
function da(e, t, n) {
|
|
2590
|
+
return ui(e, t, n, ta({ transport: la(e) }));
|
|
2591
2591
|
}
|
|
2592
2592
|
//#endregion
|
|
2593
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2594
|
-
function
|
|
2593
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/util.js
|
|
2594
|
+
function fa(e) {
|
|
2595
2595
|
let t = {};
|
|
2596
2596
|
return Object.entries(e ?? {}).forEach(([e, n]) => {
|
|
2597
|
-
n === void 0 ?
|
|
2597
|
+
n === void 0 ? T.warn(`Header "${e}" has invalid value (${n}) and will be ignored`) : t[e] = String(n);
|
|
2598
2598
|
}), t;
|
|
2599
2599
|
}
|
|
2600
2600
|
//#endregion
|
|
2601
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2602
|
-
function
|
|
2601
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/configuration/otlp-http-configuration.js
|
|
2602
|
+
function pa(e, t, n) {
|
|
2603
2603
|
return async () => {
|
|
2604
2604
|
let r = { ...await n() }, i = {};
|
|
2605
|
-
return t != null && Object.assign(i, await t()), e != null && Object.assign(i,
|
|
2605
|
+
return t != null && Object.assign(i, await t()), e != null && Object.assign(i, fa(await e())), Object.assign(i, r);
|
|
2606
2606
|
};
|
|
2607
2607
|
}
|
|
2608
|
-
function
|
|
2608
|
+
function ma(e) {
|
|
2609
2609
|
if (e != null) try {
|
|
2610
2610
|
let t = globalThis.location?.href;
|
|
2611
2611
|
return new URL(e, t).href;
|
|
@@ -2613,66 +2613,66 @@ function fa(e) {
|
|
|
2613
2613
|
throw Error(`Configuration: Could not parse user-provided export URL: '${e}'`);
|
|
2614
2614
|
}
|
|
2615
2615
|
}
|
|
2616
|
-
function
|
|
2616
|
+
function ha(e, t, n) {
|
|
2617
2617
|
return {
|
|
2618
|
-
...
|
|
2619
|
-
headers:
|
|
2620
|
-
url:
|
|
2618
|
+
...ni(e, t, n),
|
|
2619
|
+
headers: pa(e.headers, t.headers, n.headers),
|
|
2620
|
+
url: ma(e.url) ?? t.url ?? n.url
|
|
2621
2621
|
};
|
|
2622
2622
|
}
|
|
2623
|
-
function
|
|
2623
|
+
function ga(e, t) {
|
|
2624
2624
|
return {
|
|
2625
|
-
...
|
|
2625
|
+
...ri(),
|
|
2626
2626
|
headers: async () => e,
|
|
2627
2627
|
url: "http://localhost:4318/" + t
|
|
2628
2628
|
};
|
|
2629
2629
|
}
|
|
2630
2630
|
//#endregion
|
|
2631
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2632
|
-
function
|
|
2633
|
-
return typeof e.headers == "function" ? e.headers :
|
|
2631
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/configuration/convert-legacy-http-options.js
|
|
2632
|
+
function _a(e) {
|
|
2633
|
+
return typeof e.headers == "function" ? e.headers : ti(e.headers);
|
|
2634
2634
|
}
|
|
2635
2635
|
//#endregion
|
|
2636
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2637
|
-
function
|
|
2638
|
-
return
|
|
2636
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/configuration/convert-legacy-browser-http-options.js
|
|
2637
|
+
function va(e, t, n) {
|
|
2638
|
+
return ha({
|
|
2639
2639
|
url: e.url,
|
|
2640
2640
|
timeoutMillis: e.timeoutMillis,
|
|
2641
|
-
headers:
|
|
2641
|
+
headers: _a(e),
|
|
2642
2642
|
concurrencyLimit: e.concurrencyLimit
|
|
2643
|
-
}, {},
|
|
2643
|
+
}, {}, ga(n, t));
|
|
2644
2644
|
}
|
|
2645
2645
|
//#endregion
|
|
2646
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.
|
|
2647
|
-
function
|
|
2648
|
-
return new
|
|
2646
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+otlp-exporter-base@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/otlp-exporter-base/build/esm/configuration/create-legacy-browser-delegate.js
|
|
2647
|
+
function ya(e, t, n, r) {
|
|
2648
|
+
return new yi({
|
|
2649
2649
|
componentType: e,
|
|
2650
2650
|
metricsHelper: t,
|
|
2651
2651
|
url: n,
|
|
2652
2652
|
meterProvider: r,
|
|
2653
2653
|
responseAttributesFromError: (e) => {
|
|
2654
|
-
if (!e) return { [
|
|
2654
|
+
if (!e) return { [di]: 200 };
|
|
2655
2655
|
if (!(e instanceof Error)) return {};
|
|
2656
2656
|
if (e.message.startsWith("Fetch request failed with non-retryable status ")) {
|
|
2657
2657
|
let t = e.message.substring(47);
|
|
2658
|
-
return { [
|
|
2658
|
+
return { [di]: Number(t) };
|
|
2659
2659
|
}
|
|
2660
2660
|
return {};
|
|
2661
2661
|
}
|
|
2662
2662
|
});
|
|
2663
2663
|
}
|
|
2664
|
-
function
|
|
2665
|
-
let s =
|
|
2666
|
-
return
|
|
2664
|
+
function ba(e, t, n, r, i, a, o) {
|
|
2665
|
+
let s = va(e, a, o);
|
|
2666
|
+
return da(s, t, ya(n, r, s.url, e.selfObsMeterProvider));
|
|
2667
2667
|
}
|
|
2668
2668
|
//#endregion
|
|
2669
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+exporter-trace-otlp-http@0.
|
|
2670
|
-
var
|
|
2669
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+exporter-trace-otlp-http@0.222.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/exporter-trace-otlp-http/build/esm/semconv.js
|
|
2670
|
+
var xa = "otlp_http_span_exporter", Sa = class extends Qr {
|
|
2671
2671
|
constructor(e = {}) {
|
|
2672
|
-
super(
|
|
2672
|
+
super(ba(e, qi, xa, bi, e.selfObsMeterProvider, "v1/traces", { "Content-Type": "application/json" }));
|
|
2673
2673
|
}
|
|
2674
|
-
},
|
|
2675
|
-
function
|
|
2674
|
+
}, J = console.error.bind(console);
|
|
2675
|
+
function Y(e, t, n) {
|
|
2676
2676
|
let r = !!e[t] && Object.prototype.propertyIsEnumerable.call(e, t);
|
|
2677
2677
|
Object.defineProperty(e, t, {
|
|
2678
2678
|
configurable: !0,
|
|
@@ -2681,66 +2681,66 @@ function Z(e, t, n) {
|
|
|
2681
2681
|
value: n
|
|
2682
2682
|
});
|
|
2683
2683
|
}
|
|
2684
|
-
var
|
|
2684
|
+
var Ca = (e, t, n) => {
|
|
2685
2685
|
if (!e || !e[t]) {
|
|
2686
|
-
|
|
2686
|
+
J("no original function " + String(t) + " to wrap");
|
|
2687
2687
|
return;
|
|
2688
2688
|
}
|
|
2689
2689
|
if (!n) {
|
|
2690
|
-
|
|
2690
|
+
J("no wrapper function"), J((/* @__PURE__ */ Error()).stack);
|
|
2691
2691
|
return;
|
|
2692
2692
|
}
|
|
2693
2693
|
let r = e[t];
|
|
2694
2694
|
if (typeof r != "function" || typeof n != "function") {
|
|
2695
|
-
|
|
2695
|
+
J("original object and wrapper must be functions");
|
|
2696
2696
|
return;
|
|
2697
2697
|
}
|
|
2698
2698
|
let i = n(r, t);
|
|
2699
|
-
return
|
|
2700
|
-
e[t] === i &&
|
|
2701
|
-
}),
|
|
2702
|
-
},
|
|
2699
|
+
return Y(i, "__original", r), Y(i, "__unwrap", () => {
|
|
2700
|
+
e[t] === i && Y(e, t, r);
|
|
2701
|
+
}), Y(i, "__wrapped", !0), Y(e, t, i), i;
|
|
2702
|
+
}, wa = (e, t, n) => {
|
|
2703
2703
|
if (e) Array.isArray(e) || (e = [e]);
|
|
2704
2704
|
else {
|
|
2705
|
-
|
|
2705
|
+
J("must provide one or more modules to patch"), J((/* @__PURE__ */ Error()).stack);
|
|
2706
2706
|
return;
|
|
2707
2707
|
}
|
|
2708
2708
|
if (!(t && Array.isArray(t))) {
|
|
2709
|
-
|
|
2709
|
+
J("must provide one or more functions to wrap on modules");
|
|
2710
2710
|
return;
|
|
2711
2711
|
}
|
|
2712
2712
|
e.forEach((e) => {
|
|
2713
2713
|
t.forEach((t) => {
|
|
2714
|
-
|
|
2714
|
+
Ca(e, t, n);
|
|
2715
2715
|
});
|
|
2716
2716
|
});
|
|
2717
|
-
},
|
|
2717
|
+
}, Ta = (e, t) => {
|
|
2718
2718
|
if (!e || !e[t]) {
|
|
2719
|
-
|
|
2719
|
+
J("no function to unwrap."), J((/* @__PURE__ */ Error()).stack);
|
|
2720
2720
|
return;
|
|
2721
2721
|
}
|
|
2722
2722
|
let n = e[t];
|
|
2723
|
-
if (!n.__unwrap)
|
|
2723
|
+
if (!n.__unwrap) J("no original to unwrap to -- has " + String(t) + " already been unwrapped?");
|
|
2724
2724
|
else {
|
|
2725
2725
|
n.__unwrap();
|
|
2726
2726
|
return;
|
|
2727
2727
|
}
|
|
2728
|
-
},
|
|
2728
|
+
}, Ea = (e, t) => {
|
|
2729
2729
|
if (e) Array.isArray(e) || (e = [e]);
|
|
2730
2730
|
else {
|
|
2731
|
-
|
|
2731
|
+
J("must provide one or more modules to patch"), J((/* @__PURE__ */ Error()).stack);
|
|
2732
2732
|
return;
|
|
2733
2733
|
}
|
|
2734
2734
|
if (!(t && Array.isArray(t))) {
|
|
2735
|
-
|
|
2735
|
+
J("must provide one or more functions to unwrap on modules");
|
|
2736
2736
|
return;
|
|
2737
2737
|
}
|
|
2738
2738
|
e.forEach((e) => {
|
|
2739
2739
|
t.forEach((t) => {
|
|
2740
|
-
|
|
2740
|
+
Ta(e, t);
|
|
2741
2741
|
});
|
|
2742
2742
|
});
|
|
2743
|
-
},
|
|
2743
|
+
}, Da = class {
|
|
2744
2744
|
_config = {};
|
|
2745
2745
|
_tracer;
|
|
2746
2746
|
_meter;
|
|
@@ -2749,12 +2749,12 @@ var xa = (e, t, n) => {
|
|
|
2749
2749
|
instrumentationName;
|
|
2750
2750
|
instrumentationVersion;
|
|
2751
2751
|
constructor(e, t, n) {
|
|
2752
|
-
this.instrumentationName = e, this.instrumentationVersion = t, this.setConfig(n), this._diag =
|
|
2752
|
+
this.instrumentationName = e, this.instrumentationVersion = t, this.setConfig(n), this._diag = T.createComponentLogger({ namespace: e }), this._tracer = D.getTracer(e, t), this._meter = st.getMeter(e, t), this._logger = Oi.getLogger(e, t), this._updateMetricInstruments();
|
|
2753
2753
|
}
|
|
2754
|
-
_wrap =
|
|
2755
|
-
_unwrap =
|
|
2756
|
-
_massWrap =
|
|
2757
|
-
_massUnwrap =
|
|
2754
|
+
_wrap = Ca;
|
|
2755
|
+
_unwrap = Ta;
|
|
2756
|
+
_massWrap = wa;
|
|
2757
|
+
_massUnwrap = Ea;
|
|
2758
2758
|
get meter() {
|
|
2759
2759
|
return this._meter;
|
|
2760
2760
|
}
|
|
@@ -2794,14 +2794,14 @@ var xa = (e, t, n) => {
|
|
|
2794
2794
|
this._diag.error("Error running span customization hook due to exception in handler", { triggerName: t }, e);
|
|
2795
2795
|
}
|
|
2796
2796
|
}
|
|
2797
|
-
},
|
|
2797
|
+
}, Oa = class extends Da {
|
|
2798
2798
|
constructor(e, t, n) {
|
|
2799
2799
|
super(e, t, n), this._config.enabled && this.enable();
|
|
2800
2800
|
}
|
|
2801
2801
|
};
|
|
2802
2802
|
//#endregion
|
|
2803
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation@0.
|
|
2804
|
-
function
|
|
2803
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation@0.222.0_@opentelemetry+api@1.9.1_supports-color@10.2.2/node_modules/@opentelemetry/instrumentation/build/esm/utils.js
|
|
2804
|
+
function X(e, t, n) {
|
|
2805
2805
|
let r, i;
|
|
2806
2806
|
try {
|
|
2807
2807
|
i = e();
|
|
@@ -2813,25 +2813,25 @@ function Q(e, t, n) {
|
|
|
2813
2813
|
}
|
|
2814
2814
|
}
|
|
2815
2815
|
//#endregion
|
|
2816
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-fetch@0.
|
|
2817
|
-
var
|
|
2818
|
-
function
|
|
2816
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-fetch@0.222.0_@opentelemetry+api@1.9.1_supports-color@10.2.2/node_modules/@opentelemetry/instrumentation-fetch/build/esm/semconv.js
|
|
2817
|
+
var ka = "http.request.body.size", Aa = T.createComponentLogger({ namespace: "@opentelemetry/opentelemetry-instrumentation-fetch/utils" });
|
|
2818
|
+
function ja(...e) {
|
|
2819
2819
|
if (e[0] instanceof URL || typeof e[0] == "string") {
|
|
2820
2820
|
let t = e[1];
|
|
2821
2821
|
if (!t?.body) return Promise.resolve();
|
|
2822
2822
|
if (t.body instanceof ReadableStream) {
|
|
2823
|
-
let { body: e, length: n } =
|
|
2823
|
+
let { body: e, length: n } = Ma(t.body);
|
|
2824
2824
|
return t.body = e, n;
|
|
2825
2825
|
}
|
|
2826
|
-
return Promise.resolve(
|
|
2826
|
+
return Promise.resolve(Pa(t.body));
|
|
2827
2827
|
}
|
|
2828
2828
|
{
|
|
2829
2829
|
let t = e[0];
|
|
2830
|
-
return t?.body ? t.clone().text().then((e) =>
|
|
2830
|
+
return t?.body ? t.clone().text().then((e) => Ia(e)) : Promise.resolve();
|
|
2831
2831
|
}
|
|
2832
2832
|
}
|
|
2833
|
-
function
|
|
2834
|
-
if (!e.pipeThrough) return
|
|
2833
|
+
function Ma(e) {
|
|
2834
|
+
if (!e.pipeThrough) return Aa.warn("Platform has ReadableStream but not pipeThrough!"), {
|
|
2835
2835
|
body: e,
|
|
2836
2836
|
length: Promise.resolve(void 0)
|
|
2837
2837
|
};
|
|
@@ -2852,32 +2852,32 @@ function Aa(e) {
|
|
|
2852
2852
|
length: r
|
|
2853
2853
|
};
|
|
2854
2854
|
}
|
|
2855
|
-
function
|
|
2855
|
+
function Na(e) {
|
|
2856
2856
|
return typeof Document < "u" && e instanceof Document;
|
|
2857
2857
|
}
|
|
2858
|
-
function
|
|
2859
|
-
if (
|
|
2860
|
-
if (typeof e == "string") return
|
|
2858
|
+
function Pa(e) {
|
|
2859
|
+
if (Na(e)) return new XMLSerializer().serializeToString(document).length;
|
|
2860
|
+
if (typeof e == "string") return Ia(e);
|
|
2861
2861
|
if (e instanceof Blob) return e.size;
|
|
2862
|
-
if (e instanceof FormData) return
|
|
2863
|
-
if (e instanceof URLSearchParams) return
|
|
2862
|
+
if (e instanceof FormData) return La(e);
|
|
2863
|
+
if (e instanceof URLSearchParams) return Ia(e.toString());
|
|
2864
2864
|
if (e.byteLength !== void 0) return e.byteLength;
|
|
2865
|
-
|
|
2865
|
+
Aa.warn("unknown body type");
|
|
2866
2866
|
}
|
|
2867
|
-
var
|
|
2868
|
-
function
|
|
2869
|
-
return
|
|
2867
|
+
var Fa = new TextEncoder();
|
|
2868
|
+
function Ia(e) {
|
|
2869
|
+
return Fa.encode(e).byteLength;
|
|
2870
2870
|
}
|
|
2871
|
-
function
|
|
2871
|
+
function La(e) {
|
|
2872
2872
|
let t = 0;
|
|
2873
2873
|
for (let [n, r] of e.entries()) t += n.length, r instanceof Blob ? t += r.size : t += r.length;
|
|
2874
2874
|
return t;
|
|
2875
2875
|
}
|
|
2876
|
-
function
|
|
2877
|
-
let t =
|
|
2876
|
+
function Ra(e) {
|
|
2877
|
+
let t = Va(), n = e.toUpperCase();
|
|
2878
2878
|
return n in t ? n : "_OTHER";
|
|
2879
2879
|
}
|
|
2880
|
-
var
|
|
2880
|
+
var za = {
|
|
2881
2881
|
CONNECT: !0,
|
|
2882
2882
|
DELETE: !0,
|
|
2883
2883
|
GET: !0,
|
|
@@ -2888,63 +2888,63 @@ var La = {
|
|
|
2888
2888
|
PUT: !0,
|
|
2889
2889
|
TRACE: !0,
|
|
2890
2890
|
QUERY: !0
|
|
2891
|
-
},
|
|
2892
|
-
function
|
|
2893
|
-
return
|
|
2891
|
+
}, Ba;
|
|
2892
|
+
function Va() {
|
|
2893
|
+
return Ba === void 0 && (Ba = za), Ba;
|
|
2894
2894
|
}
|
|
2895
|
-
var
|
|
2895
|
+
var Ha = {
|
|
2896
2896
|
"https:": "443",
|
|
2897
2897
|
"http:": "80"
|
|
2898
2898
|
};
|
|
2899
|
-
function
|
|
2900
|
-
let t = Number(e.port ||
|
|
2899
|
+
function Ua(e) {
|
|
2900
|
+
let t = Number(e.port || Ha[e.protocol]);
|
|
2901
2901
|
if (t && !isNaN(t)) return t;
|
|
2902
2902
|
}
|
|
2903
2903
|
//#endregion
|
|
2904
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-fetch@0.
|
|
2905
|
-
var
|
|
2904
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-fetch@0.222.0_@opentelemetry+api@1.9.1_supports-color@10.2.2/node_modules/@opentelemetry/instrumentation-fetch/build/esm/version.js
|
|
2905
|
+
var Wa = "0.222.0", Ga = 300, Ka = typeof PerformanceObserver < "u", qa = class extends Oa {
|
|
2906
2906
|
component = "fetch";
|
|
2907
|
-
version =
|
|
2907
|
+
version = Wa;
|
|
2908
2908
|
moduleName = this.component;
|
|
2909
2909
|
_usedResources = /* @__PURE__ */ new WeakSet();
|
|
2910
2910
|
_tasksCount = 0;
|
|
2911
2911
|
constructor(e = {}) {
|
|
2912
|
-
super("@opentelemetry/instrumentation-fetch",
|
|
2912
|
+
super("@opentelemetry/instrumentation-fetch", Wa, e);
|
|
2913
2913
|
}
|
|
2914
2914
|
init() {}
|
|
2915
2915
|
_addChildSpan(e, t) {
|
|
2916
|
-
let n = this.tracer.startSpan("CORS Preflight", { startTime: t[
|
|
2917
|
-
|
|
2916
|
+
let n = this.tracer.startSpan("CORS Preflight", { startTime: t[W.FETCH_START] }, D.setSpan(w.active(), e));
|
|
2917
|
+
Wr(n, t, this.getConfig().ignoreNetworkEvents, void 0, !0), n.end(t[W.RESPONSE_END]);
|
|
2918
2918
|
}
|
|
2919
2919
|
_addFinalSpanAttributes(e, t) {
|
|
2920
|
-
let n =
|
|
2920
|
+
let n = Xr(t.url);
|
|
2921
2921
|
e.setAttribute("http.response.status_code", t.status), e.setAttribute("server.address", n.hostname);
|
|
2922
|
-
let r =
|
|
2922
|
+
let r = Ua(n);
|
|
2923
2923
|
r && e.setAttribute("server.port", r);
|
|
2924
2924
|
}
|
|
2925
2925
|
_addHeaders(e, t) {
|
|
2926
|
-
if (!
|
|
2926
|
+
if (!Zr(t, this.getConfig().propagateTraceHeaderCorsUrls)) {
|
|
2927
2927
|
let e = {};
|
|
2928
|
-
|
|
2928
|
+
E.inject(w.active(), e), Object.keys(e).length > 0 && this._diag.debug("headers inject skipped due to CORS policy");
|
|
2929
2929
|
return;
|
|
2930
2930
|
}
|
|
2931
|
-
if (e instanceof Request)
|
|
2931
|
+
if (e instanceof Request) E.inject(w.active(), e.headers, { set: (e, t, n) => e.set(t, typeof n == "string" ? n : String(n)) });
|
|
2932
2932
|
else {
|
|
2933
2933
|
let t = new Headers(e.headers);
|
|
2934
|
-
|
|
2934
|
+
E.inject(w.active(), t, { set: (e, t, n) => e.set(t, typeof n == "string" ? n : String(n)) }), e.headers = t;
|
|
2935
2935
|
}
|
|
2936
2936
|
}
|
|
2937
2937
|
_clearResources() {
|
|
2938
2938
|
this._tasksCount === 0 && this.getConfig().clearTimingResources && (performance.clearResourceTimings(), this._usedResources = /* @__PURE__ */ new WeakSet());
|
|
2939
2939
|
}
|
|
2940
2940
|
_createSpan(e, t = {}) {
|
|
2941
|
-
if (
|
|
2941
|
+
if (Fn(e, this.getConfig().ignoreUrls)) {
|
|
2942
2942
|
this._diag.debug("ignoring span as url matches ignored url");
|
|
2943
2943
|
return;
|
|
2944
2944
|
}
|
|
2945
|
-
let n = {}, r = t.method, i =
|
|
2945
|
+
let n = {}, r = t.method, i = Ra(t.method || "GET"), a = i;
|
|
2946
2946
|
return n["http.request.method"] = i, i !== r && (n["http.request.method_original"] = r), n[c] = e, this.tracer.startSpan(a, {
|
|
2947
|
-
kind:
|
|
2947
|
+
kind: it.CLIENT,
|
|
2948
2948
|
attributes: n
|
|
2949
2949
|
});
|
|
2950
2950
|
}
|
|
@@ -2954,35 +2954,35 @@ var Ha = "0.221.0", Ua = 300, Wa = typeof PerformanceObserver < "u", Ga = class
|
|
|
2954
2954
|
if (!performance.getEntriesByType) return;
|
|
2955
2955
|
r = performance.getEntriesByType("resource");
|
|
2956
2956
|
}
|
|
2957
|
-
let i =
|
|
2957
|
+
let i = qr(t.spanUrl, t.startTime, n, r, this._usedResources, "fetch");
|
|
2958
2958
|
if (i.mainRequest) {
|
|
2959
2959
|
let t = i.mainRequest;
|
|
2960
2960
|
this._markResourceAsUsed(t);
|
|
2961
2961
|
let n = i.corsPreFlightRequest;
|
|
2962
|
-
n && (this._addChildSpan(e, n), this._markResourceAsUsed(n)),
|
|
2962
|
+
n && (this._addChildSpan(e, n), this._markResourceAsUsed(n)), Wr(e, t, this.getConfig().ignoreNetworkEvents, void 0, !0);
|
|
2963
2963
|
}
|
|
2964
2964
|
}
|
|
2965
2965
|
_markResourceAsUsed(e) {
|
|
2966
2966
|
this._usedResources.add(e);
|
|
2967
2967
|
}
|
|
2968
2968
|
_endSpan(t, n, r) {
|
|
2969
|
-
let i =
|
|
2970
|
-
this._addFinalSpanAttributes(t, r), r.status >= 400 && (t.setStatus({ code:
|
|
2969
|
+
let i = j(Date.now()), a = M();
|
|
2970
|
+
this._addFinalSpanAttributes(t, r), r.status >= 400 && (t.setStatus({ code: C.ERROR }), t.setAttribute(e, String(r.status))), setTimeout(() => {
|
|
2971
2971
|
n.observer?.disconnect(), this._findResourceAndAddNetworkEvents(t, n, a), this._tasksCount--, this._clearResources(), t.end(i);
|
|
2972
|
-
},
|
|
2972
|
+
}, Ga);
|
|
2973
2973
|
}
|
|
2974
2974
|
_patchConstructor() {
|
|
2975
2975
|
return (e) => {
|
|
2976
2976
|
let t = this;
|
|
2977
2977
|
return function(...n) {
|
|
2978
2978
|
if (!t._isEnabled) return e.apply(this, n);
|
|
2979
|
-
let r = this, i =
|
|
2979
|
+
let r = this, i = Xr(n[0] instanceof Request ? n[0].url : String(n[0])).href, a;
|
|
2980
2980
|
a = n[0] instanceof Request ? n[1] == null ? n[0] : new Request(n[0], n[1]) : n[1] || {};
|
|
2981
2981
|
let o = t._createSpan(i, a);
|
|
2982
2982
|
if (!o) return e.apply(this, n);
|
|
2983
2983
|
let s = t._prepareSpanData(i);
|
|
2984
|
-
t.getConfig().measureRequestSize &&
|
|
2985
|
-
e && o.setAttribute(
|
|
2984
|
+
t.getConfig().measureRequestSize && ja(...n).then((e) => {
|
|
2985
|
+
e && o.setAttribute(ka, e);
|
|
2986
2986
|
}).catch((e) => {
|
|
2987
2987
|
t._diag.warn("getFetchBodyLength", e);
|
|
2988
2988
|
});
|
|
@@ -3032,24 +3032,24 @@ var Ha = "0.221.0", Ua = 300, Wa = typeof PerformanceObserver < "u", Ga = class
|
|
|
3032
3032
|
}
|
|
3033
3033
|
throw n;
|
|
3034
3034
|
}
|
|
3035
|
-
return
|
|
3035
|
+
return w.with(D.setSpan(w.active(), o), () => (t._callRequestHook(o, a), t._addHeaders(a, i), t._tasksCount++, e.apply(r, a instanceof Request ? [a] : [i, a]).then(u.bind(r, o), ee.bind(r, o))));
|
|
3036
3036
|
};
|
|
3037
3037
|
};
|
|
3038
3038
|
}
|
|
3039
3039
|
_applyAttributesAfterFetch(e, t, n) {
|
|
3040
3040
|
let r = this.getConfig().applyCustomAttributesOnSpan;
|
|
3041
|
-
r &&
|
|
3041
|
+
r && X(() => r(e, t, n), (e) => {
|
|
3042
3042
|
e && this._diag.error("applyCustomAttributesOnSpan", e);
|
|
3043
3043
|
}, !0);
|
|
3044
3044
|
}
|
|
3045
3045
|
_callRequestHook(e, t) {
|
|
3046
3046
|
let n = this.getConfig().requestHook;
|
|
3047
|
-
n &&
|
|
3047
|
+
n && X(() => n(e, t), (e) => {
|
|
3048
3048
|
e && this._diag.error("requestHook", e);
|
|
3049
3049
|
}, !0);
|
|
3050
3050
|
}
|
|
3051
3051
|
_prepareSpanData(e) {
|
|
3052
|
-
let t =
|
|
3052
|
+
let t = M(), n = [];
|
|
3053
3053
|
if (typeof PerformanceObserver != "function") return {
|
|
3054
3054
|
entries: n,
|
|
3055
3055
|
startTime: t,
|
|
@@ -3068,7 +3068,7 @@ var Ha = "0.221.0", Ua = 300, Wa = typeof PerformanceObserver < "u", Ga = class
|
|
|
3068
3068
|
};
|
|
3069
3069
|
}
|
|
3070
3070
|
enable() {
|
|
3071
|
-
if (!
|
|
3071
|
+
if (!Ka) {
|
|
3072
3072
|
this._diag.warn("this instrumentation is intended for web usage only, it does not instrument server-side fetch()");
|
|
3073
3073
|
return;
|
|
3074
3074
|
}
|
|
@@ -3085,52 +3085,77 @@ var Ha = "0.221.0", Ua = 300, Wa = typeof PerformanceObserver < "u", Ga = class
|
|
|
3085
3085
|
}
|
|
3086
3086
|
}
|
|
3087
3087
|
disable() {
|
|
3088
|
-
|
|
3088
|
+
Ka && this._isEnabled && (this._isEnabled = !1, this._usedResources = /* @__PURE__ */ new WeakSet());
|
|
3089
|
+
}
|
|
3090
|
+
}, Ja = performance, Ya = "traceparent", Z;
|
|
3091
|
+
(function(e) {
|
|
3092
|
+
e.CONNECT_END = "connectEnd", e.CONNECT_START = "connectStart", e.DECODED_BODY_SIZE = "decodedBodySize", e.DOM_COMPLETE = "domComplete", e.DOM_CONTENT_LOADED_EVENT_END = "domContentLoadedEventEnd", e.DOM_CONTENT_LOADED_EVENT_START = "domContentLoadedEventStart", e.DOM_INTERACTIVE = "domInteractive", e.DOMAIN_LOOKUP_END = "domainLookupEnd", e.DOMAIN_LOOKUP_START = "domainLookupStart", e.ENCODED_BODY_SIZE = "encodedBodySize", e.FETCH_START = "fetchStart", e.LOAD_EVENT_END = "loadEventEnd", e.LOAD_EVENT_START = "loadEventStart", e.NAVIGATION_START = "navigationStart", e.REDIRECT_END = "redirectEnd", e.REDIRECT_START = "redirectStart", e.REQUEST_START = "requestStart", e.RESPONSE_END = "responseEnd", e.RESPONSE_START = "responseStart", e.SECURE_CONNECTION_START = "secureConnectionStart", e.START_TIME = "startTime", e.UNLOAD_EVENT_END = "unloadEventEnd", e.UNLOAD_EVENT_START = "unloadEventStart";
|
|
3093
|
+
})(Z ||= {});
|
|
3094
|
+
//#endregion
|
|
3095
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-web@2.10.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace-web/build/esm/semconv.js
|
|
3096
|
+
var Xa = "http.response_content_length", Za = "http.response_content_length_uncompressed";
|
|
3097
|
+
//#endregion
|
|
3098
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+sdk-trace-web@2.10.0_@opentelemetry+api@1.9.1/node_modules/@opentelemetry/sdk-trace-web/build/esm/utils.js
|
|
3099
|
+
function Q(e, t) {
|
|
3100
|
+
return t in e;
|
|
3101
|
+
}
|
|
3102
|
+
function $(e, t, n, r = !0) {
|
|
3103
|
+
if (Q(n, t) && typeof n[t] == "number" && !(r && n[t] === 0)) return e.addEvent(t, n[t]);
|
|
3104
|
+
}
|
|
3105
|
+
function Qa(e, t, n = !1, r, i) {
|
|
3106
|
+
if (r === void 0 && (r = t[Z.START_TIME] !== 0), n || ($(e, Z.FETCH_START, t, r), $(e, Z.DOMAIN_LOOKUP_START, t, r), $(e, Z.DOMAIN_LOOKUP_END, t, r), $(e, Z.CONNECT_START, t, r), $(e, Z.SECURE_CONNECTION_START, t, r), $(e, Z.CONNECT_END, t, r), $(e, Z.REQUEST_START, t, r), $(e, Z.RESPONSE_START, t, r), $(e, Z.RESPONSE_END, t, r)), !i) {
|
|
3107
|
+
let n = t[Z.ENCODED_BODY_SIZE];
|
|
3108
|
+
n !== void 0 && e.setAttribute(Xa, n);
|
|
3109
|
+
let r = t[Z.DECODED_BODY_SIZE];
|
|
3110
|
+
r !== void 0 && n !== r && e.setAttribute(Za, r);
|
|
3089
3111
|
}
|
|
3090
|
-
}
|
|
3112
|
+
}
|
|
3113
|
+
//#endregion
|
|
3114
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-document-load@0.67.0_@opentelemetry+api@1.9.1_supports-color@10.2.2/node_modules/@opentelemetry/instrumentation-document-load/build/esm/enums/AttributeNames.js
|
|
3115
|
+
var $a;
|
|
3091
3116
|
(function(e) {
|
|
3092
3117
|
e.DOCUMENT_LOAD = "documentLoad", e.DOCUMENT_FETCH = "documentFetch", e.RESOURCE_FETCH = "resourceFetch";
|
|
3093
|
-
})($ ||= {});
|
|
3118
|
+
})($a ||= {});
|
|
3094
3119
|
//#endregion
|
|
3095
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-document-load@0.
|
|
3096
|
-
var
|
|
3120
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-document-load@0.67.0_@opentelemetry+api@1.9.1_supports-color@10.2.2/node_modules/@opentelemetry/instrumentation-document-load/build/esm/version.js
|
|
3121
|
+
var eo = "0.67.0", to = "@opentelemetry/instrumentation-document-load", no;
|
|
3097
3122
|
(function(e) {
|
|
3098
3123
|
e.FIRST_PAINT = "firstPaint", e.FIRST_CONTENTFUL_PAINT = "firstContentfulPaint";
|
|
3099
|
-
})(
|
|
3124
|
+
})(no ||= {});
|
|
3100
3125
|
//#endregion
|
|
3101
|
-
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-document-load@0.
|
|
3102
|
-
var
|
|
3103
|
-
let e = {}, t =
|
|
3104
|
-
if (t) Object.values(
|
|
3105
|
-
if (
|
|
3126
|
+
//#region ../../node_modules/.pnpm/@opentelemetry+instrumentation-document-load@0.67.0_@opentelemetry+api@1.9.1_supports-color@10.2.2/node_modules/@opentelemetry/instrumentation-document-load/build/esm/utils.js
|
|
3127
|
+
var ro = () => {
|
|
3128
|
+
let e = {}, t = Ja.getEntriesByType?.("navigation")[0];
|
|
3129
|
+
if (t) Object.values(Z).forEach((n) => {
|
|
3130
|
+
if (Q(t, n)) {
|
|
3106
3131
|
let r = t[n];
|
|
3107
3132
|
typeof r == "number" && (e[n] = r);
|
|
3108
3133
|
}
|
|
3109
3134
|
});
|
|
3110
3135
|
else {
|
|
3111
|
-
let t =
|
|
3112
|
-
t && Object.values(
|
|
3113
|
-
if (
|
|
3136
|
+
let t = Ja.timing;
|
|
3137
|
+
t && Object.values(Z).forEach((n) => {
|
|
3138
|
+
if (Q(t, n)) {
|
|
3114
3139
|
let r = t[n];
|
|
3115
3140
|
typeof r == "number" && (e[n] = r);
|
|
3116
3141
|
}
|
|
3117
3142
|
});
|
|
3118
3143
|
}
|
|
3119
3144
|
return e;
|
|
3120
|
-
},
|
|
3121
|
-
"first-paint":
|
|
3122
|
-
"first-contentful-paint":
|
|
3123
|
-
},
|
|
3124
|
-
let t =
|
|
3145
|
+
}, io = {
|
|
3146
|
+
"first-paint": no.FIRST_PAINT,
|
|
3147
|
+
"first-contentful-paint": no.FIRST_CONTENTFUL_PAINT
|
|
3148
|
+
}, ao = (e) => {
|
|
3149
|
+
let t = Ja.getEntriesByType?.("paint");
|
|
3125
3150
|
t && t.forEach(({ name: t, startTime: n }) => {
|
|
3126
|
-
|
|
3151
|
+
Q(io, t) && e.addEvent(io[t], n);
|
|
3127
3152
|
});
|
|
3128
|
-
},
|
|
3153
|
+
}, oo = class extends Oa {
|
|
3129
3154
|
component = "document-load";
|
|
3130
3155
|
version = "1";
|
|
3131
3156
|
moduleName = this.component;
|
|
3132
3157
|
constructor(e = {}) {
|
|
3133
|
-
super(
|
|
3158
|
+
super(to, eo, e);
|
|
3134
3159
|
}
|
|
3135
3160
|
init() {}
|
|
3136
3161
|
_onDocumentLoaded() {
|
|
@@ -3139,43 +3164,43 @@ var Ya = () => {
|
|
|
3139
3164
|
});
|
|
3140
3165
|
}
|
|
3141
3166
|
_addResourcesSpans(e) {
|
|
3142
|
-
let t =
|
|
3167
|
+
let t = Ja.getEntriesByType?.("resource");
|
|
3143
3168
|
t && t.forEach((t) => {
|
|
3144
3169
|
this._initResourceSpan(t, e);
|
|
3145
3170
|
});
|
|
3146
3171
|
}
|
|
3147
3172
|
_collectPerformance() {
|
|
3148
|
-
let e = Array.from(document.getElementsByTagName("meta")).find((e) => e.getAttribute("name") ===
|
|
3149
|
-
|
|
3150
|
-
let e = this._startSpan(
|
|
3151
|
-
e && (
|
|
3152
|
-
let e = this._startSpan(
|
|
3153
|
-
e && (e.setAttribute(c, location.href),
|
|
3154
|
-
|
|
3173
|
+
let e = Array.from(document.getElementsByTagName("meta")).find((e) => e.getAttribute("name") === Ya), t = ro(), n = e && e.content || "";
|
|
3174
|
+
w.with(E.extract(b, { traceparent: n }), () => {
|
|
3175
|
+
let e = this._startSpan($a.DOCUMENT_LOAD, Z.FETCH_START, t);
|
|
3176
|
+
e && (w.with(D.setSpan(w.active(), e), () => {
|
|
3177
|
+
let e = this._startSpan($a.DOCUMENT_FETCH, Z.FETCH_START, t);
|
|
3178
|
+
e && (e.setAttribute(c, location.href), w.with(D.setSpan(w.active(), e), () => {
|
|
3179
|
+
Qa(e, t, this.getConfig().ignoreNetworkEvents), this._addCustomAttributesOnSpan(e, this.getConfig().applyCustomAttributesOnSpan?.documentFetch), this._endSpan(e, Z.RESPONSE_END, t);
|
|
3155
3180
|
}));
|
|
3156
|
-
}), e.setAttribute(c, location.href), e.setAttribute("user_agent.original", navigator.userAgent), this._addResourcesSpans(e), this.getConfig().ignoreNetworkEvents || (
|
|
3181
|
+
}), e.setAttribute(c, location.href), e.setAttribute("user_agent.original", navigator.userAgent), this._addResourcesSpans(e), this.getConfig().ignoreNetworkEvents || ($(e, Z.FETCH_START, t), $(e, Z.UNLOAD_EVENT_START, t), $(e, Z.UNLOAD_EVENT_END, t), $(e, Z.DOM_INTERACTIVE, t), $(e, Z.DOM_CONTENT_LOADED_EVENT_START, t), $(e, Z.DOM_CONTENT_LOADED_EVENT_END, t), $(e, Z.DOM_COMPLETE, t), $(e, Z.LOAD_EVENT_START, t), $(e, Z.LOAD_EVENT_END, t)), this.getConfig().ignorePerformancePaintEvents || ao(e), this._addCustomAttributesOnSpan(e, this.getConfig().applyCustomAttributesOnSpan?.documentLoad), this._endSpan(e, Z.LOAD_EVENT_END, t));
|
|
3157
3182
|
});
|
|
3158
3183
|
}
|
|
3159
3184
|
_endSpan(e, t, n) {
|
|
3160
|
-
e && (
|
|
3185
|
+
e && (Q(n, t) ? e.end(n[t]) : e.end());
|
|
3161
3186
|
}
|
|
3162
3187
|
_initResourceSpan(e, t) {
|
|
3163
|
-
let n = this._startSpan(
|
|
3164
|
-
n && (n.setAttribute(c, e.name),
|
|
3188
|
+
let n = this._startSpan($a.RESOURCE_FETCH, Z.FETCH_START, e, t);
|
|
3189
|
+
n && (n.setAttribute(c, e.name), Qa(n, e, this.getConfig().ignoreNetworkEvents), this._addCustomAttributesOnResourceSpan(n, e, this.getConfig().applyCustomAttributesOnSpan?.resourceFetch), this._endSpan(n, Z.RESPONSE_END, e));
|
|
3165
3190
|
}
|
|
3166
3191
|
_startSpan(e, t, n, r) {
|
|
3167
|
-
if (
|
|
3192
|
+
if (Q(n, t) && typeof n[t] == "number") return this.tracer.startSpan(e, { startTime: n[t] }, r ? D.setSpan(w.active(), r) : void 0);
|
|
3168
3193
|
}
|
|
3169
3194
|
_waitForPageLoad() {
|
|
3170
3195
|
window.document.readyState === "complete" ? this._onDocumentLoaded() : (this._onDocumentLoaded = this._onDocumentLoaded.bind(this), window.addEventListener("load", this._onDocumentLoaded));
|
|
3171
3196
|
}
|
|
3172
3197
|
_addCustomAttributesOnSpan(e, t) {
|
|
3173
|
-
t &&
|
|
3198
|
+
t && X(() => t(e), (e) => {
|
|
3174
3199
|
e && this._diag.error("addCustomAttributesOnSpan", e);
|
|
3175
3200
|
}, !0);
|
|
3176
3201
|
}
|
|
3177
3202
|
_addCustomAttributesOnResourceSpan(e, t, n) {
|
|
3178
|
-
n &&
|
|
3203
|
+
n && X(() => n(e, t), (e) => {
|
|
3179
3204
|
e && this._diag.error("addCustomAttributesOnResourceSpan", e);
|
|
3180
3205
|
}, !0);
|
|
3181
3206
|
}
|
|
@@ -3185,22 +3210,22 @@ var Ya = () => {
|
|
|
3185
3210
|
disable() {
|
|
3186
3211
|
window.removeEventListener("load", this._onDocumentLoaded);
|
|
3187
3212
|
}
|
|
3188
|
-
},
|
|
3213
|
+
}, so = {
|
|
3189
3214
|
development: 1,
|
|
3190
3215
|
staging: .5,
|
|
3191
3216
|
production: .2
|
|
3192
3217
|
};
|
|
3193
|
-
function
|
|
3218
|
+
function co(e) {
|
|
3194
3219
|
let t = typeof process < "u" ? process.env.OTEL_SAMPLING_RATE : void 0;
|
|
3195
3220
|
if (t !== void 0) {
|
|
3196
3221
|
let e = Number(t);
|
|
3197
3222
|
return Number.isFinite(e) ? Math.max(0, Math.min(1, e)) : 1;
|
|
3198
3223
|
}
|
|
3199
|
-
return
|
|
3224
|
+
return so[e.toLowerCase()] ?? 1;
|
|
3200
3225
|
}
|
|
3201
3226
|
//#endregion
|
|
3202
3227
|
//#region ../../packages/telemetry/src/utils.ts
|
|
3203
|
-
function
|
|
3228
|
+
function lo(e, t, n) {
|
|
3204
3229
|
return Promise.race([Promise.resolve(e).then(() => {}), new Promise((e) => {
|
|
3205
3230
|
setTimeout(() => {
|
|
3206
3231
|
console.warn(`[telemetry] ${n} timed out after ${t}ms — proceeding without confirmation`), e();
|
|
@@ -3209,57 +3234,57 @@ function to(e, t, n) {
|
|
|
3209
3234
|
}
|
|
3210
3235
|
//#endregion
|
|
3211
3236
|
//#region ../../packages/telemetry/src/browser.ts
|
|
3212
|
-
var
|
|
3213
|
-
function
|
|
3214
|
-
if (
|
|
3215
|
-
|
|
3237
|
+
var uo = !1;
|
|
3238
|
+
function fo(e) {
|
|
3239
|
+
if (uo) return;
|
|
3240
|
+
uo = !0;
|
|
3216
3241
|
let t = () => {
|
|
3217
|
-
|
|
3242
|
+
lo(e(), 2e3, "browser flush");
|
|
3218
3243
|
};
|
|
3219
3244
|
window.addEventListener("pagehide", t), window.addEventListener("beforeunload", t), document.addEventListener("visibilitychange", () => {
|
|
3220
3245
|
document.visibilityState === "hidden" && t();
|
|
3221
3246
|
});
|
|
3222
3247
|
}
|
|
3223
|
-
function
|
|
3248
|
+
function po(e) {
|
|
3224
3249
|
return e?.enabled === !1 ? null : {
|
|
3225
3250
|
serviceName: e?.serviceName ?? "frontend",
|
|
3226
3251
|
environment: e?.environment ?? "development",
|
|
3227
3252
|
exporterEndpoint: e?.exporterEndpoint ?? "http://localhost:4318",
|
|
3228
|
-
samplingRate:
|
|
3253
|
+
samplingRate: co(e?.environment ?? "development"),
|
|
3229
3254
|
otlpHeaders: e?.otlpHeaders ?? {},
|
|
3230
3255
|
signozApiKey: e?.signozApiKey ?? "",
|
|
3231
3256
|
logLevel: e?.logLevel ?? "info",
|
|
3232
3257
|
propagateCorsUrls: e?.propagateCorsUrls
|
|
3233
3258
|
};
|
|
3234
3259
|
}
|
|
3235
|
-
function
|
|
3236
|
-
let t =
|
|
3260
|
+
function mo(e) {
|
|
3261
|
+
let t = po(e);
|
|
3237
3262
|
if (!t) return {
|
|
3238
3263
|
shutdown: async () => {},
|
|
3239
3264
|
flush: async () => {}
|
|
3240
3265
|
};
|
|
3241
|
-
let n = new
|
|
3242
|
-
resource:
|
|
3266
|
+
let n = new Rr({
|
|
3267
|
+
resource: Vn({
|
|
3243
3268
|
[r]: t.serviceName,
|
|
3244
3269
|
"deployment.environment": t.environment,
|
|
3245
3270
|
"service.version": "0.0.0"
|
|
3246
3271
|
}),
|
|
3247
|
-
spanProcessors: [new
|
|
3272
|
+
spanProcessors: [new Pr(new Sa({
|
|
3248
3273
|
url: `${t.exporterEndpoint}/v1/traces`,
|
|
3249
3274
|
headers: t.otlpHeaders
|
|
3250
3275
|
}))]
|
|
3251
3276
|
});
|
|
3252
|
-
return n.register(),
|
|
3277
|
+
return n.register(), E.setGlobalPropagator(new un()), new qa({ propagateTraceHeaderCorsUrls: t.propagateCorsUrls ? [t.propagateCorsUrls] : [] }).enable(), new oo().enable(), fo(() => n.forceFlush()), {
|
|
3253
3278
|
shutdown: async () => {
|
|
3254
3279
|
try {
|
|
3255
|
-
await
|
|
3280
|
+
await lo(n.shutdown(), 1e4, "browser shutdown");
|
|
3256
3281
|
} catch (e) {
|
|
3257
3282
|
console.error("[telemetry-browser] Error during shutdown", e);
|
|
3258
3283
|
}
|
|
3259
3284
|
},
|
|
3260
3285
|
flush: async () => {
|
|
3261
3286
|
try {
|
|
3262
|
-
await
|
|
3287
|
+
await lo(n.forceFlush(), 1e4, "browser flush");
|
|
3263
3288
|
} catch (e) {
|
|
3264
3289
|
console.error("[telemetry-browser] Error during flush", e);
|
|
3265
3290
|
}
|
|
@@ -3267,6 +3292,6 @@ function ao(e) {
|
|
|
3267
3292
|
};
|
|
3268
3293
|
}
|
|
3269
3294
|
//#endregion
|
|
3270
|
-
export {
|
|
3295
|
+
export { mo as initializeTelemetryBrowser };
|
|
3271
3296
|
|
|
3272
|
-
//# sourceMappingURL=browser-
|
|
3297
|
+
//# sourceMappingURL=browser-BXy4OnXA.js.map
|