@utk09/ui-observability 0.11.0 → 0.12.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +61 -0
- package/README.md +273 -102
- package/bin/uiobs.mjs +1 -1
- package/dist/{batch-CL9uWYY3.js → batch-BjQUwjA6.js} +4 -4
- package/dist/batch-BjQUwjA6.js.map +1 -0
- package/dist/{batch-C8OcWR2L.cjs → batch-D5LlU4Q9.cjs} +2 -2
- package/dist/batch-D5LlU4Q9.cjs.map +1 -0
- package/dist/bus/bus.d.ts +48 -47
- package/dist/bus/links.d.ts +4 -4
- package/dist/bus/validation.d.ts +1 -1
- package/dist/bus-D_7pd7RN.cjs +2 -0
- package/dist/bus-D_7pd7RN.cjs.map +1 -0
- package/dist/{bus-BZ0GldpT.js → bus-ecxUNTja.js} +91 -91
- package/dist/bus-ecxUNTja.js.map +1 -0
- package/dist/capture/console.d.ts +10 -10
- package/dist/capture/errors.d.ts +6 -6
- package/dist/capture/interactions.d.ts +14 -14
- package/dist/capture/lifecycle.d.ts +3 -3
- package/dist/capture/long-frames.d.ts +6 -6
- package/dist/capture/network.d.ts +17 -17
- package/dist/capture/profiler-frames.d.ts +44 -0
- package/dist/capture/replay-buffer.d.ts +46 -0
- package/dist/capture/replay-upload.d.ts +74 -0
- package/dist/capture/replay.d.ts +114 -0
- package/dist/capture/reports.d.ts +2 -2
- package/dist/capture/resource-timing.d.ts +1 -1
- package/dist/capture/server-timing.d.ts +3 -3
- package/dist/capture/storm.d.ts +3 -3
- package/dist/capture/types.d.ts +45 -33
- package/dist/capture/unclean-exit.d.ts +8 -8
- package/dist/capture/user-timing.d.ts +3 -3
- package/dist/capture/web-socket.d.ts +11 -11
- package/dist/capture/web-vitals.d.ts +20 -7
- package/dist/compression-AJJCMBOa.js +11 -0
- package/dist/compression-AJJCMBOa.js.map +1 -0
- package/dist/compression-lD9abCcO.cjs +2 -0
- package/dist/compression-lD9abCcO.cjs.map +1 -0
- package/dist/{console-BPZCuSLc.cjs → console-CLz_PvFn.cjs} +2 -2
- package/dist/console-CLz_PvFn.cjs.map +1 -0
- package/dist/{console-BeCF7n59.js → console-cwgHKXvM.js} +4 -4
- package/dist/console-cwgHKXvM.js.map +1 -0
- package/dist/constants-Bwl_YtQi.js +349 -0
- package/dist/constants-Bwl_YtQi.js.map +1 -0
- package/dist/constants-DakMxVB2.cjs +2 -0
- package/dist/constants-DakMxVB2.cjs.map +1 -0
- package/dist/constants.d.ts +150 -103
- package/dist/context-storage-BjzeBSxH.cjs.map +1 -1
- package/dist/context-storage-BzkoHzkQ.js.map +1 -1
- package/dist/core/breadcrumbs.d.ts +16 -15
- package/dist/core/config.d.ts +3 -3
- package/dist/core/context.d.ts +7 -7
- package/dist/core/debug-buffer.d.ts +10 -10
- package/dist/core/debug-bundle.d.ts +3 -3
- package/dist/core/deferred.d.ts +2 -2
- package/dist/core/diagnostics.d.ts +24 -21
- package/dist/core/drops.d.ts +7 -7
- package/dist/core/hold-buffer.d.ts +1 -1
- package/dist/core/journey.d.ts +22 -23
- package/dist/core/logger.d.ts +22 -21
- package/dist/core/measure.d.ts +7 -7
- package/dist/core/meter.d.ts +25 -21
- package/dist/core/pipeline.d.ts +42 -41
- package/dist/core/profile-buckets.d.ts +31 -0
- package/dist/core/profiler.d.ts +218 -0
- package/dist/core/record.d.ts +23 -23
- package/dist/core/remote-rules.d.ts +4 -4
- package/dist/core/remote-sampling.d.ts +21 -20
- package/dist/core/runtime.d.ts +206 -137
- package/dist/core/sampling.d.ts +18 -18
- package/dist/core/sender.d.ts +22 -20
- package/dist/core/spans.d.ts +5 -5
- package/dist/{deadline-BOjOxNHj.js → deadline-C4ccAuk5.js} +3 -6
- package/dist/deadline-C4ccAuk5.js.map +1 -0
- package/dist/deadline-CUGbto-y.cjs +2 -0
- package/dist/deadline-CUGbto-y.cjs.map +1 -0
- package/dist/{debug-bundle-C7UkHZ-q.js → debug-bundle-BOdYmCeV.js} +10 -3
- package/dist/debug-bundle-BOdYmCeV.js.map +1 -0
- package/dist/debug-bundle-Ex4L_LSP.cjs +2 -0
- package/dist/debug-bundle-Ex4L_LSP.cjs.map +1 -0
- package/dist/doctor.cjs +1 -1
- package/dist/doctor.cjs.map +1 -1
- package/dist/doctor.d.ts +16 -6
- package/dist/doctor.js +147 -52
- package/dist/doctor.js.map +1 -1
- package/dist/{emergency-queue-Zy6lNafo.js → emergency-queue-B9WZxanZ.js} +4 -4
- package/dist/emergency-queue-B9WZxanZ.js.map +1 -0
- package/dist/{emergency-queue-CNTRui5t.cjs → emergency-queue-HBpL5r3V.cjs} +2 -2
- package/dist/emergency-queue-HBpL5r3V.cjs.map +1 -0
- package/dist/error-like-B11pB4aL.js.map +1 -1
- package/dist/error-like-gGRx2s36.cjs.map +1 -1
- package/dist/{errors-Dh7kef0i.js → errors-D6bwgJtO.js} +3 -3
- package/dist/errors-D6bwgJtO.js.map +1 -0
- package/dist/{errors-tfEr48bS.cjs → errors-DCOCRdSi.cjs} +2 -2
- package/dist/errors-DCOCRdSi.cjs.map +1 -0
- package/dist/{factory-CJXVYp0R.cjs → factory-DLFDjdLv.cjs} +2 -2
- package/dist/factory-DLFDjdLv.cjs.map +1 -0
- package/dist/{factory-BonqI3NL.js → factory-e9Qo3K0z.js} +13 -13
- package/dist/factory-e9Qo3K0z.js.map +1 -0
- package/dist/fixed-window-CvESpFYV.cjs.map +1 -1
- package/dist/fixed-window-Dq3MLUUv.js.map +1 -1
- package/dist/global-scope-BN-Io_yv.cjs.map +1 -1
- package/dist/global-scope-D9I8s-oN.js.map +1 -1
- package/dist/guards-Cidk71ME.js.map +1 -1
- package/dist/guards-nJ70syPt.cjs.map +1 -1
- package/dist/{identity-Cxgj6pZX.cjs → identity-BlvlgjrU.cjs} +2 -2
- package/dist/identity-BlvlgjrU.cjs.map +1 -0
- package/dist/{identity-DT5VmvXy.js → identity-BrQp_5J5.js} +19 -19
- package/dist/identity-BrQp_5J5.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.ts +112 -79
- package/dist/index.js +783 -635
- package/dist/index.js.map +1 -1
- package/dist/{indexeddb-storage-CIoW21Xd.cjs → indexeddb-storage-CtLvZH1r.cjs} +2 -2
- package/dist/indexeddb-storage-CtLvZH1r.cjs.map +1 -0
- package/dist/{indexeddb-storage-BJVtiQKm.js → indexeddb-storage-DLXQzAGh.js} +4 -4
- package/dist/indexeddb-storage-DLXQzAGh.js.map +1 -0
- package/dist/{interactions-DTgKy_6K.js → interactions-B6z2I4tU.js} +3 -3
- package/dist/interactions-B6z2I4tU.js.map +1 -0
- package/dist/{interactions-fEN6FbVo.cjs → interactions-P6pz08Jn.cjs} +2 -2
- package/dist/interactions-P6pz08Jn.cjs.map +1 -0
- package/dist/{journey-CuJrHzEg.js → journey-35yCMNFo.js} +20 -19
- package/dist/journey-35yCMNFo.js.map +1 -0
- package/dist/journey-DAGh5h9k.cjs +2 -0
- package/dist/journey-DAGh5h9k.cjs.map +1 -0
- package/dist/keys-BHhw_0Wh.cjs.map +1 -1
- package/dist/keys-BU9j5YqW.js.map +1 -1
- package/dist/{library-console-D2GY9Or6.cjs → library-console-BFWEuQsl.cjs} +2 -2
- package/dist/library-console-BFWEuQsl.cjs.map +1 -0
- package/dist/{library-console-C1m6g1BR.js → library-console-Dl_Ly6DQ.js} +2 -2
- package/dist/library-console-Dl_Ly6DQ.js.map +1 -0
- package/dist/{library-request-1BX_UlaX.cjs → library-request-Da-CHKzT.cjs} +2 -2
- package/dist/library-request-Da-CHKzT.cjs.map +1 -0
- package/dist/{library-request-BQBT9N9Q.js → library-request-nI6pvI6I.js} +2 -2
- package/dist/library-request-nI6pvI6I.js.map +1 -0
- package/dist/{lifecycle-2EtUaRpo.cjs → lifecycle-BGGOcN4N.cjs} +2 -2
- package/dist/lifecycle-BGGOcN4N.cjs.map +1 -0
- package/dist/{lifecycle-BaKx_-32.js → lifecycle-CZ6RRXc6.js} +2 -2
- package/dist/lifecycle-CZ6RRXc6.js.map +1 -0
- package/dist/{log-record-i9zOTkpQ.cjs → log-record-D7bA1RPb.cjs} +2 -2
- package/dist/log-record-D7bA1RPb.cjs.map +1 -0
- package/dist/{log-record-CAoGBBf3.js → log-record-DIA6McNr.js} +2 -2
- package/dist/log-record-DIA6McNr.js.map +1 -0
- package/dist/{long-frames-Czk7IupC.js → long-frames-430_85Da.js} +8 -6
- package/dist/long-frames-430_85Da.js.map +1 -0
- package/dist/long-frames-Dd8tsi2U.cjs +2 -0
- package/dist/long-frames-Dd8tsi2U.cjs.map +1 -0
- package/dist/models/batch.d.ts +14 -15
- package/dist/models/bus.d.ts +24 -24
- package/dist/models/config.d.ts +402 -216
- package/dist/models/drop.d.ts +13 -11
- package/dist/models/health.d.ts +13 -13
- package/dist/models/log-record.d.ts +13 -14
- package/dist/models/metric.d.ts +82 -17
- package/dist/models/plugin.d.ts +13 -13
- package/dist/models/replay.d.ts +60 -0
- package/dist/models/serializer.d.ts +2 -3
- package/dist/models/stats.d.ts +2 -2
- package/dist/models/storage.d.ts +12 -11
- package/dist/{network-DBNwApoF.js → network-C7SkLf4v.js} +12 -12
- package/dist/network-C7SkLf4v.js.map +1 -0
- package/dist/{network-xbbuvG_6.cjs → network-pEX3PAJv.cjs} +2 -2
- package/dist/network-pEX3PAJv.cjs.map +1 -0
- package/dist/openfin-Bxelt0yg.js.map +1 -1
- package/dist/openfin-DtH2f7zX.cjs.map +1 -1
- package/dist/otlp-2MCrC3kd.cjs +2 -0
- package/dist/otlp-2MCrC3kd.cjs.map +1 -0
- package/dist/{otlp-BTJdIa6F.js → otlp-COq033e3.js} +25 -32
- package/dist/otlp-COq033e3.js.map +1 -0
- package/dist/patch-BX8KrPCT.cjs.map +1 -1
- package/dist/patch-UdPz1ea8.js.map +1 -1
- package/dist/{platform-C2Ez5kDc.cjs → platform-12uR7kBQ.cjs} +2 -2
- package/dist/platform-12uR7kBQ.cjs.map +1 -0
- package/dist/{platform-DkcuXwe-.js → platform-CVewe4wQ.js} +7 -7
- package/dist/platform-CVewe4wQ.js.map +1 -0
- package/dist/profiler-BVWIOgnq.js +310 -0
- package/dist/profiler-BVWIOgnq.js.map +1 -0
- package/dist/profiler-eVCknCzS.cjs +2 -0
- package/dist/profiler-eVCknCzS.cjs.map +1 -0
- package/dist/profiler-frames-CLXlT_xL.js +86 -0
- package/dist/profiler-frames-CLXlT_xL.js.map +1 -0
- package/dist/profiler-frames-Dg2OebB2.cjs +2 -0
- package/dist/profiler-frames-Dg2OebB2.cjs.map +1 -0
- package/dist/{remote-rules-Cfb4K-Nl.js → remote-rules-BJGDJGwA.js} +27 -27
- package/dist/remote-rules-BJGDJGwA.js.map +1 -0
- package/dist/{remote-rules-vzvk7aKf.cjs → remote-rules-CJD3ToVk.cjs} +2 -2
- package/dist/remote-rules-CJD3ToVk.cjs.map +1 -0
- package/dist/replay-0zAJv9T3.js +338 -0
- package/dist/replay-0zAJv9T3.js.map +1 -0
- package/dist/replay-DomJpXqW.cjs +2 -0
- package/dist/replay-DomJpXqW.cjs.map +1 -0
- package/dist/{reports-Dk2YhKIh.cjs → reports-BsbqmP8h.cjs} +2 -2
- package/dist/reports-BsbqmP8h.cjs.map +1 -0
- package/dist/{reports-TA-zInnq.js → reports-BuXekPOS.js} +3 -3
- package/dist/reports-BuXekPOS.js.map +1 -0
- package/dist/{resource-timing-BLv3EA2A.js → resource-timing-CXGHwFRD.js} +4 -4
- package/dist/resource-timing-CXGHwFRD.js.map +1 -0
- package/dist/{resource-timing-Cysw1S1f.cjs → resource-timing-DkycFGDa.cjs} +2 -2
- package/dist/resource-timing-DkycFGDa.cjs.map +1 -0
- package/dist/{sampling-Ckh2yW9k.cjs → sampling-Dd0wllyq.cjs} +2 -2
- package/dist/sampling-Dd0wllyq.cjs.map +1 -0
- package/dist/{sampling-C4VV-1MS.js → sampling-UUDbi3K0.js} +9 -9
- package/dist/sampling-UUDbi3K0.js.map +1 -0
- package/dist/{sanitize-6ymPlVvP.js → sanitize-CNmsD9r3.js} +2 -2
- package/dist/sanitize-CNmsD9r3.js.map +1 -0
- package/dist/{sanitize-BAWzkZt0.cjs → sanitize-ChLn97Ch.cjs} +2 -2
- package/dist/sanitize-ChLn97Ch.cjs.map +1 -0
- package/dist/{select-ZF4by-lF.cjs → select-CTk-K5mG.cjs} +3 -3
- package/dist/select-CTk-K5mG.cjs.map +1 -0
- package/dist/{select-xtQaenIi.js → select-DPv_j6wq.js} +61 -61
- package/dist/select-DPv_j6wq.js.map +1 -0
- package/dist/{sender-CiMHC9YG.js → sender-15zEsZpr.js} +61 -60
- package/dist/sender-15zEsZpr.js.map +1 -0
- package/dist/sender-Bfpv9tad.cjs +2 -0
- package/dist/sender-Bfpv9tad.cjs.map +1 -0
- package/dist/storage/context-storage.d.ts +34 -33
- package/dist/storage/emergency-queue.d.ts +9 -9
- package/dist/storage/eviction.d.ts +12 -12
- package/dist/storage/factory.d.ts +8 -7
- package/dist/storage/gap.d.ts +6 -6
- package/dist/storage/idb-driver.d.ts +31 -32
- package/dist/storage/indexeddb-storage.d.ts +26 -27
- package/dist/storage/keys.d.ts +7 -7
- package/dist/storage/local-storage.d.ts +38 -38
- package/dist/storage/memory-storage.d.ts +21 -22
- package/dist/storage/persistence.d.ts +1 -1
- package/dist/storage-BA9RqRO-.cjs.map +1 -1
- package/dist/storage-DZwed89z.js.map +1 -1
- package/dist/{storm-VR024_QN.js → storm-BTSNTIWI.js} +2 -2
- package/dist/storm-BTSNTIWI.js.map +1 -0
- package/dist/{storm-CYi9Swpx.cjs → storm-D0_qZOEg.cjs} +2 -2
- package/dist/storm-D0_qZOEg.cjs.map +1 -0
- package/dist/transport/compression.d.ts +2 -2
- package/dist/transport/errors.d.ts +7 -7
- package/dist/transport/exit-flush.d.ts +39 -39
- package/dist/transport/headers.d.ts +2 -2
- package/dist/transport/http-transport.d.ts +28 -27
- package/dist/transport/memory-transport.d.ts +6 -6
- package/dist/transport/retry-engine.d.ts +35 -34
- package/dist/transport/serializers/ecs.d.ts +1 -1
- package/dist/transport/serializers/otlp-metrics.d.ts +1 -1
- package/dist/transport/serializers/otlp-traces.d.ts +1 -1
- package/dist/transport/serializers/otlp.d.ts +16 -16
- package/dist/transport/serializers/select.d.ts +7 -7
- package/dist/transport/status-transport.d.ts +20 -20
- package/dist/transport/worker-protocol.d.ts +3 -3
- package/dist/types-BAerHgCq.js.map +1 -1
- package/dist/types-C7WNpnG1.cjs.map +1 -1
- package/dist/{unclean-exit-DFUN57wY.cjs → unclean-exit-ClGzrc2A.cjs} +2 -2
- package/dist/unclean-exit-ClGzrc2A.cjs.map +1 -0
- package/dist/{unclean-exit-CwcUhFOn.js → unclean-exit-Cob_jyTv.js} +2 -2
- package/dist/unclean-exit-Cob_jyTv.js.map +1 -0
- package/dist/unref-CU9Nyz_9.cjs +2 -0
- package/dist/unref-CU9Nyz_9.cjs.map +1 -0
- package/dist/unref-DgHPQeWv.js +7 -0
- package/dist/unref-DgHPQeWv.js.map +1 -0
- package/dist/user-timing-CdYqx3PF.cjs +2 -0
- package/dist/user-timing-CdYqx3PF.cjs.map +1 -0
- package/dist/{user-timing-_jZIhDKI.js → user-timing-DgHubxCI.js} +5 -3
- package/dist/user-timing-DgHubxCI.js.map +1 -0
- package/dist/utils/console.d.ts +2 -2
- package/dist/utils/deadline.d.ts +4 -4
- package/dist/utils/error-like.d.ts +7 -7
- package/dist/utils/fixed-window.d.ts +9 -8
- package/dist/utils/global-scope.d.ts +8 -8
- package/dist/utils/guards.d.ts +2 -2
- package/dist/utils/identity.d.ts +17 -17
- package/dist/utils/library-console.d.ts +4 -4
- package/dist/utils/library-request.d.ts +10 -10
- package/dist/utils/lock.d.ts +10 -9
- package/dist/utils/openfin.d.ts +5 -5
- package/dist/utils/patch.d.ts +6 -6
- package/dist/utils/platform.d.ts +13 -11
- package/dist/utils/sanitize.d.ts +4 -4
- package/dist/utils/timer.d.ts +1 -1
- package/dist/utils/tracing.d.ts +38 -38
- package/dist/utils/unref.d.ts +3 -3
- package/dist/{web-socket-BWUoqBh8.cjs → web-socket-BTuvYoJI.cjs} +2 -2
- package/dist/web-socket-BTuvYoJI.cjs.map +1 -0
- package/dist/{web-socket-CV7yIMnm.js → web-socket-DthJuSAg.js} +4 -4
- package/dist/web-socket-DthJuSAg.js.map +1 -0
- package/dist/web-vitals-Ch5BpDmo.cjs +2 -0
- package/dist/web-vitals-Ch5BpDmo.cjs.map +1 -0
- package/dist/web-vitals-CsGCWnUr.js +77 -0
- package/dist/web-vitals-CsGCWnUr.js.map +1 -0
- package/dist/{worker-protocol-CrsdSDLn.js → worker-protocol-B0_8rWy5.js} +4 -4
- package/dist/worker-protocol-B0_8rWy5.js.map +1 -0
- package/dist/{worker-protocol-Bai7GAIA.cjs → worker-protocol-BjzFORfq.cjs} +2 -2
- package/dist/worker-protocol-BjzFORfq.cjs.map +1 -0
- package/dist/worker-server-4en-Lt-3.cjs +2 -0
- package/dist/worker-server-4en-Lt-3.cjs.map +1 -0
- package/dist/{worker-server-Dp5HYm4b.js → worker-server-Cne9MX9I.js} +8 -8
- package/dist/{worker-server-Dp5HYm4b.js.map → worker-server-Cne9MX9I.js.map} +1 -1
- package/dist/worker-transport-B-GF4Aqn.cjs +2 -0
- package/dist/worker-transport-B-GF4Aqn.cjs.map +1 -0
- package/dist/{worker-transport-D6jtgpqN.js → worker-transport-C3SjJAEC.js} +62 -61
- package/dist/worker-transport-C3SjJAEC.js.map +1 -0
- package/package.json +8 -2
- package/dist/batch-C8OcWR2L.cjs.map +0 -1
- package/dist/batch-CL9uWYY3.js.map +0 -1
- package/dist/bus-BZ0GldpT.js.map +0 -1
- package/dist/bus-VWlmM5xs.cjs +0 -2
- package/dist/bus-VWlmM5xs.cjs.map +0 -1
- package/dist/console-BPZCuSLc.cjs.map +0 -1
- package/dist/console-BeCF7n59.js.map +0 -1
- package/dist/constants-DqKJH_MP.cjs +0 -2
- package/dist/constants-DqKJH_MP.cjs.map +0 -1
- package/dist/constants-zyrqveN4.js +0 -304
- package/dist/constants-zyrqveN4.js.map +0 -1
- package/dist/deadline-BOjOxNHj.js.map +0 -1
- package/dist/deadline-XSnm95pg.cjs +0 -2
- package/dist/deadline-XSnm95pg.cjs.map +0 -1
- package/dist/debug-bundle-BzJNpbF0.cjs +0 -2
- package/dist/debug-bundle-BzJNpbF0.cjs.map +0 -1
- package/dist/debug-bundle-C7UkHZ-q.js.map +0 -1
- package/dist/emergency-queue-CNTRui5t.cjs.map +0 -1
- package/dist/emergency-queue-Zy6lNafo.js.map +0 -1
- package/dist/errors-Dh7kef0i.js.map +0 -1
- package/dist/errors-tfEr48bS.cjs.map +0 -1
- package/dist/factory-BonqI3NL.js.map +0 -1
- package/dist/factory-CJXVYp0R.cjs.map +0 -1
- package/dist/identity-Cxgj6pZX.cjs.map +0 -1
- package/dist/identity-DT5VmvXy.js.map +0 -1
- package/dist/indexeddb-storage-BJVtiQKm.js.map +0 -1
- package/dist/indexeddb-storage-CIoW21Xd.cjs.map +0 -1
- package/dist/interactions-DTgKy_6K.js.map +0 -1
- package/dist/interactions-fEN6FbVo.cjs.map +0 -1
- package/dist/journey-CuJrHzEg.js.map +0 -1
- package/dist/journey-pffMVMfa.cjs +0 -2
- package/dist/journey-pffMVMfa.cjs.map +0 -1
- package/dist/library-console-C1m6g1BR.js.map +0 -1
- package/dist/library-console-D2GY9Or6.cjs.map +0 -1
- package/dist/library-request-1BX_UlaX.cjs.map +0 -1
- package/dist/library-request-BQBT9N9Q.js.map +0 -1
- package/dist/lifecycle-2EtUaRpo.cjs.map +0 -1
- package/dist/lifecycle-BaKx_-32.js.map +0 -1
- package/dist/log-record-CAoGBBf3.js.map +0 -1
- package/dist/log-record-i9zOTkpQ.cjs.map +0 -1
- package/dist/long-frames-BVg4i5SC.cjs +0 -2
- package/dist/long-frames-BVg4i5SC.cjs.map +0 -1
- package/dist/long-frames-Czk7IupC.js.map +0 -1
- package/dist/network-DBNwApoF.js.map +0 -1
- package/dist/network-xbbuvG_6.cjs.map +0 -1
- package/dist/otlp-BDvFrLnc.cjs +0 -2
- package/dist/otlp-BDvFrLnc.cjs.map +0 -1
- package/dist/otlp-BTJdIa6F.js.map +0 -1
- package/dist/platform-C2Ez5kDc.cjs.map +0 -1
- package/dist/platform-DkcuXwe-.js.map +0 -1
- package/dist/remote-rules-Cfb4K-Nl.js.map +0 -1
- package/dist/remote-rules-vzvk7aKf.cjs.map +0 -1
- package/dist/reports-Dk2YhKIh.cjs.map +0 -1
- package/dist/reports-TA-zInnq.js.map +0 -1
- package/dist/resource-timing-BLv3EA2A.js.map +0 -1
- package/dist/resource-timing-Cysw1S1f.cjs.map +0 -1
- package/dist/sampling-C4VV-1MS.js.map +0 -1
- package/dist/sampling-Ckh2yW9k.cjs.map +0 -1
- package/dist/sanitize-6ymPlVvP.js.map +0 -1
- package/dist/sanitize-BAWzkZt0.cjs.map +0 -1
- package/dist/select-ZF4by-lF.cjs.map +0 -1
- package/dist/select-xtQaenIi.js.map +0 -1
- package/dist/sender-CiMHC9YG.js.map +0 -1
- package/dist/sender-D5wBoXA8.cjs +0 -2
- package/dist/sender-D5wBoXA8.cjs.map +0 -1
- package/dist/storm-CYi9Swpx.cjs.map +0 -1
- package/dist/storm-VR024_QN.js.map +0 -1
- package/dist/unclean-exit-CwcUhFOn.js.map +0 -1
- package/dist/unclean-exit-DFUN57wY.cjs.map +0 -1
- package/dist/user-timing-C9kfRq3J.cjs +0 -2
- package/dist/user-timing-C9kfRq3J.cjs.map +0 -1
- package/dist/user-timing-_jZIhDKI.js.map +0 -1
- package/dist/web-socket-BWUoqBh8.cjs.map +0 -1
- package/dist/web-socket-CV7yIMnm.js.map +0 -1
- package/dist/web-vitals-Bq4WFHQo.js +0 -52
- package/dist/web-vitals-Bq4WFHQo.js.map +0 -1
- package/dist/web-vitals-DFuoTQbZ.cjs +0 -2
- package/dist/web-vitals-DFuoTQbZ.cjs.map +0 -1
- package/dist/worker-protocol-Bai7GAIA.cjs.map +0 -1
- package/dist/worker-protocol-CrsdSDLn.js.map +0 -1
- package/dist/worker-server-BrIYkfoa.cjs +0 -2
- package/dist/worker-server-BrIYkfoa.cjs.map +0 -1
- package/dist/worker-transport-Bwej4N2e.cjs +0 -2
- package/dist/worker-transport-Bwej4N2e.cjs.map +0 -1
- package/dist/worker-transport-D6jtgpqN.js.map +0 -1
package/dist/core/runtime.d.ts
CHANGED
|
@@ -18,49 +18,55 @@ import { JourneyEngine } from "./journey";
|
|
|
18
18
|
import { RecordBuilder } from "./record";
|
|
19
19
|
/** Manages subsystem lifecycles, bus coordination and record delivery. */
|
|
20
20
|
export declare class ObservabilityRuntime {
|
|
21
|
-
/** True while the
|
|
21
|
+
/** True while the security context is changing. */
|
|
22
22
|
private rotating;
|
|
23
|
-
/**
|
|
23
|
+
/**
|
|
24
|
+
* True while this runtime has the profiler core attached. Tracking it keeps configure() from
|
|
25
|
+
* restarting the sampling every time, and keeps a runtime with the profiler off from ever
|
|
26
|
+
* creating the core and its global symbol.
|
|
27
|
+
*/
|
|
28
|
+
private profilerOn;
|
|
29
|
+
/** True while the old context's last records are being collected. */
|
|
24
30
|
private closingContext;
|
|
25
31
|
/** Version of another SDK copy that owns the page runtime, or null. */
|
|
26
32
|
private mismatchVersion;
|
|
27
|
-
/** True if the configured context id differs from the owner context id. */
|
|
33
|
+
/** True if the configured context id differs from the owner's context id. */
|
|
28
34
|
private contextMismatch;
|
|
29
|
-
/**
|
|
35
|
+
/** The context change in progress. Shutdown waits for this promise. */
|
|
30
36
|
private rotation?;
|
|
31
37
|
/** Memory store kept for later context changes. */
|
|
32
38
|
private memoryStorage?;
|
|
33
|
-
/** State of the
|
|
39
|
+
/** State of the persistent storage request. getHealth() reports it. */
|
|
34
40
|
private storagePersistence;
|
|
35
|
-
/** True while a diagnostic record goes out.
|
|
41
|
+
/** True while a diagnostic record goes out. Diagnostics raised meanwhile produce no record. */
|
|
36
42
|
private recordingDiagnostic;
|
|
37
|
-
/** Logger
|
|
43
|
+
/** Logger for the records that diagnostics.records produces. */
|
|
38
44
|
private readonly diagnosticLogger;
|
|
39
|
-
/** Records that minLevel or sampling dropped. An error
|
|
45
|
+
/** Records that minLevel or sampling dropped. An error in this context sends them first. */
|
|
40
46
|
private readonly debugBuffer;
|
|
41
47
|
/** True if the app supplied a context id at startup. */
|
|
42
48
|
private explicitSecurityContext;
|
|
43
|
-
/** True
|
|
49
|
+
/** True once this forwarder has taken a context id from its owner. */
|
|
44
50
|
private ownerAdopted;
|
|
45
51
|
/**
|
|
46
|
-
* Checks
|
|
52
|
+
* Checks whether a security context change is in progress.
|
|
47
53
|
* @returns True until the current change completes.
|
|
48
54
|
*/
|
|
49
55
|
isRotating(): boolean;
|
|
50
56
|
/**
|
|
51
|
-
* Locks or unlocks configuration
|
|
52
|
-
*
|
|
57
|
+
* Locks or unlocks configuration when the app asks. Any other code on this origin can call
|
|
58
|
+
* this too, so the lock is not access control.
|
|
53
59
|
* @param locked True to refuse changes through configure().
|
|
54
60
|
*/
|
|
55
61
|
setConfigurationLocked(locked: boolean): void;
|
|
56
62
|
/**
|
|
57
|
-
*
|
|
63
|
+
* This copy's runtime when another version of the library owns the page runtime.
|
|
58
64
|
* It stays off the global key.
|
|
59
65
|
*/
|
|
60
66
|
private static local;
|
|
61
67
|
/**
|
|
62
|
-
*
|
|
63
|
-
*
|
|
68
|
+
* This runtime's library version. Another copy reads it from the global key, because two
|
|
69
|
+
* versions sharing one runtime would call methods the other version doesn't have.
|
|
64
70
|
*/
|
|
65
71
|
readonly sdkVersion: string;
|
|
66
72
|
/** Diagnostics reporter for internal faults. */
|
|
@@ -71,9 +77,9 @@ export declare class ObservabilityRuntime {
|
|
|
71
77
|
readonly platform: PlatformMetadata;
|
|
72
78
|
/** Identity context containing session, tab, and context identifiers. */
|
|
73
79
|
readonly identity: Identity;
|
|
74
|
-
/** Stores for identity and journey keys
|
|
80
|
+
/** Stores for identity and journey keys, set at startup. */
|
|
75
81
|
private readonly stores;
|
|
76
|
-
/**
|
|
82
|
+
/** The identity strategy the stores were built with. */
|
|
77
83
|
private readonly identityBuiltAs;
|
|
78
84
|
/** Throttled writer of the session's last-seen timestamp. */
|
|
79
85
|
private readonly sessionTouch;
|
|
@@ -89,14 +95,25 @@ export declare class ObservabilityRuntime {
|
|
|
89
95
|
readonly journey: JourneyEngine;
|
|
90
96
|
/** Record builder assembling structured log records. */
|
|
91
97
|
readonly builder: RecordBuilder;
|
|
92
|
-
/** Slot
|
|
98
|
+
/** Slot for the remote sampling rules. The sender or the bus fills it. */
|
|
93
99
|
private readonly remote;
|
|
94
|
-
/**
|
|
100
|
+
/** Number of delivery identity changes. A context's first id doesn't count as a change. */
|
|
95
101
|
private identityEpoch;
|
|
96
|
-
/**
|
|
102
|
+
/** Session replay's hook. It gets every ERROR and FATAL record. */
|
|
103
|
+
private errorHook;
|
|
104
|
+
/**
|
|
105
|
+
* True after startReplay(), false after stopReplay(), undefined until either is called. The
|
|
106
|
+
* app's last choice survives a reinstall of the capture modules.
|
|
107
|
+
*/
|
|
108
|
+
private replayConsent;
|
|
109
|
+
/** The installed session replay capture. */
|
|
110
|
+
private replay;
|
|
111
|
+
/** Timer that restores the local capture switches once the remote TTL ends. */
|
|
97
112
|
private remoteCaptureTimer;
|
|
98
113
|
/** Settings of the current capture load or install. */
|
|
99
114
|
private installedCaptureKey;
|
|
115
|
+
/** The replay settings the running replay capture was built with. */
|
|
116
|
+
private replayBuiltKey;
|
|
100
117
|
/** Console sink for local developer output. */
|
|
101
118
|
readonly console: ConsoleSink;
|
|
102
119
|
/** Collects lost records into onDrop summaries. */
|
|
@@ -104,60 +121,63 @@ export declare class ObservabilityRuntime {
|
|
|
104
121
|
/** Sums the values of the counter and histogram instruments. */
|
|
105
122
|
private readonly meter;
|
|
106
123
|
/**
|
|
107
|
-
* Cross-realm communication bus.
|
|
108
|
-
*
|
|
124
|
+
* Cross-realm communication bus. Null until its chunk loads. In bus.mode "off", it loads
|
|
125
|
+
* only when a child frame or a worker needs it.
|
|
109
126
|
*/
|
|
110
127
|
private bus;
|
|
111
|
-
/**
|
|
128
|
+
/** Promise for the bus load and construction. Undefined until first needed. */
|
|
112
129
|
private busBuilt?;
|
|
113
|
-
/**
|
|
130
|
+
/** Promise for the bus load and start. Undefined until first needed. */
|
|
114
131
|
private busLoad?;
|
|
115
|
-
/**
|
|
132
|
+
/** The adapter's storage strategy, set when the build starts. */
|
|
116
133
|
private storageBuiltAs?;
|
|
117
|
-
/**
|
|
134
|
+
/**
|
|
135
|
+
* Delivery stack. Set in the sender role with an endpoint or a custom transport, once the
|
|
136
|
+
* chunk has loaded.
|
|
137
|
+
*/
|
|
118
138
|
private sender?;
|
|
119
|
-
/**
|
|
139
|
+
/** The delivery stack load. Undefined when nothing loads, so records have no destination. */
|
|
120
140
|
private senderLoad?;
|
|
121
141
|
/** Records that arrive while the delivery stack loads. */
|
|
122
142
|
private readonly pendingRecords;
|
|
123
143
|
/** Active auto-capture instrumentation modules. */
|
|
124
144
|
private readonly captures;
|
|
125
|
-
/**
|
|
145
|
+
/** Number of capture installs. An install replaced by a later one stops after its load. */
|
|
126
146
|
private captureGeneration;
|
|
127
|
-
/** Capture work that
|
|
147
|
+
/** Capture work that rebuilding the capture modules must not repeat. */
|
|
128
148
|
private readonly captureOnce;
|
|
129
|
-
/**
|
|
149
|
+
/** Holds records created before the bus role is resolved. */
|
|
130
150
|
private readonly bootBuffer;
|
|
131
|
-
/**
|
|
151
|
+
/** Records staged for forwarding on the next microtask. */
|
|
132
152
|
private forwardBuffer;
|
|
133
153
|
/** True if a microtask drain of the forward buffer is pending. */
|
|
134
154
|
private forwardScheduled;
|
|
135
|
-
/** True
|
|
155
|
+
/** True once startup has decided the bus role. A sender load waits for it. */
|
|
136
156
|
private roleResolved;
|
|
137
|
-
/** Resolves when startup releases the boot records.
|
|
157
|
+
/** Resolves when startup releases the boot records. Set by init(), awaited by flush(). */
|
|
138
158
|
private started;
|
|
139
159
|
/** True if asynchronous initialization is complete. */
|
|
140
160
|
private ready;
|
|
141
161
|
/** True if shutdown stopped the runtime. */
|
|
142
162
|
private destroyed;
|
|
143
|
-
/**
|
|
163
|
+
/** When the last storage gap warning was reported, in epoch milliseconds. */
|
|
144
164
|
private lastGapAt;
|
|
145
|
-
/** Record limits
|
|
165
|
+
/** Record limits for the builder and the console. The app's first configure() sets them. */
|
|
146
166
|
private readonly limits;
|
|
147
|
-
/** Lifetime rules
|
|
167
|
+
/** Lifetime rules for the journey engine. The app's first configure() sets the age. */
|
|
148
168
|
private readonly journeyOptions;
|
|
149
|
-
/** False in a runtime
|
|
169
|
+
/** False in a runtime started by an early log call. The first configure() then sets limits. */
|
|
150
170
|
private tunablesLocked;
|
|
151
171
|
/**
|
|
152
|
-
* True for a console-only runtime
|
|
153
|
-
*
|
|
172
|
+
* True for a console-only runtime, which sends nothing, joins no bus and installs no capture.
|
|
173
|
+
* That happens next to another version of the library on the page, or on a server.
|
|
154
174
|
*/
|
|
155
175
|
private readonly degraded;
|
|
156
|
-
/** True
|
|
176
|
+
/** True once a destination on a server has been reported. It is reported only once. */
|
|
157
177
|
private serverReported;
|
|
158
178
|
/**
|
|
159
|
-
* Ends
|
|
160
|
-
*
|
|
179
|
+
* Ends a forwarder's root span when its document unloads. The exit flush only ends it in the
|
|
180
|
+
* sender, so without this the client spans of a frame or a view have no parent.
|
|
161
181
|
*/
|
|
162
182
|
private readonly onPageHide;
|
|
163
183
|
/**
|
|
@@ -166,86 +186,109 @@ export declare class ObservabilityRuntime {
|
|
|
166
186
|
*/
|
|
167
187
|
private constructor();
|
|
168
188
|
/**
|
|
169
|
-
*
|
|
170
|
-
*
|
|
171
|
-
* @returns The handler, or undefined
|
|
189
|
+
* Returns the diagnostics handler. With diagnostics.records, it also sends every event as
|
|
190
|
+
* a record.
|
|
191
|
+
* @returns The handler, or undefined with no onDiagnostic and no diagnostic records.
|
|
172
192
|
*/
|
|
173
193
|
private diagnosticHandler;
|
|
174
194
|
/**
|
|
175
195
|
* Sends a diagnostic event as a record when diagnostics.records selects its code.
|
|
176
|
-
* A diagnostic during that send
|
|
196
|
+
* A diagnostic raised during that send produces no record, which stops a loop.
|
|
177
197
|
* @param event Diagnostic event.
|
|
178
198
|
*/
|
|
179
199
|
private recordDiagnostic;
|
|
180
200
|
/**
|
|
181
|
-
* Adds a breadcrumb from app code.
|
|
182
|
-
*
|
|
183
|
-
* @param message Description of the event. A JavaScript caller can pass a
|
|
184
|
-
*
|
|
201
|
+
* Adds a breadcrumb from app code. The data is copied now, so a later change to the app's
|
|
202
|
+
* object doesn't change the trail.
|
|
203
|
+
* @param message Description of the event. A JavaScript caller can pass a non-string, which
|
|
204
|
+
* is converted.
|
|
185
205
|
* @param data Optional metadata.
|
|
186
206
|
*/
|
|
187
207
|
addBreadcrumb(message: unknown, data?: Record<string, unknown>): void;
|
|
188
208
|
/**
|
|
189
|
-
* Adds a value to a counter or a histogram. The meter sends one point
|
|
190
|
-
* @param def
|
|
209
|
+
* Adds a value to a counter or a histogram. The meter sends one point per interval.
|
|
210
|
+
* @param def The instrument's definition.
|
|
191
211
|
* @param value Value to add.
|
|
192
|
-
* @param attributes
|
|
212
|
+
* @param attributes The value's attribute set.
|
|
193
213
|
*/
|
|
194
214
|
recordMetric(def: InstrumentDef, value: number, attributes?: MetricAttributes): void;
|
|
195
215
|
/**
|
|
196
|
-
* Starts a timed operation.
|
|
216
|
+
* Starts a timed operation. Its values are dropped if the runtime has shut down or a rotation
|
|
217
|
+
* is running when it ends. With `securityContext.isolation`, a new delivery identity before
|
|
218
|
+
* the end drops them too.
|
|
197
219
|
* @param name Operation name.
|
|
198
|
-
* @param attributes Attribute set
|
|
199
|
-
* @returns The handle
|
|
220
|
+
* @param attributes Attribute set for every histogram point.
|
|
221
|
+
* @returns The operation's handle.
|
|
200
222
|
*/
|
|
201
223
|
startMeasure(name: string, attributes?: MetricAttributes): Measure;
|
|
202
224
|
/**
|
|
203
|
-
* Builds and emits the record
|
|
204
|
-
* drop it. The trace engine sampled the trace before the span existed.
|
|
225
|
+
* Builds and emits the record for one span. The console doesn't print it and minLevel
|
|
226
|
+
* doesn't drop it. The trace engine already sampled the trace before the span existed.
|
|
205
227
|
* @param span The span data.
|
|
206
228
|
*/
|
|
207
229
|
private recordSpan;
|
|
208
230
|
/**
|
|
209
|
-
* Builds and emits the record
|
|
231
|
+
* Builds and emits the record for one aggregated point. The console doesn't print it.
|
|
210
232
|
* @param name Metric name.
|
|
211
|
-
* @param attributes
|
|
212
|
-
* @param fields
|
|
233
|
+
* @param attributes The call's attributes. The record limits apply to them.
|
|
234
|
+
* @param fields The point's metric fields. The record limits don't truncate them.
|
|
213
235
|
*/
|
|
214
236
|
private emitPoint;
|
|
237
|
+
/**
|
|
238
|
+
* Turns the profiler on or off to match profiler.enabled. Before switching off it sends the
|
|
239
|
+
* points that are waiting, because the switch would otherwise drop them.
|
|
240
|
+
*/
|
|
241
|
+
private syncProfiler;
|
|
242
|
+
/**
|
|
243
|
+
* Gives or withdraws consent for session replay, and starts or stops the recorder if the
|
|
244
|
+
* capture is installed.
|
|
245
|
+
* @param consent True starts the recorder, false stops it.
|
|
246
|
+
*/
|
|
247
|
+
setReplay(consent: boolean): void;
|
|
248
|
+
/**
|
|
249
|
+
* Sends the open interval of the meter and the profiler. The profiler doesn't calibrate here,
|
|
250
|
+
* which keeps flush and the exit path short and synchronous.
|
|
251
|
+
*/
|
|
252
|
+
private collectPoints;
|
|
253
|
+
/**
|
|
254
|
+
* Starts a new identity epoch. With isolation on, the profiler also drops its data and open
|
|
255
|
+
* spans, so a span from the old identity can't add to the new one.
|
|
256
|
+
*/
|
|
257
|
+
private advanceIdentity;
|
|
215
258
|
/**
|
|
216
259
|
* Checks the source policy before a direct child link opens.
|
|
217
260
|
* @param source Child window.
|
|
218
|
-
* @param origin
|
|
219
|
-
* @returns True if the bus
|
|
261
|
+
* @param origin The child window's origin.
|
|
262
|
+
* @returns True if the bus allows this source.
|
|
220
263
|
*/
|
|
221
264
|
readonly busCanAccept: (source: Window, origin: string) => boolean;
|
|
222
265
|
/**
|
|
223
266
|
* Receives direct messages from same-origin child frames.
|
|
224
267
|
* @param message Inbound bus message.
|
|
225
268
|
* @param reply Direct response callback.
|
|
226
|
-
* @param source
|
|
269
|
+
* @param source The child frame's window.
|
|
227
270
|
*/
|
|
228
271
|
readonly busAccept: (message: BusMessage, reply: Receive, source?: Window) => void;
|
|
229
272
|
/**
|
|
230
|
-
* Returns the runtime on
|
|
273
|
+
* Returns the runtime on this realm's global key. Another copy of the library can own it.
|
|
231
274
|
* @returns Pinned runtime instance or null.
|
|
232
275
|
*/
|
|
233
276
|
private static pinned;
|
|
234
277
|
/**
|
|
235
|
-
* Returns
|
|
236
|
-
*
|
|
278
|
+
* Returns this copy's local runtime, or the pinned runtime if there is none. A pinned
|
|
279
|
+
* runtime from another version returns null, and a log call then starts the local runtime.
|
|
237
280
|
* @returns Active runtime instance or null.
|
|
238
281
|
*/
|
|
239
282
|
static current(): ObservabilityRuntime | null;
|
|
240
283
|
/**
|
|
241
284
|
* Returns the runtime that shutdown() stopped, until the next configure().
|
|
242
|
-
* A stopped runtime
|
|
285
|
+
* A stopped runtime from another version returns null.
|
|
243
286
|
* @returns Stopped runtime instance or null.
|
|
244
287
|
*/
|
|
245
288
|
static stopped(): ObservabilityRuntime | null;
|
|
246
289
|
/**
|
|
247
|
-
*
|
|
248
|
-
* @returns True
|
|
290
|
+
* Checks whether shutdown() stopped this runtime.
|
|
291
|
+
* @returns True once destroy() starts.
|
|
249
292
|
*/
|
|
250
293
|
isDestroyed(): boolean;
|
|
251
294
|
/**
|
|
@@ -256,10 +299,10 @@ export declare class ObservabilityRuntime {
|
|
|
256
299
|
*/
|
|
257
300
|
static configure(input: Partial<ObservabilityConfig>, implicit?: boolean): ObservabilityRuntime;
|
|
258
301
|
/**
|
|
259
|
-
* Starts a console-only runtime next to
|
|
260
|
-
*
|
|
302
|
+
* Starts a console-only runtime next to another version's runtime. It sends nothing, joins
|
|
303
|
+
* no bus and installs no capture. The other version keeps the page runtime.
|
|
261
304
|
* @param input Consumer configuration options.
|
|
262
|
-
* @param found
|
|
305
|
+
* @param found The pinned runtime's sdkVersion. A runtime older than 0.9.0 has none.
|
|
263
306
|
* @returns The local runtime.
|
|
264
307
|
*/
|
|
265
308
|
private static startDegraded;
|
|
@@ -269,15 +312,15 @@ export declare class ObservabilityRuntime {
|
|
|
269
312
|
*/
|
|
270
313
|
private reconfigure;
|
|
271
314
|
/**
|
|
272
|
-
*
|
|
315
|
+
* Checks whether the runtime is on a server, for example Node during server-side rendering.
|
|
273
316
|
* @returns True on Node.
|
|
274
317
|
*/
|
|
275
318
|
private onServer;
|
|
276
319
|
/**
|
|
277
|
-
* Removes the delivery settings from
|
|
278
|
-
* reports a destination
|
|
320
|
+
* Removes the delivery settings from a console-only runtime's input. On a server, it
|
|
321
|
+
* reports a destination once.
|
|
279
322
|
* @param input Consumer configuration options.
|
|
280
|
-
* @returns The options
|
|
323
|
+
* @returns The options the runtime accepts.
|
|
281
324
|
*/
|
|
282
325
|
private allowed;
|
|
283
326
|
/**
|
|
@@ -287,55 +330,58 @@ export declare class ObservabilityRuntime {
|
|
|
287
330
|
*/
|
|
288
331
|
private keepRouting;
|
|
289
332
|
/**
|
|
290
|
-
* Restores the startup tunables in the next config.
|
|
291
|
-
*
|
|
292
|
-
* @param next
|
|
333
|
+
* Restores the startup tunables in the next config. Each tunable is read once by some part
|
|
334
|
+
* of the runtime, so a later change would have no effect and is refused.
|
|
335
|
+
* @param next The resolved config from a later configure() call.
|
|
293
336
|
*/
|
|
294
337
|
private keepStartupTunables;
|
|
295
338
|
/**
|
|
296
|
-
* Refuses a change
|
|
297
|
-
* @param next
|
|
298
|
-
* @param sections Sections that
|
|
339
|
+
* Refuses a change to config sections by restoring the current values in the next config.
|
|
340
|
+
* @param next The resolved config from a later configure() call.
|
|
341
|
+
* @param sections Sections that can't change.
|
|
299
342
|
*/
|
|
300
343
|
private keepSections;
|
|
301
344
|
/**
|
|
302
|
-
* Restores the storage strategy
|
|
303
|
-
*
|
|
304
|
-
*
|
|
345
|
+
* Restores the built adapter's storage strategy. Every other key is read live, but the
|
|
346
|
+
* adapter is built only once. A new adapter would strand the batches in the old one, and
|
|
347
|
+
* that loss is worse than a refused change.
|
|
305
348
|
*/
|
|
306
349
|
private keepBuiltStorage;
|
|
307
350
|
/**
|
|
308
351
|
* Refuses a change that leaves the built delivery stack with no destination.
|
|
309
|
-
* Without
|
|
352
|
+
* Without one, the retry engine removes every stored batch as if it were delivered.
|
|
310
353
|
* @param input Partial configuration to merge.
|
|
311
354
|
* @returns Input without the refused changes.
|
|
312
355
|
*/
|
|
313
356
|
private keepDestination;
|
|
314
357
|
/**
|
|
315
|
-
* Restores the identity strategy from startup. The ids
|
|
316
|
-
*
|
|
358
|
+
* Restores the identity strategy from startup. The ids have existed since startup, and a
|
|
359
|
+
* later change can't move them to another store.
|
|
317
360
|
*/
|
|
318
361
|
private keepBuiltIdentity;
|
|
319
362
|
/** Initializes asynchronous subsystems and flushes the boot buffer. */
|
|
320
363
|
private init;
|
|
321
|
-
/**
|
|
364
|
+
/**
|
|
365
|
+
* Resolves the bus role, loads the delivery stack and releases the boot records.
|
|
366
|
+
* Never rejects.
|
|
367
|
+
*/
|
|
322
368
|
private boot;
|
|
323
369
|
/**
|
|
324
|
-
* Starts the
|
|
325
|
-
* @returns Promise that resolves to the started bus, or null if it
|
|
370
|
+
* Starts the bus load once.
|
|
371
|
+
* @returns Promise that resolves to the started bus, or null if it didn't load.
|
|
326
372
|
*/
|
|
327
373
|
private ensureBus;
|
|
328
374
|
/**
|
|
329
|
-
* Loads and constructs the bus
|
|
330
|
-
* @returns Promise that resolves to the constructed bus, or null if it
|
|
375
|
+
* Loads and constructs the bus once. Does not call start().
|
|
376
|
+
* @returns Promise that resolves to the constructed bus, or null if it didn't load.
|
|
331
377
|
*/
|
|
332
378
|
private constructBus;
|
|
333
379
|
/**
|
|
334
|
-
* Starts the constructed bus.
|
|
335
|
-
* @returns Promise that resolves to the started bus, or null if it
|
|
380
|
+
* Starts the constructed bus. Never rejects.
|
|
381
|
+
* @returns Promise that resolves to the started bus, or null if it didn't load or start.
|
|
336
382
|
*/
|
|
337
383
|
private startBus;
|
|
338
|
-
/** Imports and constructs the bus.
|
|
384
|
+
/** Imports and constructs the bus. Never rejects. */
|
|
339
385
|
private buildBus;
|
|
340
386
|
/**
|
|
341
387
|
* Reads the bus role. Without a bus, this context is the sender.
|
|
@@ -343,43 +389,65 @@ export declare class ObservabilityRuntime {
|
|
|
343
389
|
*/
|
|
344
390
|
private role;
|
|
345
391
|
/**
|
|
346
|
-
* Loads the delivery stack if this context is the sender and has an
|
|
392
|
+
* Loads the delivery stack if this context is the sender and has a destination, that is an
|
|
393
|
+
* endpoint or a custom transport.
|
|
347
394
|
* @returns Promise that resolves when the load completes, or immediately when nothing loads.
|
|
348
395
|
*/
|
|
349
396
|
private syncSender;
|
|
350
397
|
/**
|
|
351
|
-
*
|
|
352
|
-
* @returns True
|
|
398
|
+
* Checks whether the config names a destination for the records.
|
|
399
|
+
* @returns True if it has an endpoint or a custom transport.
|
|
353
400
|
*/
|
|
354
401
|
private hasDestination;
|
|
355
402
|
/**
|
|
356
|
-
* Starts the
|
|
403
|
+
* Starts the delivery stack load once.
|
|
357
404
|
* @returns Promise that resolves when the load completes or fails.
|
|
358
405
|
*/
|
|
359
406
|
private loadSender;
|
|
360
|
-
/**
|
|
407
|
+
/**
|
|
408
|
+
* Imports and builds the delivery stack, then moves the held records into it.
|
|
409
|
+
* Never rejects.
|
|
410
|
+
*/
|
|
361
411
|
private buildSender;
|
|
362
412
|
/** Refreshes temporary switches and restores local settings when their TTL ends. */
|
|
363
413
|
private refreshCaptures;
|
|
414
|
+
/**
|
|
415
|
+
* Serializes the current capture settings and profiler observers into one string. When the
|
|
416
|
+
* string changes, the captures are reinstalled.
|
|
417
|
+
* @param settings Current capture settings.
|
|
418
|
+
* @returns The string.
|
|
419
|
+
*/
|
|
420
|
+
private captureState;
|
|
421
|
+
/**
|
|
422
|
+
* Serializes what the replay recorder reads when it starts. The replay capture has its own
|
|
423
|
+
* key because a restart drops the buffer, so an unrelated capture change must not cause one.
|
|
424
|
+
* The other replay values are read on use and apply without a restart.
|
|
425
|
+
* @param settings Current capture settings.
|
|
426
|
+
* @returns The string. Empty while replay is off, so a replay change then installs nothing.
|
|
427
|
+
*/
|
|
428
|
+
private replayState;
|
|
364
429
|
/** Returns local capture settings with the permitted remote switches. */
|
|
365
430
|
private effectiveCapture;
|
|
366
|
-
/** Loads, builds and installs the enabled capture modules.
|
|
431
|
+
/** Loads, builds and installs the enabled capture modules. Never rejects. */
|
|
367
432
|
private installCaptures;
|
|
368
|
-
/**
|
|
433
|
+
/**
|
|
434
|
+
* Uninstalls the active capture modules.
|
|
435
|
+
* @param kept A replay capture that stays installed, if there is one.
|
|
436
|
+
*/
|
|
369
437
|
private uninstallCaptures;
|
|
370
438
|
/**
|
|
371
|
-
* Imports the WebSocket capture plugin. A failed import
|
|
439
|
+
* Imports the WebSocket capture plugin. A failed import is reported and skipped.
|
|
372
440
|
* @returns Promise that resolves to the class, or undefined if the import failed.
|
|
373
441
|
*/
|
|
374
442
|
private loadWebSocket;
|
|
375
443
|
/**
|
|
376
|
-
* Wraps a plugin as a capture module. The plugin gets public tools
|
|
377
|
-
* @param plugin
|
|
444
|
+
* Wraps a plugin as a capture module. The plugin only gets public tools.
|
|
445
|
+
* @param plugin The app's plugin, or a built-in one.
|
|
378
446
|
* @returns The capture module.
|
|
379
447
|
*/
|
|
380
448
|
private pluginCapture;
|
|
381
449
|
/**
|
|
382
|
-
* Imports one capture module. A failed import
|
|
450
|
+
* Imports one capture module. A failed import is reported and skips only that module.
|
|
383
451
|
* @param name Capture module name.
|
|
384
452
|
* @returns Promise that resolves to the class, or undefined if the import failed.
|
|
385
453
|
*/
|
|
@@ -404,8 +472,7 @@ export declare class ObservabilityRuntime {
|
|
|
404
472
|
*/
|
|
405
473
|
emit(record: LogRecord | null): void;
|
|
406
474
|
/**
|
|
407
|
-
* Sends a record to the forward buffer or to the local pipeline
|
|
408
|
-
* the path.
|
|
475
|
+
* Sends a record to the forward buffer or to the local pipeline, depending on the bus role.
|
|
409
476
|
* @param record Log record to route.
|
|
410
477
|
*/
|
|
411
478
|
private route;
|
|
@@ -416,7 +483,7 @@ export declare class ObservabilityRuntime {
|
|
|
416
483
|
*/
|
|
417
484
|
private deliver;
|
|
418
485
|
/**
|
|
419
|
-
* Counts a record
|
|
486
|
+
* Counts a record dropped by a full hold buffer and passes it to the onDrop report.
|
|
420
487
|
* @param record Dropped record.
|
|
421
488
|
*/
|
|
422
489
|
private dropHeld;
|
|
@@ -425,85 +492,87 @@ export declare class ObservabilityRuntime {
|
|
|
425
492
|
* @param record Log record to forward.
|
|
426
493
|
*/
|
|
427
494
|
private forward;
|
|
428
|
-
/**
|
|
495
|
+
/** Hands the forward buffer's records to the bus. */
|
|
429
496
|
private sendForwarded;
|
|
430
497
|
/**
|
|
431
|
-
* Validates, samples and queues records from child frames or workers.
|
|
432
|
-
*
|
|
433
|
-
*
|
|
498
|
+
* Validates, samples and queues records from child frames or workers. A forwarded record
|
|
499
|
+
* arrives already built, so this is the first point in this context where sampling can run.
|
|
500
|
+
* Local records are sampled by RecordBuilder.
|
|
434
501
|
* @param records Inbound payload from bus.
|
|
435
502
|
*/
|
|
436
503
|
private ingestForwarded;
|
|
437
|
-
/** Flushes the startup records
|
|
504
|
+
/** Flushes the startup records, adding the active journey to records that have none. */
|
|
438
505
|
private releaseBootBuffer;
|
|
439
506
|
/**
|
|
440
|
-
*
|
|
441
|
-
* @param reason
|
|
507
|
+
* Passes lost records to the onDrop report.
|
|
508
|
+
* @param reason Why they were lost.
|
|
442
509
|
* @param records Lost records.
|
|
443
510
|
* @param batchIds Ids of the lost batches.
|
|
444
511
|
*/
|
|
445
512
|
private readonly reportLoss;
|
|
446
513
|
/**
|
|
447
|
-
*
|
|
448
|
-
*
|
|
514
|
+
* Passes the evicted batches to the onDrop report and emits a warning record. The warning
|
|
515
|
+
* records are throttled.
|
|
449
516
|
* @param result Storage prune summary metrics.
|
|
450
517
|
* @param dropped The evicted batches.
|
|
451
518
|
*/
|
|
452
519
|
private readonly reportGap;
|
|
453
|
-
/**
|
|
520
|
+
/** Creates and stores a new tab ID after a tab ID collision. */
|
|
454
521
|
private regenerateTabId;
|
|
455
522
|
/**
|
|
456
|
-
* Starts a new session in this context.
|
|
457
|
-
* ends the active journey and clears the breadcrumbs. Other tabs
|
|
458
|
-
* startup.
|
|
523
|
+
* Starts a new session in this context. Sends the open metric points, starts a new trace,
|
|
524
|
+
* ends the active journey and clears the breadcrumbs. Other tabs pick up the new id at
|
|
525
|
+
* their next startup.
|
|
459
526
|
*/
|
|
460
527
|
newSession(): void;
|
|
461
528
|
/**
|
|
462
|
-
* Closes the
|
|
529
|
+
* Closes the old session's work and starts the given session.
|
|
463
530
|
* @param sessionId Id of the session to start.
|
|
464
531
|
*/
|
|
465
532
|
private resetSession;
|
|
466
533
|
/**
|
|
467
|
-
* Changes the delivery context in one operation. A second
|
|
534
|
+
* Changes the delivery context in one operation. A second call while this one is running is
|
|
535
|
+
* rejected.
|
|
468
536
|
* @param update New identity, delivery settings and context attributes.
|
|
469
|
-
* @param options
|
|
537
|
+
* @param options What to do with the old context's records, and the flush deadline.
|
|
470
538
|
* @returns Promise that resolves when the change completes. Invalid settings reject it.
|
|
471
539
|
*/
|
|
472
540
|
rotateSecurityContext(update: SecurityContextUpdate, options?: SecurityContextRotationOptions): Promise<void>;
|
|
473
541
|
/**
|
|
474
|
-
* Checks new settings, stops old delivery and starts the new context.
|
|
542
|
+
* Checks the new settings, stops the old delivery and starts the new context.
|
|
475
543
|
* @param update New identity, delivery settings and attributes.
|
|
476
|
-
* @param pending
|
|
544
|
+
* @param pending What to do with the old records.
|
|
477
545
|
* @param timeoutMs Maximum wait for an old-context flush, in milliseconds.
|
|
478
546
|
* @returns Promise that resolves when the context change completes.
|
|
479
547
|
*/
|
|
480
548
|
private rotateContext;
|
|
481
549
|
/**
|
|
482
|
-
* Moves the
|
|
550
|
+
* Moves the old context's records into the new context.
|
|
483
551
|
* @param live Records that were in memory. They go through the live buffer.
|
|
484
552
|
* @param stored Batches that were stored. The new sender stores them again.
|
|
485
|
-
* @returns Promise that resolves
|
|
553
|
+
* @returns Promise that resolves once the stored batches are stored again.
|
|
486
554
|
*/
|
|
487
555
|
private carry;
|
|
488
556
|
/**
|
|
489
|
-
* Collects
|
|
557
|
+
* Collects this runtime's state for a support ticket. The app decides where to send it.
|
|
490
558
|
* @param health Health snapshot from the facade, with the logger cache counts.
|
|
491
559
|
* @returns Promise that resolves to the JSON-safe bundle.
|
|
492
560
|
*/
|
|
493
561
|
debugBundle(health: ObservabilityHealth): Promise<DebugBundle>;
|
|
494
562
|
/**
|
|
495
|
-
* Reads
|
|
563
|
+
* Reads this runtime's state. Doesn't wait for startup or for the sender to load.
|
|
496
564
|
* @returns State, delivery counts and policies. The facade adds the logger cache counts.
|
|
497
565
|
*/
|
|
498
566
|
health(): Promise<Omit<ObservabilityHealth, "loggerCache">>;
|
|
499
567
|
/**
|
|
500
|
-
* Reads
|
|
568
|
+
* Reads this context's delivery state.
|
|
501
569
|
* @returns Promise that resolves to the counts and the time of the last accepted send.
|
|
502
570
|
*/
|
|
503
571
|
stats(): Promise<DeliveryStats>;
|
|
504
572
|
/**
|
|
505
|
-
* Removes stored records
|
|
506
|
-
*
|
|
573
|
+
* Removes the stored records for one context, or for all contexts in the application
|
|
574
|
+
* namespace.
|
|
575
|
+
* @param scope Which part of storage to clear.
|
|
507
576
|
* @returns Promise that resolves when removal completes.
|
|
508
577
|
*/
|
|
509
578
|
clearPersisted(scope: "context" | "namespace"): Promise<void>;
|
|
@@ -515,7 +584,7 @@ export declare class ObservabilityRuntime {
|
|
|
515
584
|
queueDepth(): Promise<number>;
|
|
516
585
|
/**
|
|
517
586
|
* Flushes all pending records in the pipeline or forward buffer.
|
|
518
|
-
* @returns Promise that resolves
|
|
587
|
+
* @returns Promise that resolves once the queued records are sent or handed off.
|
|
519
588
|
*/
|
|
520
589
|
flush(): Promise<void>;
|
|
521
590
|
}
|