@graphrefly/ts 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/actions-types-CSC3NMDl.d.ts +657 -0
- package/dist/actions-types-wl9Mgkmr.d.cts +657 -0
- package/dist/adapters/index.cjs +5157 -2951
- package/dist/adapters/index.cjs.map +1 -1
- package/dist/adapters/index.d.cts +207 -70
- package/dist/adapters/index.d.ts +207 -70
- package/dist/adapters/index.js +3738 -1688
- package/dist/adapters/index.js.map +1 -1
- package/dist/adapters/nestjs/microservices.cjs +841 -0
- package/dist/adapters/nestjs/microservices.cjs.map +1 -0
- package/dist/adapters/nestjs/microservices.d.cts +45 -0
- package/dist/adapters/nestjs/microservices.d.ts +45 -0
- package/dist/adapters/nestjs/microservices.js +206 -0
- package/dist/adapters/nestjs/microservices.js.map +1 -0
- package/dist/adapters/nestjs/native.cjs +1391 -0
- package/dist/adapters/nestjs/native.cjs.map +1 -0
- package/dist/adapters/nestjs/native.d.cts +111 -0
- package/dist/adapters/nestjs/native.d.ts +111 -0
- package/dist/adapters/nestjs/native.js +577 -0
- package/dist/adapters/nestjs/native.js.map +1 -0
- package/dist/adapters/nestjs/websockets.cjs +924 -0
- package/dist/adapters/nestjs/websockets.cjs.map +1 -0
- package/dist/adapters/nestjs/websockets.d.cts +47 -0
- package/dist/adapters/nestjs/websockets.d.ts +47 -0
- package/dist/adapters/nestjs/websockets.js +286 -0
- package/dist/adapters/nestjs/websockets.js.map +1 -0
- package/dist/adapters/nestjs.cjs +1085 -0
- package/dist/adapters/nestjs.cjs.map +1 -0
- package/dist/adapters/nestjs.d.cts +385 -0
- package/dist/adapters/nestjs.d.ts +385 -0
- package/dist/adapters/nestjs.js +112 -0
- package/dist/adapters/nestjs.js.map +1 -0
- package/dist/adapters/observe-storage.d.cts +3 -3
- package/dist/adapters/observe-storage.d.ts +3 -3
- package/dist/adapters/observe-storage.js +4 -4
- package/dist/adapters/react.cjs.map +1 -1
- package/dist/adapters/react.d.cts +2 -2
- package/dist/adapters/react.d.ts +2 -2
- package/dist/adapters/react.js +1 -1
- package/dist/adapters/solid.cjs.map +1 -1
- package/dist/adapters/solid.d.cts +2 -2
- package/dist/adapters/solid.d.ts +2 -2
- package/dist/adapters/solid.js +1 -1
- package/dist/adapters/svelte.cjs.map +1 -1
- package/dist/adapters/svelte.d.cts +2 -2
- package/dist/adapters/svelte.d.ts +2 -2
- package/dist/adapters/svelte.js +1 -1
- package/dist/adapters/vue.cjs.map +1 -1
- package/dist/adapters/vue.d.cts +2 -2
- package/dist/adapters/vue.d.ts +2 -2
- package/dist/adapters/vue.js +1 -1
- package/dist/{agent-runtime-DZTJ3C-p.d.cts → agent-runtime-types-core-CaXfKNtY.d.cts} +171 -320
- package/dist/{agent-runtime-BesGDZcB.d.ts → agent-runtime-types-core-hU299uIC.d.ts} +171 -320
- package/dist/agent-runtime-types-tool-BEpSINol.d.ts +695 -0
- package/dist/agent-runtime-types-tool-DninPEzk.d.cts +695 -0
- package/dist/agentic-memory-retention-BmGX368S.d.ts +14 -0
- package/dist/agentic-memory-retention-Ih1qhX9Z.d.cts +14 -0
- package/dist/{agentic-memory-BmRCvh0d.d.ts → agentic-memory-types-CVSUS6XR.d.ts} +13 -57
- package/dist/{agentic-memory-DfuVZ-lY.d.cts → agentic-memory-types-FnnYlVUs.d.cts} +13 -57
- package/dist/{capability-admission-g0mn9hpq.d.ts → capability-admission-BW2CziT6.d.ts} +3 -3
- package/dist/{capability-admission-B0BzqAm5.d.cts → capability-admission-lwSecxXs.d.cts} +3 -3
- package/dist/chunk-2KUAG2GZ.js +9693 -0
- package/dist/chunk-2KUAG2GZ.js.map +1 -0
- package/dist/chunk-2NJP6GO4.js +1320 -0
- package/dist/chunk-2NJP6GO4.js.map +1 -0
- package/dist/{chunk-YDSIVHRR.js → chunk-4NWSNI4K.js} +1598 -1584
- package/dist/chunk-4NWSNI4K.js.map +1 -0
- package/dist/{chunk-Z2ANQ6JW.js → chunk-4Q77MMJY.js} +2 -2
- package/dist/chunk-6E76H4OU.js +132 -0
- package/dist/chunk-6E76H4OU.js.map +1 -0
- package/dist/chunk-7GOTIIQ7.js +819 -0
- package/dist/chunk-7GOTIIQ7.js.map +1 -0
- package/dist/{chunk-IXZBUWSP.js → chunk-7HZRJMN6.js} +2 -2
- package/dist/{chunk-SS2A464I.js → chunk-CJIFGJQG.js} +3 -3
- package/dist/{chunk-V7CIJE4B.js → chunk-CX6B6PO2.js} +92 -9
- package/dist/chunk-CX6B6PO2.js.map +1 -0
- package/dist/{chunk-FBUU43PM.js → chunk-E4QCH32M.js} +448 -446
- package/dist/chunk-E4QCH32M.js.map +1 -0
- package/dist/{chunk-HKK2JD7Z.js → chunk-ECURQ3HD.js} +12 -125
- package/dist/chunk-ECURQ3HD.js.map +1 -0
- package/dist/{chunk-3JR3EDB2.js → chunk-EOKT4QFF.js} +121 -115
- package/dist/chunk-EOKT4QFF.js.map +1 -0
- package/dist/{chunk-K3FXTC3I.js → chunk-HJACH5PU.js} +3 -3
- package/dist/{chunk-GTPCOEOZ.js → chunk-IDMLXLLG.js} +3 -3
- package/dist/{chunk-DKP56CSW.js → chunk-JKAYLDQV.js} +2 -2
- package/dist/{chunk-4VLAQHZI.js → chunk-K7FB3JTD.js} +17 -1
- package/dist/chunk-K7FB3JTD.js.map +1 -0
- package/dist/{chunk-H75VXTGT.js → chunk-L6LDXRWE.js} +3 -3
- package/dist/{chunk-H75VXTGT.js.map → chunk-L6LDXRWE.js.map} +1 -1
- package/dist/{chunk-YXMZ2N6J.js → chunk-M7J6Z4IJ.js} +1071 -1025
- package/dist/chunk-M7J6Z4IJ.js.map +1 -0
- package/dist/chunk-MQEQMS7B.js +1009 -0
- package/dist/chunk-MQEQMS7B.js.map +1 -0
- package/dist/chunk-MTELVIYR.js +1421 -0
- package/dist/chunk-MTELVIYR.js.map +1 -0
- package/dist/{chunk-QFY4AFY4.js → chunk-PVC7WDKI.js} +58 -52
- package/dist/chunk-PVC7WDKI.js.map +1 -0
- package/dist/{chunk-VTHLCFN4.js → chunk-RAHNUYA5.js} +2 -2
- package/dist/{chunk-XKXWK2KP.js → chunk-SHZDP2MQ.js} +1157 -1021
- package/dist/chunk-SHZDP2MQ.js.map +1 -0
- package/dist/{chunk-CZNV3VXM.js → chunk-SIDJO2T4.js} +11 -11
- package/dist/chunk-STXRMPW4.js +4131 -0
- package/dist/chunk-STXRMPW4.js.map +1 -0
- package/dist/{chunk-2747WN4Y.js → chunk-TPND5MJS.js} +3 -3
- package/dist/chunk-TQPCAIQI.js +612 -0
- package/dist/chunk-TQPCAIQI.js.map +1 -0
- package/dist/{chunk-43BKLFZU.js → chunk-YDWBXXQZ.js} +10 -10
- package/dist/{chunk-6PHB5CJS.js → chunk-ZLFRB6FI.js} +2 -2
- package/dist/composition/index.cjs +1228 -1076
- package/dist/composition/index.cjs.map +1 -1
- package/dist/composition/index.d.cts +3 -3
- package/dist/composition/index.d.ts +3 -3
- package/dist/composition/index.js +4 -4
- package/dist/core/index.cjs +1198 -1046
- package/dist/core/index.cjs.map +1 -1
- package/dist/core/index.d.cts +1 -1
- package/dist/core/index.d.ts +1 -1
- package/dist/core/index.js +2 -2
- package/dist/cqrs/index.d.cts +3 -3
- package/dist/cqrs/index.d.ts +3 -3
- package/dist/cqrs/messaging.d.cts +4 -4
- package/dist/cqrs/messaging.d.ts +4 -4
- package/dist/cqrs/work-queue.d.cts +5 -5
- package/dist/cqrs/work-queue.d.ts +5 -5
- package/dist/data-structures/index.cjs +1226 -1074
- package/dist/data-structures/index.cjs.map +1 -1
- package/dist/data-structures/index.d.cts +8 -7
- package/dist/data-structures/index.d.ts +8 -7
- package/dist/data-structures/index.js +6 -5
- package/dist/{describe-BpyJuWkw.d.ts → describe-B_A5fbXH.d.ts} +1 -1
- package/dist/{describe-DYMw_l1C.d.cts → describe-CQRrkv-Q.d.cts} +1 -1
- package/dist/executors/tool-provider-adapters.cjs +3091 -0
- package/dist/executors/tool-provider-adapters.cjs.map +1 -0
- package/dist/executors/tool-provider-adapters.d.cts +174 -0
- package/dist/executors/tool-provider-adapters.d.ts +174 -0
- package/dist/executors/tool-provider-adapters.js +1336 -0
- package/dist/executors/tool-provider-adapters.js.map +1 -0
- package/dist/executors/tool-provider-runtime.cjs +5178 -0
- package/dist/executors/tool-provider-runtime.cjs.map +1 -0
- package/dist/executors/tool-provider-runtime.d.cts +17 -0
- package/dist/executors/tool-provider-runtime.d.ts +17 -0
- package/dist/executors/tool-provider-runtime.js +15 -0
- package/dist/executors/tool-provider-runtime.js.map +1 -0
- package/dist/executors/tool-provider.cjs +6392 -0
- package/dist/executors/tool-provider.cjs.map +1 -0
- package/dist/executors/tool-provider.d.cts +60 -0
- package/dist/executors/tool-provider.d.ts +60 -0
- package/dist/executors/tool-provider.js +89 -0
- package/dist/executors/tool-provider.js.map +1 -0
- package/dist/executors/work-queue.d.cts +6 -6
- package/dist/executors/work-queue.d.ts +6 -6
- package/dist/graph/index.cjs +1499 -1341
- package/dist/graph/index.cjs.map +1 -1
- package/dist/graph/index.d.cts +9 -8
- package/dist/graph/index.d.ts +9 -8
- package/dist/graph/index.js +23 -22
- package/dist/{graph-DCEWh4T2.d.cts → graph-CWK3HLPB.d.cts} +133 -131
- package/dist/{graph-D-1-SQeC.d.ts → graph-ho5sotHP.d.ts} +133 -131
- package/dist/{index-Bmxeu0nK.d.ts → index-CQWcE0Dw.d.ts} +18 -4
- package/dist/{index-72VZC0-E.d.cts → index-DHA1i67c.d.cts} +18 -4
- package/dist/index.cjs +3397 -3140
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +12 -9
- package/dist/index.d.ts +12 -9
- package/dist/index.js +110 -109
- package/dist/inspection/boundary.d.cts +4 -4
- package/dist/inspection/boundary.d.ts +4 -4
- package/dist/measurements-C0mAvWU1.d.cts +164 -0
- package/dist/measurements-OMpCeBwh.d.ts +164 -0
- package/dist/messaging/index.cjs +57 -51
- package/dist/messaging/index.cjs.map +1 -1
- package/dist/messaging/index.d.cts +11 -276
- package/dist/messaging/index.d.ts +11 -276
- package/dist/messaging/index.js +1 -1
- package/dist/operators/index.cjs +1228 -1076
- package/dist/operators/index.cjs.map +1 -1
- package/dist/operators/index.d.cts +5 -5
- package/dist/operators/index.d.ts +5 -5
- package/dist/operators/index.js +5 -5
- package/dist/orchestration/index.cjs +8844 -6071
- package/dist/orchestration/index.cjs.map +1 -1
- package/dist/orchestration/index.d.cts +171 -224
- package/dist/orchestration/index.d.ts +171 -224
- package/dist/orchestration/index.js +42 -991
- package/dist/orchestration/index.js.map +1 -1
- package/dist/orchestration/messaging.d.cts +5 -8
- package/dist/orchestration/messaging.d.ts +5 -8
- package/dist/orchestration/work-queue.cjs +1243 -5
- package/dist/orchestration/work-queue.cjs.map +1 -1
- package/dist/orchestration/work-queue.d.cts +121 -10
- package/dist/orchestration/work-queue.d.ts +121 -10
- package/dist/orchestration/work-queue.js +1067 -4
- package/dist/orchestration/work-queue.js.map +1 -1
- package/dist/patterns/event-flow.cjs +6 -20
- package/dist/patterns/event-flow.cjs.map +1 -1
- package/dist/patterns/event-flow.d.cts +4 -4
- package/dist/patterns/event-flow.d.ts +4 -4
- package/dist/patterns/event-flow.js +2 -2
- package/dist/patterns/index.cjs +453 -465
- package/dist/patterns/index.cjs.map +1 -1
- package/dist/patterns/index.d.cts +6 -5
- package/dist/patterns/index.d.ts +6 -5
- package/dist/patterns/index.js +3 -3
- package/dist/process-types-C9uMYz3i.d.ts +200 -0
- package/dist/process-types-h3uRlzDc.d.cts +200 -0
- package/dist/{reactive-collection-DNV0-gFi.d.cts → reactive-collection-B9R0Bl1P.d.cts} +4 -34
- package/dist/{reactive-collection-BAmfrGjd.d.ts → reactive-collection-BXFrH0U2.d.ts} +4 -34
- package/dist/{reactive-collection-storage-BNEldDyi.d.cts → reactive-collection-storage-BLGv8Xp8.d.cts} +5 -5
- package/dist/{reactive-collection-storage-YZsAQsWK.d.ts → reactive-collection-storage-a4zD3665.d.ts} +5 -5
- package/dist/{reactive-map-DRD1LJ2H.d.cts → reactive-map-C_8sOfdS.d.cts} +3 -2
- package/dist/{reactive-map-EsDiCmJk.d.ts → reactive-map-jle5dnok.d.ts} +3 -2
- package/dist/render/index.d.cts +2 -2
- package/dist/render/index.d.ts +2 -2
- package/dist/scheduled-readiness-5rwQlyjV.d.ts +91 -0
- package/dist/scheduled-readiness-DpRY8jI0.d.cts +91 -0
- package/dist/semantic-memory-graph-C2ZUwIlq.d.ts +30 -0
- package/dist/semantic-memory-graph-DlZBD_Eu.d.cts +30 -0
- package/dist/{semantic-memory-graph-DKuNzuWw.d.cts → semantic-memory-graph-types-BvzdqmkY.d.cts} +2 -28
- package/dist/{semantic-memory-graph-uwbwJdhe.d.ts → semantic-memory-graph-types-Ci-OtahO.d.ts} +2 -28
- package/dist/solutions/index.cjs +6353 -6169
- package/dist/solutions/index.cjs.map +1 -1
- package/dist/solutions/index.d.cts +12 -10
- package/dist/solutions/index.d.ts +12 -10
- package/dist/solutions/index.js +5 -5
- package/dist/solutions/reactive-layout/browser/index.cjs +116 -108
- package/dist/solutions/reactive-layout/browser/index.cjs.map +1 -1
- package/dist/solutions/reactive-layout/browser/index.d.cts +4 -4
- package/dist/solutions/reactive-layout/browser/index.d.ts +4 -4
- package/dist/solutions/reactive-layout/browser/index.js +3 -3
- package/dist/solutions/reactive-layout/index.cjs +3578 -3350
- package/dist/solutions/reactive-layout/index.cjs.map +1 -1
- package/dist/solutions/reactive-layout/index.d.cts +32 -576
- package/dist/solutions/reactive-layout/index.d.ts +32 -576
- package/dist/solutions/reactive-layout/index.js +65 -5
- package/dist/solutions/reactive-layout/node-canvas/index.cjs +127 -117
- package/dist/solutions/reactive-layout/node-canvas/index.cjs.map +1 -1
- package/dist/solutions/reactive-layout/node-canvas/index.d.cts +4 -4
- package/dist/solutions/reactive-layout/node-canvas/index.d.ts +4 -4
- package/dist/solutions/reactive-layout/node-canvas/index.js +3 -3
- package/dist/solutions/reactive-layout/react-native/index.cjs +127 -117
- package/dist/solutions/reactive-layout/react-native/index.cjs.map +1 -1
- package/dist/solutions/reactive-layout/react-native/index.d.cts +4 -4
- package/dist/solutions/reactive-layout/react-native/index.d.ts +4 -4
- package/dist/solutions/reactive-layout/react-native/index.js +3 -3
- package/dist/solutions/reactive-layout/skia/index.cjs +127 -117
- package/dist/solutions/reactive-layout/skia/index.cjs.map +1 -1
- package/dist/solutions/reactive-layout/skia/index.d.cts +4 -4
- package/dist/solutions/reactive-layout/skia/index.d.ts +4 -4
- package/dist/solutions/reactive-layout/skia/index.js +3 -3
- package/dist/solutions/work-item/actions.cjs +1609 -1428
- package/dist/solutions/work-item/actions.cjs.map +1 -1
- package/dist/solutions/work-item/actions.d.cts +23 -184
- package/dist/solutions/work-item/actions.d.ts +23 -184
- package/dist/solutions/work-item/actions.js +1558 -934
- package/dist/solutions/work-item/actions.js.map +1 -1
- package/dist/solutions/work-item/scheduling.cjs +9181 -1838
- package/dist/solutions/work-item/scheduling.cjs.map +1 -1
- package/dist/solutions/work-item/scheduling.d.cts +1763 -328
- package/dist/solutions/work-item/scheduling.d.ts +1763 -328
- package/dist/solutions/work-item/scheduling.js +117 -3
- package/dist/solutions/work-item/work-queue.d.cts +7 -7
- package/dist/solutions/work-item/work-queue.d.ts +7 -7
- package/dist/sources/browser.cjs +1318 -1083
- package/dist/sources/browser.cjs.map +1 -1
- package/dist/sources/browser.d.cts +4 -4
- package/dist/sources/browser.d.ts +4 -4
- package/dist/sources/browser.js +4 -4
- package/dist/sources/index.cjs +1318 -1083
- package/dist/sources/index.cjs.map +1 -1
- package/dist/sources/index.d.cts +4 -4
- package/dist/sources/index.d.ts +4 -4
- package/dist/sources/index.js +4 -4
- package/dist/sources/node.d.cts +3 -3
- package/dist/sources/node.d.ts +3 -3
- package/dist/storage/browser.cjs +16 -0
- package/dist/storage/browser.cjs.map +1 -1
- package/dist/storage/browser.js +3 -3
- package/dist/storage/index.cjs +16 -0
- package/dist/storage/index.cjs.map +1 -1
- package/dist/storage/index.d.cts +5 -4
- package/dist/storage/index.d.ts +5 -4
- package/dist/storage/index.js +6 -6
- package/dist/storage/node.cjs +16 -0
- package/dist/storage/node.cjs.map +1 -1
- package/dist/storage/node.js +3 -3
- package/dist/{store-C-joM4gh.d.ts → store-BmtEs9mG.d.ts} +1 -1
- package/dist/{store-CNJwmT-h.d.cts → store-PAAsYvML.d.cts} +1 -1
- package/dist/types-BRNKoFHj.d.ts +357 -0
- package/dist/{types-CcPIn7sy.d.cts → types-BS6CyR-x.d.cts} +27 -108
- package/dist/types-BWK2ay3e.d.cts +457 -0
- package/dist/types-BXKSAoE1.d.cts +357 -0
- package/dist/types-BaPpZItj.d.ts +457 -0
- package/dist/types-BhveCMg5.d.cts +274 -0
- package/dist/{types-BsJvElYZ.d.ts → types-C9NOgNJw.d.ts} +27 -108
- package/dist/types-CTsQ8Ww4.d.ts +274 -0
- package/dist/types-DL_05n2M.d.ts +34 -0
- package/dist/types-XDoqxYO9.d.cts +34 -0
- package/dist/{work-item-runtime-C3M79vE9.d.ts → work-item-runtime-types-BqtWnSCS.d.ts} +3 -93
- package/dist/{work-item-runtime-qaVgsL0T.d.cts → work-item-runtime-types-CHO03AKh.d.cts} +3 -93
- package/dist/work-queue/index.cjs +957 -953
- package/dist/work-queue/index.cjs.map +1 -1
- package/dist/work-queue/index.d.cts +9 -357
- package/dist/work-queue/index.d.ts +9 -357
- package/dist/work-queue/index.js +957 -953
- package/dist/work-queue/index.js.map +1 -1
- package/package.json +603 -513
- package/dist/chunk-3JR3EDB2.js.map +0 -1
- package/dist/chunk-4VLAQHZI.js.map +0 -1
- package/dist/chunk-6XAIOL3X.js +0 -2407
- package/dist/chunk-6XAIOL3X.js.map +0 -1
- package/dist/chunk-FBUU43PM.js.map +0 -1
- package/dist/chunk-HKK2JD7Z.js.map +0 -1
- package/dist/chunk-PC3BTTBE.js +0 -3217
- package/dist/chunk-PC3BTTBE.js.map +0 -1
- package/dist/chunk-QFY4AFY4.js.map +0 -1
- package/dist/chunk-V7CIJE4B.js.map +0 -1
- package/dist/chunk-XKXWK2KP.js.map +0 -1
- package/dist/chunk-YDSIVHRR.js.map +0 -1
- package/dist/chunk-YXMZ2N6J.js.map +0 -1
- /package/dist/{chunk-Z2ANQ6JW.js.map → chunk-4Q77MMJY.js.map} +0 -0
- /package/dist/{chunk-IXZBUWSP.js.map → chunk-7HZRJMN6.js.map} +0 -0
- /package/dist/{chunk-SS2A464I.js.map → chunk-CJIFGJQG.js.map} +0 -0
- /package/dist/{chunk-K3FXTC3I.js.map → chunk-HJACH5PU.js.map} +0 -0
- /package/dist/{chunk-GTPCOEOZ.js.map → chunk-IDMLXLLG.js.map} +0 -0
- /package/dist/{chunk-DKP56CSW.js.map → chunk-JKAYLDQV.js.map} +0 -0
- /package/dist/{chunk-VTHLCFN4.js.map → chunk-RAHNUYA5.js.map} +0 -0
- /package/dist/{chunk-CZNV3VXM.js.map → chunk-SIDJO2T4.js.map} +0 -0
- /package/dist/{chunk-2747WN4Y.js.map → chunk-TPND5MJS.js.map} +0 -0
- /package/dist/{chunk-43BKLFZU.js.map → chunk-YDWBXXQZ.js.map} +0 -0
- /package/dist/{chunk-6PHB5CJS.js.map → chunk-ZLFRB6FI.js.map} +0 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/adapters/nestjs/microservices.ts","../../../src/adapters/nestjs.ts"],"sourcesContent":["/**\n * NestJS microservice/message native phase bridge (D488).\n *\n * This focused subpath may import `@nestjs/microservices`; the dependency-light\n * structural layer and HTTP native bridge stay free of that optional peer.\n */\n\nimport type { CustomTransportStrategy } from \"@nestjs/microservices\";\nimport {\n\tbindingEmitOptions,\n\tbindingRequestId,\n\ttype DecoratorHostConstructor,\n\tfromNestMessage,\n\tGraphMessage,\n\tGraphMessageReply,\n\tgetNestBoundaryBindings,\n\ttype NestBoundaryBindingMeta,\n\ttype NestBoundaryDiagnostic,\n\ttype NestBoundaryEnvelope,\n\ttype NestDiagnosticIngressBoundary,\n\ttype NestGraphRunOptions,\n\ttype NestIngressBindingMeta,\n\ttype NestIngressBoundary,\n\ttype NestIngressEmitOptions,\n\ttype NestIngressOptions,\n\ttype NestMessageReplyBindingMeta,\n\ttype NestProviderBinding,\n\ttype NestReplyEnvelope,\n\ttype NestReplyResponseHandle,\n\tsanitizeNestDiagnostic,\n\ttoNestHttp,\n} from \"../nestjs.js\";\n\n/** D488 provider token for the focused Nest microservice/message native bridge. */\nexport const GRAPHREFLY_NEST_MESSAGE_BRIDGE = Symbol.for(\"graphrefly:nest:message-bridge\");\n\n/** Options for the D488 Nest message bridge; transport contexts stay host-private. */\nexport interface GraphMessageBridgeOptions<THost = unknown> extends NestGraphRunOptions<THost> {\n\treadonly diagnosticBoundary?: NestDiagnosticIngressBoundary;\n\treadonly timeoutMs?: number;\n\treadonly maxDiagnostics?: number;\n}\n\n/** D495 focused microservice/message provider bundle options. */\nexport interface GraphMessageProviderBundleOptions<THost = unknown> {\n\treadonly bridge?: GraphMessageBridgeOptions<THost> | false;\n}\n\n/** Explicit Nest message-pattern phase bridge over `GraphMessage` and `GraphMessageReply` metadata. */\nexport interface GraphMessageBridge<THost = unknown>\n\textends Pick<CustomTransportStrategy, \"close\"> {\n\thandleMessage(\n\t\ttarget: DecoratorHostConstructor | object,\n\t\tmethodKey: string | symbol,\n\t\thost: THost,\n\t\topts?: NestGraphRunOptions<THost>,\n\t): Promise<unknown> | undefined;\n\tonModuleDestroy(): void;\n\tdiagnostics(): readonly NestBoundaryDiagnostic[];\n\tdispose(): void;\n}\n\ntype MessageBoundary = ReturnType<typeof toNestHttp<unknown>>;\n\n/** Build a dependency-light Nest provider for the focused message bridge token. */\nexport function provideGraphMessageBridge<THost = unknown>(\n\topts: GraphMessageBridgeOptions<THost> = {},\n): NestProviderBinding<GraphMessageBridge<THost>> {\n\treturn { provide: GRAPHREFLY_NEST_MESSAGE_BRIDGE, useValue: createGraphMessageBridge(opts) };\n}\n\n/** Build the D495 focused message provider bundle without adding a router or event bus. */\nexport function provideGraphMessageProviders<THost = unknown>(\n\topts: GraphMessageProviderBundleOptions<THost> = {},\n): NestProviderBinding<GraphMessageBridge<THost>>[] {\n\treturn opts.bridge === false ? [] : [provideGraphMessageBridge(opts.bridge ?? {})];\n}\n\n/** Create a host-private message bridge instance without adding a router or event bus. */\nexport function createGraphMessageBridge<THost = unknown>(\n\topts: GraphMessageBridgeOptions<THost> = {},\n): GraphMessageBridge<THost> {\n\treturn new GraphMessageBridgeImpl(opts);\n}\n\nclass GraphMessageBridgeImpl<THost> implements GraphMessageBridge<THost> {\n\tprivate readonly boundaries = new WeakMap<object, Map<string, MessageBoundary>>();\n\tprivate readonly disposable = new Set<MessageBoundary>();\n\tprivate readonly localDiagnostics: NestBoundaryDiagnostic[] = [];\n\tprivate active = true;\n\n\tconstructor(private readonly opts: GraphMessageBridgeOptions<THost>) {}\n\n\tclose(): void {\n\t\tthis.dispose();\n\t}\n\n\tonModuleDestroy(): void {\n\t\tthis.dispose();\n\t}\n\n\thandleMessage(\n\t\ttarget: DecoratorHostConstructor | object,\n\t\tmethodKey: string | symbol,\n\t\thost: THost,\n\t\trunOpts: NestGraphRunOptions<THost> = {},\n\t): Promise<unknown> | undefined {\n\t\tif (!this.active) throw new Error(\"GraphMessage native bridge is disposed\");\n\t\tconst bindings = getNestBoundaryBindings(target, methodKey);\n\t\tconst ingress = bindings.filter(isMessageIngress);\n\t\tif (ingress.length === 0) return undefined;\n\t\tconst replies = bindings.filter(isMessageReply);\n\t\tconst needsRequestId = replies.length > 0;\n\t\tfor (const binding of ingress) assertExplicitNativePayload(binding, \"GraphMessage\");\n\t\tconst ingressEmits = ingress.map((binding) => ({\n\t\t\tbinding,\n\t\t\trequestId: bindingRequestId(host, binding, runOpts.requestId ?? this.opts.requestId),\n\t\t}));\n\t\tif (needsRequestId && ingressEmits.some((entry) => entry.requestId === undefined)) {\n\t\t\tthrow new Error(\"GraphMessage native bridge requires a stable requestId for reply egress\");\n\t\t}\n\t\tconst requestIds = uniqueDefinedStrings(ingressEmits.map((entry) => entry.requestId));\n\t\tconst cleanups: Array<() => boolean> = [];\n\t\tlet timeout: ReturnType<typeof setTimeout> | undefined;\n\t\tlet settled = false;\n\t\tlet resolvePromise: ((payload: unknown) => void) | undefined;\n\t\tlet rejectPromise: ((error: unknown) => void) | undefined;\n\t\tlet cleaned = false;\n\t\tconst cleanupAll = () => {\n\t\t\tif (cleaned) return;\n\t\t\tcleaned = true;\n\t\t\tfor (const cleanup of cleanups) cleanup();\n\t\t\tthis.clearTimeout(timeout);\n\t\t};\n\t\tconst handle: NestReplyResponseHandle<unknown> = {\n\t\t\tresolve(payload) {\n\t\t\t\tif (settled) return;\n\t\t\t\tsettled = true;\n\t\t\t\tresolvePromise?.(payload);\n\t\t\t},\n\t\t\treject(error) {\n\t\t\t\tif (settled) return;\n\t\t\t\tsettled = true;\n\t\t\t\trejectPromise?.(error);\n\t\t\t},\n\t\t};\n\t\tconst promise =\n\t\t\treplies.length === 0\n\t\t\t\t? undefined\n\t\t\t\t: new Promise<unknown>((resolve, reject) => {\n\t\t\t\t\t\tresolvePromise = resolve;\n\t\t\t\t\t\trejectPromise = reject;\n\t\t\t\t\t});\n\t\tif (promise !== undefined) {\n\t\t\ttry {\n\t\t\t\tfor (const requestId of requestIds) {\n\t\t\t\t\tfor (const reply of replies) {\n\t\t\t\t\t\tcleanups.push(\n\t\t\t\t\t\t\tthis.boundaryFor(reply).attach({\n\t\t\t\t\t\t\t\trequestId,\n\t\t\t\t\t\t\t\tbindingId: reply.bindingId,\n\t\t\t\t\t\t\t\thandle,\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} catch (error) {\n\t\t\t\tcleanupAll();\n\t\t\t\thandle.reject(error);\n\t\t\t\treturn promise;\n\t\t\t}\n\t\t\tif (settled) {\n\t\t\t\tcleanupAll();\n\t\t\t\treturn promise;\n\t\t\t}\n\t\t\tif (this.opts.timeoutMs !== undefined) {\n\t\t\t\ttimeout = setTimeout(() => {\n\t\t\t\t\tcleanupAll();\n\t\t\t\t\tconst error = new Error(\n\t\t\t\t\t\t`GraphMessage native bridge timed out waiting for ${requestIds[0]}`,\n\t\t\t\t\t);\n\t\t\t\t\tthis.diagnose({\n\t\t\t\t\t\tkind: \"timeout\",\n\t\t\t\t\t\trequestId: requestIds[0],\n\t\t\t\t\t\tmessage: error.message,\n\t\t\t\t\t\terror,\n\t\t\t\t\t});\n\t\t\t\t\thandle.reject(error);\n\t\t\t\t}, this.opts.timeoutMs);\n\t\t\t}\n\t\t}\n\t\ttry {\n\t\t\tfor (const { binding, requestId } of ingressEmits) {\n\t\t\t\tbinding.boundary.emit(host, {\n\t\t\t\t\t...bindingEmitOptions(host, binding, requestId),\n\t\t\t\t\trequireRequestId: needsRequestId,\n\t\t\t\t});\n\t\t\t}\n\t\t} catch (error) {\n\t\t\tcleanupAll();\n\t\t\tthrow error;\n\t\t}\n\t\treturn promise?.finally(() => {\n\t\t\tcleanupAll();\n\t\t});\n\t}\n\n\tdiagnostics(): readonly NestBoundaryDiagnostic[] {\n\t\treturn [\n\t\t\t...this.localDiagnostics,\n\t\t\t...[...this.disposable].flatMap((boundary) => boundary.diagnostics()),\n\t\t];\n\t}\n\n\tdispose(): void {\n\t\tif (!this.active) return;\n\t\tthis.active = false;\n\t\tfor (const boundary of this.disposable) boundary.dispose();\n\t}\n\n\tprivate boundaryFor(binding: NestMessageReplyBindingMeta): MessageBoundary {\n\t\tlet byBinding = this.boundaries.get(binding.replyNode);\n\t\tif (byBinding === undefined) {\n\t\t\tbyBinding = new Map();\n\t\t\tthis.boundaries.set(binding.replyNode, byBinding);\n\t\t}\n\t\tconst existing = byBinding.get(binding.bindingId);\n\t\tif (existing !== undefined) return existing;\n\t\tconst boundary = toNestHttp(binding.replyNode, {\n\t\t\tbindingId: binding.bindingId,\n\t\t\tdiagnosticBoundary: this.opts.diagnosticBoundary,\n\t\t\tdiagnosticPhase: \"message\",\n\t\t\tname: \"nestjs.message-reply\",\n\t\t\tmaxDiagnostics: this.opts.maxDiagnostics,\n\t\t});\n\t\tbyBinding.set(binding.bindingId, boundary);\n\t\tthis.disposable.add(boundary);\n\t\treturn boundary;\n\t}\n\n\tprivate diagnose(diagnostic: NestBoundaryDiagnostic): void {\n\t\tthis.localDiagnostics.push(diagnostic);\n\t\ttry {\n\t\t\tconst phase = diagnostic.phase ?? \"message\";\n\t\t\tconst payload = sanitizeNestDiagnostic({ ...diagnostic, phase }, phase);\n\t\t\tthis.opts.diagnosticBoundary?.emit(payload, { payload });\n\t\t} catch {\n\t\t\t// Graph-visible diagnostics are optional and must not interrupt host cleanup.\n\t\t}\n\t\tif (\n\t\t\tthis.opts.maxDiagnostics !== undefined &&\n\t\t\tthis.localDiagnostics.length > this.opts.maxDiagnostics\n\t\t) {\n\t\t\tthis.localDiagnostics.splice(0, this.localDiagnostics.length - this.opts.maxDiagnostics);\n\t\t}\n\t}\n\n\tprivate clearTimeout(timeout: ReturnType<typeof setTimeout> | undefined): void {\n\t\tif (timeout !== undefined) clearTimeout(timeout);\n\t}\n}\n\nfunction isMessageIngress(binding: NestBoundaryBindingMeta): binding is NestIngressBindingMeta {\n\treturn binding.direction === \"ingress\" && binding.kind === \"message\";\n}\n\nfunction isMessageReply(binding: NestBoundaryBindingMeta): binding is NestMessageReplyBindingMeta {\n\treturn binding.direction === \"egress\" && binding.kind === \"message-reply\";\n}\n\nfunction assertExplicitNativePayload(binding: NestIngressBindingMeta, label: string): void {\n\tif (binding.payload === undefined) {\n\t\tthrow new Error(`${label} native bridge requires an explicit payload selector`);\n\t}\n}\n\nfunction uniqueDefinedStrings(values: readonly (string | undefined)[]): string[] {\n\tconst seen = new Set<string>();\n\tfor (const value of values) if (value !== undefined) seen.add(value);\n\treturn [...seen];\n}\n\nexport {\n\tfromNestMessage,\n\tGraphMessage,\n\tGraphMessageReply,\n\ttype NestBoundaryEnvelope,\n\ttype NestIngressBoundary,\n\ttype NestIngressEmitOptions,\n\ttype NestIngressOptions,\n\ttype NestReplyEnvelope,\n};\n","/**\n * Focused NestJS boundary bindings for GraphReFly (D474/D478).\n *\n * This subpath stays dependency-light: it exposes graph boundary primitives,\n * token/provider shapes, and decorator metadata without importing Nest itself.\n * User-land Nest modules/controllers bind these helpers to real decorators and\n * host lifecycle objects at the framework edge.\n */\n\nimport type { DataIssue } from \"../data/index.js\";\nimport type { Graph } from \"../graph/graph.js\";\nimport type { Node } from \"../node/node.js\";\nimport type { Message } from \"../protocol/messages.js\";\n\nexport const NEST_BOUNDARY_ENVELOPE_VERSION = 1;\nexport const NEST_BOUNDARY_PAYLOAD_MAX_BYTES = 64 * 1024;\nexport const NEST_HTTP_DIAGNOSTICS_MAX_RETAINED = 100;\n\n/** D478 minimal graph-visible transport envelope. Payload must be data-only. */\nexport interface NestBoundaryEnvelope<T = unknown> {\n\treadonly bindingId: string;\n\treadonly version: number;\n\treadonly payload: T;\n\treadonly requestId?: string;\n}\n\n/** Reply-capable egress must carry host-private request correlation (D478). */\nexport type NestReplyEnvelope<T = unknown> = NestBoundaryEnvelope<T> & {\n\treadonly requestId: string;\n};\n\nexport type NestBoundaryKind =\n\t| \"request\"\n\t| \"guard\"\n\t| \"interceptor\"\n\t| \"error\"\n\t| \"lifecycle\"\n\t| \"cron\"\n\t| \"diagnostics\"\n\t| \"ws\"\n\t| \"message\";\n\nexport type NestEgressKind = \"http\" | \"guard-decision\" | \"ws-ack\" | \"ws-reply\" | \"message-reply\";\nexport type NestFilterMode = \"handle\" | \"observe\";\nexport type NestDiagnosticPhase =\n\t| \"adapter\"\n\t| \"http\"\n\t| \"guard\"\n\t| \"filter\"\n\t| \"cron\"\n\t| \"lifecycle\"\n\t| \"ws\"\n\t| \"message\"\n\t| NestBoundaryKind\n\t| NestEgressKind;\n\nexport interface NestHttpResponsePayload<TBody = unknown> {\n\treadonly status: number;\n\treadonly body?: TBody;\n\treadonly headers?: Record<string, string>;\n}\n\nexport interface HttpDataIssue extends DataIssue {\n\treadonly status: number;\n\treadonly body?: unknown;\n\treadonly headers?: Record<string, string>;\n}\n\nexport type NestIssueResponse<THost = unknown> = (\n\tissue: DataIssue,\n\thost: THost,\n) => NestHttpResponsePayload;\n\nexport type NestProtocolErrorResponse<THost = unknown> = (\n\terrorPayload: unknown,\n\thost: THost,\n) => NestHttpResponsePayload;\n\nexport type GraphGuardDecision =\n\t| {\n\t\t\treadonly kind: \"allow\";\n\t\t\treadonly reason?: string;\n\t\t\treadonly metadata?: Record<string, unknown>;\n\t }\n\t| {\n\t\t\treadonly kind: \"deny\";\n\t\t\treadonly reason?: string;\n\t\t\treadonly status?: number;\n\t\t\treadonly body?: unknown;\n\t\t\treadonly headers?: Record<string, string>;\n\t\t\treadonly issue?: DataIssue | HttpDataIssue;\n\t\t\treadonly metadata?: Record<string, unknown>;\n\t };\n\nexport interface NestBoundaryDiagnostic {\n\treadonly kind:\n\t\t| \"binding-mismatch\"\n\t\t| \"dispose-pending\"\n\t\t| \"malformed-egress\"\n\t\t| \"stale-egress\"\n\t\t| \"terminal-egress\"\n\t\t| \"timeout\"\n\t\t| \"resolve-threw\"\n\t\t| \"reject-threw\";\n\treadonly phase?: NestDiagnosticPhase;\n\treadonly requestId?: string;\n\treadonly bindingId?: string;\n\treadonly expectedBindingId?: string;\n\treadonly message: string;\n\treadonly error?: unknown;\n}\n\nexport interface NestDiagnosticErrorPayload {\n\treadonly name?: string;\n\treadonly message: string;\n}\n\nexport interface NestDiagnosticPayload {\n\treadonly kind: NestBoundaryDiagnostic[\"kind\"];\n\treadonly phase: NestDiagnosticPhase;\n\treadonly requestId?: string;\n\treadonly bindingId?: string;\n\treadonly expectedBindingId?: string;\n\treadonly message: string;\n\treadonly error?: NestDiagnosticErrorPayload;\n}\n\nexport interface NestDiagnosticInput extends NestBoundaryDiagnostic {\n\treadonly phase?: NestDiagnosticPhase;\n}\n\nexport interface NestDiagnosticsOptions\n\textends Omit<NestIngressOptions<NestDiagnosticInput, NestDiagnosticPayload>, \"payload\"> {\n\treadonly phase?: NestDiagnosticPhase;\n}\n\nexport type NestDiagnosticIngressBoundary = NestIngressBoundary<\n\tNestDiagnosticInput,\n\tNestDiagnosticPayload\n>;\n\nexport interface NestIngressBoundary<THost = unknown, TPayload = THost> {\n\treadonly kind: NestBoundaryKind;\n\treadonly bindingId: string;\n\treadonly version: number;\n\treadonly node: Node<NestBoundaryEnvelope<TPayload>>;\n\tenvelope(host: THost, opts?: NestIngressEmitOptions<TPayload>): NestBoundaryEnvelope<TPayload>;\n\temit(host: THost, opts?: NestIngressEmitOptions<TPayload>): NestBoundaryEnvelope<TPayload>;\n}\n\nexport interface NestIngressOptions<THost, TPayload> {\n\treadonly bindingId?: string;\n\treadonly name?: string;\n\treadonly version?: number;\n\treadonly maxPayloadBytes?: number;\n\treadonly requestId?: string | ((host: THost) => string | undefined);\n\treadonly requireRequestId?: boolean;\n\treadonly payload?: (host: THost) => TPayload;\n}\n\nexport interface NestIngressEmitOptions<TPayload> {\n\treadonly requestId?: string;\n\treadonly bindingId?: string;\n\treadonly version?: number;\n\treadonly payload?: TPayload;\n\treadonly requireRequestId?: boolean;\n}\n\nexport interface NestReplyResponseHandle<TPayload> {\n\tresolve(payload: TPayload, envelope: NestReplyEnvelope<TPayload>): void;\n\treject(error: unknown, envelope?: NestReplyEnvelope<TPayload>): void;\n}\n\nexport interface NestReplyPendingRegistration<TPayload> {\n\treadonly requestId: string;\n\treadonly handle: NestReplyResponseHandle<TPayload>;\n\treadonly bindingId?: string;\n}\n\nexport interface NestReplyBoundary<TPayload = unknown> {\n\treadonly kind: NestEgressKind;\n\treadonly bindingId: string;\n\tattach(registration: NestReplyPendingRegistration<TPayload>): () => boolean;\n\tpendingCount(): number;\n\tdiagnostics(): readonly NestBoundaryDiagnostic[];\n\tdispose(): void;\n}\n\nexport interface NestHttpResponseHandle<TPayload> extends NestReplyResponseHandle<TPayload> {}\n\nexport interface NestHttpPendingRegistration<TPayload>\n\textends NestReplyPendingRegistration<TPayload> {}\n\nexport interface NestHttpBoundary<TPayload = unknown> extends NestReplyBoundary<TPayload> {\n\treadonly kind: \"http\";\n}\n\nexport interface ToNestHttpOptions<TPayload> {\n\treadonly bindingId?: string;\n\treadonly diagnosticBoundary?: NestDiagnosticIngressBoundary;\n\treadonly diagnosticPhase?: NestDiagnosticPhase;\n\treadonly maxDiagnostics?: number;\n\treadonly maxPayloadBytes?: number;\n\treadonly name?: string;\n\treadonly transform?: (payload: TPayload, envelope: NestReplyEnvelope<TPayload>) => TPayload;\n\treadonly label?: string;\n}\n\ninterface NestReplyPendingEntry<TPayload> {\n\treadonly requestId: string;\n\treadonly bindingId?: string;\n\treadonly handle: NestReplyResponseHandle<TPayload>;\n}\n\ninterface NestHttpPendingEntry<TPayload> extends NestReplyPendingEntry<TPayload> {}\n\nexport interface NestBoundaryDecoratorOptions<THost = unknown, TPayload = unknown> {\n\treadonly bindingId?: string;\n\treadonly payload?: (host: THost) => TPayload;\n\treadonly requestId?: string | ((host: THost) => string | undefined);\n\treadonly order?: number;\n}\n\nexport interface NestFilterDecoratorOptions<THost = unknown, TPayload = unknown>\n\textends NestBoundaryDecoratorOptions<THost, TPayload> {\n\treadonly mode?: NestFilterMode;\n\treadonly issueResponse?: NestIssueResponse<THost>;\n\treadonly protocolError?: NestProtocolErrorResponse<THost>;\n}\n\nexport interface NestHttpReplyDecoratorOptions<THost = unknown> {\n\treadonly bindingId: string;\n\treadonly order?: number;\n\treadonly issueResponse?: NestIssueResponse<THost>;\n\treadonly protocolError?: NestProtocolErrorResponse<THost>;\n}\n\nexport interface NestGuardDecisionDecoratorOptions<THost = unknown> {\n\treadonly bindingId: string;\n\treadonly order?: number;\n\treadonly issueResponse?: NestIssueResponse<THost>;\n\treadonly protocolError?: NestProtocolErrorResponse<THost>;\n}\n\nexport interface NestGraphRunOptions<THost = unknown> {\n\treadonly requestId?: string | ((host: THost) => string | undefined);\n}\n\nexport interface NestGraphBoundaryRunnerOptions {\n\treadonly diagnosticBoundary?: NestDiagnosticIngressBoundary;\n\treadonly diagnosticPhase?: NestDiagnosticPhase;\n}\n\nexport interface NestGraphBoundaryRunner {\n\trun<THost = unknown>(\n\t\ttarget: DecoratorHostConstructor | object,\n\t\tmethodKey: string | symbol,\n\t\thost: THost,\n\t\topts?: NestGraphRunOptions<THost>,\n\t): Promise<unknown> | undefined;\n\tdispose(): void;\n}\n\nexport interface NestExecutionContextLike {\n\tgetClass(): DecoratorHostConstructor;\n\tgetHandler(): DecoratorBoundMethod;\n\tswitchToHttp?(): { getRequest<T = unknown>(): T };\n}\n\nexport interface NestCallHandlerLike {\n\thandle(): unknown;\n}\n\nexport interface NestGraphBoundaryInterceptorOptions<THost = unknown>\n\textends NestGraphRunOptions<THost>,\n\t\tNestGraphBoundaryRunnerOptions {\n\treadonly host?: (context: NestExecutionContextLike) => THost;\n\treadonly runner?: NestGraphBoundaryRunner;\n}\n\nexport interface NestGraphBoundaryInterceptor {\n\tintercept(\n\t\tcontext: NestExecutionContextLike,\n\t\tnext?: NestCallHandlerLike,\n\t): Promise<unknown> | unknown;\n\tdispose(): void;\n}\n\n/** Injection token for a root graph singleton. */\nexport const GRAPHREFLY_ROOT_GRAPH = Symbol.for(\"graphrefly:root-graph\");\n\n/** Injection token for adapter module options. */\nexport const GRAPHREFLY_MODULE_OPTIONS = Symbol.for(\"graphrefly:module-options\");\n\n/** Injection token for a request-scoped graph. */\nexport const GRAPHREFLY_REQUEST_GRAPH = Symbol.for(\"graphrefly:request-graph\");\n\nexport type DecoratorHostConstructor = abstract new (...args: unknown[]) => unknown;\nexport type DecoratorBoundMethod = (...args: unknown[]) => unknown;\n\nexport interface OnGraphEventMeta {\n\tnodeName: string;\n\tmethodKey: string | symbol;\n}\n\nexport interface GraphIntervalMeta {\n\tms: number;\n\tmethodKey: string | symbol;\n}\n\nexport interface GraphCronMeta {\n\texpr: string;\n\tmethodKey: string | symbol;\n}\n\nexport type NestBoundaryBindingDirection = \"ingress\" | \"egress\";\n\nexport interface NestIngressBindingMeta {\n\treadonly direction: \"ingress\";\n\tkind: NestBoundaryKind;\n\tbindingId: string;\n\tmethodKey: string | symbol;\n\treadonly boundary: NestIngressBoundary<unknown, unknown>;\n\treadonly payload?: (host: unknown) => unknown;\n\treadonly requestId?: string | ((host: unknown) => string | undefined);\n\treadonly order?: number;\n\treadonly mode?: NestFilterMode;\n\treadonly issueResponse?: NestIssueResponse<unknown>;\n\treadonly protocolError?: NestProtocolErrorResponse<unknown>;\n}\n\nexport interface NestHttpReplyBindingMeta {\n\treadonly direction: \"egress\";\n\treadonly kind: \"http\";\n\treadonly bindingId: string;\n\treadonly methodKey: string | symbol;\n\treadonly replyNode: Node<NestReplyEnvelope<unknown>>;\n\treadonly order?: number;\n\treadonly issueResponse?: NestIssueResponse<unknown>;\n\treadonly protocolError?: NestProtocolErrorResponse<unknown>;\n}\n\nexport interface NestGuardDecisionBindingMeta {\n\treadonly direction: \"egress\";\n\treadonly kind: \"guard-decision\";\n\treadonly bindingId: string;\n\treadonly methodKey: string | symbol;\n\treadonly decisionNode: Node<NestReplyEnvelope<GraphGuardDecision>>;\n\treadonly order?: number;\n\treadonly issueResponse?: NestIssueResponse<unknown>;\n\treadonly protocolError?: NestProtocolErrorResponse<unknown>;\n}\n\nexport interface NestWsAckBindingMeta {\n\treadonly direction: \"egress\";\n\treadonly kind: \"ws-ack\";\n\treadonly bindingId: string;\n\treadonly methodKey: string | symbol;\n\treadonly ackNode: Node<NestReplyEnvelope<unknown>>;\n\treadonly order?: number;\n}\n\nexport interface NestWsReplyBindingMeta {\n\treadonly direction: \"egress\";\n\treadonly kind: \"ws-reply\";\n\treadonly bindingId: string;\n\treadonly methodKey: string | symbol;\n\treadonly replyNode: Node<NestReplyEnvelope<unknown>>;\n\treadonly order?: number;\n}\n\nexport interface NestMessageReplyBindingMeta {\n\treadonly direction: \"egress\";\n\treadonly kind: \"message-reply\";\n\treadonly bindingId: string;\n\treadonly methodKey: string | symbol;\n\treadonly replyNode: Node<NestReplyEnvelope<unknown>>;\n\treadonly order?: number;\n}\n\nexport type NestBoundaryBindingMeta =\n\t| NestIngressBindingMeta\n\t| NestHttpReplyBindingMeta\n\t| NestGuardDecisionBindingMeta\n\t| NestWsAckBindingMeta\n\t| NestWsReplyBindingMeta\n\t| NestMessageReplyBindingMeta;\n\nexport const EVENT_HANDLERS = new WeakMap<DecoratorHostConstructor, OnGraphEventMeta[]>();\nexport const INTERVAL_HANDLERS = new WeakMap<DecoratorHostConstructor, GraphIntervalMeta[]>();\nexport const CRON_HANDLERS = new WeakMap<DecoratorHostConstructor, GraphCronMeta[]>();\nexport const NEST_BOUNDARY_BINDINGS = new WeakMap<\n\tDecoratorHostConstructor,\n\tNestBoundaryBindingMeta[]\n>();\n\nexport type GraphMethodDecorator = MethodDecorator &\n\t((value: DecoratorBoundMethod, context: ClassMethodDecoratorContext) => void);\n\n/** Minimal Nest provider object shape without importing @nestjs/common. */\nexport type NestProviderBinding<T = unknown> =\n\t| { readonly provide: string | symbol; readonly useValue: T }\n\t| { readonly provide: string | symbol; readonly useFactory: (...args: unknown[]) => T };\n\n/** Get the injection token for a named feature graph. */\nexport function getGraphToken(name: string): symbol {\n\tassertNonEmptyString(name, \"getGraphToken(name)\");\n\treturn Symbol.for(`graphrefly:graph:${name}`);\n}\n\n/** Get the injection token for a node at a qualified path. */\nexport function getNodeToken(path: string): symbol {\n\tassertNonEmptyString(path, \"getNodeToken(path)\");\n\treturn Symbol.for(`graphrefly:node:${path}`);\n}\n\n/** Get the injection token for a named Nest boundary binding. */\nexport function getNestBoundaryToken(bindingId: string): symbol {\n\tassertNonEmptyString(bindingId, \"getNestBoundaryToken(bindingId)\");\n\treturn Symbol.for(`graphrefly:nest-boundary:${bindingId}`);\n}\n\n/** Build a dependency-free provider binding shape for user-land Nest modules. */\nexport function nestProvider<T>(provide: string | symbol, useValue: T): NestProviderBinding<T> {\n\treturn { provide, useValue };\n}\n\n/** D474 P0 HTTP request ingress. */\nexport function fromNestReq<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"request\", opts);\n}\n\n/** D474 P0 guard/admission ingress. */\nexport function fromNestGuard<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"guard\", opts);\n}\n\n/** D474 P1 interceptor ingress. */\nexport function fromNestIntercept<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"interceptor\", opts);\n}\n\n/** D474 P0 error/filter ingress. */\nexport function fromNestError<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"error\", opts);\n}\n\n/** D474 P1 Nest lifecycle hook ingress. */\nexport function fromNestLifecycle<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"lifecycle\", opts);\n}\n\n/** D474 P1 schedule/cron ingress. */\nexport function fromNestCron<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"cron\", opts);\n}\n\n/** D494 explicit graph-visible diagnostics ingress. Emits sanitized data-only payloads. */\nexport function fromNestDiagnostics(\n\tgraph: Graph,\n\topts: NestDiagnosticsOptions = {},\n): NestDiagnosticIngressBoundary {\n\treturn nestIngress<NestDiagnosticInput, NestDiagnosticPayload>(graph, \"diagnostics\", {\n\t\t...opts,\n\t\tpayload: (diagnostic) => sanitizeNestDiagnostic(diagnostic, opts.phase),\n\t});\n}\n\n/** D474 later/optional WebSocket ingress. Kept thin for first-slice experiments. */\nexport function fromNestWs<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"ws\", opts);\n}\n\n/** D474 later/optional microservice/message ingress. */\nexport function fromNestMessage<THost = unknown, TPayload = THost>(\n\tgraph: Graph,\n\topts: NestIngressOptions<THost, TPayload> = {},\n): NestIngressBoundary<THost, TPayload> {\n\treturn nestIngress(graph, \"message\", opts);\n}\n\n/**\n * D474 HTTP egress resolver.\n *\n * The returned boundary owns only a host-private pending map. It never stores\n * response/socket/ack handles in graph DATA and only resolves handles whose\n * requestId (and optional bindingId) match an egress envelope.\n */\nexport function toNestHttp<TPayload = unknown>(\n\tegress: Node<NestReplyEnvelope<TPayload>>,\n\topts: ToNestHttpOptions<TPayload> = {},\n): NestHttpBoundary<TPayload> {\n\tconst bindingId = stableBindingId(\"http\", opts);\n\tconst scopedBindingId = opts.bindingId;\n\tconst maxDiagnostics = diagnosticsRetainedLimit(opts.maxDiagnostics);\n\tconst maxPayloadBytes = payloadByteLimit(opts.maxPayloadBytes);\n\tconst pending = new Map<string, NestHttpPendingEntry<TPayload>>();\n\tconst diagnostics: NestBoundaryDiagnostic[] = [];\n\tlet active = true;\n\tlet terminal:\n\t\t| {\n\t\t\t\treadonly error: unknown;\n\t\t\t\treadonly message: string;\n\t\t }\n\t\t| undefined;\n\n\tconst report = (diagnostic: NestBoundaryDiagnostic) => {\n\t\tpushDiagnostic(diagnostics, diagnostic, maxDiagnostics);\n\t\ttry {\n\t\t\tconst phase = diagnostic.phase ?? opts.diagnosticPhase ?? \"http\";\n\t\t\tconst payload = sanitizeNestDiagnostic({ ...diagnostic, phase }, phase);\n\t\t\topts.diagnosticBoundary?.emit(payload, { payload });\n\t\t} catch {\n\t\t\t// Graph-visible diagnostics are optional and must not interrupt host cleanup.\n\t\t}\n\t};\n\tconst keyOf = (requestId: string, requestBindingId?: string) =>\n\t\trequestBindingId === undefined ? requestId : `${requestBindingId}\\u0000${requestId}`;\n\tconst rejectEntry = (\n\t\tentry: NestHttpPendingEntry<TPayload>,\n\t\terror: unknown,\n\t\tenvelope: NestReplyEnvelope<TPayload> | undefined,\n\t\tmessage: string,\n\t) => {\n\t\ttry {\n\t\t\tentry.handle.reject(error, envelope);\n\t\t} catch (rejectError) {\n\t\t\treport({\n\t\t\t\tkind: \"reject-threw\",\n\t\t\t\trequestId: entry.requestId,\n\t\t\t\tbindingId: entry.bindingId,\n\t\t\t\tmessage,\n\t\t\t\terror: rejectError,\n\t\t\t});\n\t\t}\n\t};\n\tconst rejectPending = (\n\t\tkind: \"dispose-pending\" | \"terminal-egress\",\n\t\terror: unknown,\n\t\tmessage: string,\n\t): number => {\n\t\tconst entries = [...pending.values()];\n\t\tpending.clear();\n\t\tif (entries.length === 0) return 0;\n\t\treport({ kind, bindingId: scopedBindingId, message, error });\n\t\tfor (const entry of entries) {\n\t\t\trejectEntry(entry, error, undefined, `toNestHttp(${bindingId}) pending reject threw`);\n\t\t}\n\t\treturn entries.length;\n\t};\n\n\tconst unsubscribe = egress.subscribe((msg: Message) => {\n\t\tif (!active) return;\n\t\tif (msg[0] === \"ERROR\" || msg[0] === \"COMPLETE\" || msg[0] === \"TEARDOWN\") {\n\t\t\tconst error =\n\t\t\t\tmsg[0] === \"ERROR\"\n\t\t\t\t\t? msg[1]\n\t\t\t\t\t: new Error(`toNestHttp(${bindingId}) egress received ${msg[0]}`);\n\t\t\tconst message = `toNestHttp(${bindingId}) rejected pending requests after ${msg[0]}`;\n\t\t\tterminal = { error, message };\n\t\t\tconst rejectedCount = rejectPending(\"terminal-egress\", error, message);\n\t\t\tif (rejectedCount === 0)\n\t\t\t\treport({ kind: \"terminal-egress\", bindingId: scopedBindingId, message, error });\n\t\t\treturn;\n\t\t}\n\t\tif (msg[0] !== \"DATA\") return;\n\t\tconst envelope = msg[1] as NestReplyEnvelope<TPayload>;\n\t\tconst malformed = validateEnvelope(envelope, maxPayloadBytes);\n\t\tif (malformed !== undefined) {\n\t\t\tconst correlated = malformedCorrelation(msg[1], scopedBindingId);\n\t\t\tif (correlated !== undefined) {\n\t\t\t\tconst pendingKey = keyOf(correlated.requestId, scopedBindingId);\n\t\t\t\tconst entry = pending.get(pendingKey);\n\t\t\t\tif (entry !== undefined) {\n\t\t\t\t\tpending.delete(pendingKey);\n\t\t\t\t\trejectEntry(\n\t\t\t\t\t\tentry,\n\t\t\t\t\t\tnew Error(malformed),\n\t\t\t\t\t\tundefined,\n\t\t\t\t\t\t`toNestHttp(${bindingId}) rejected malformed correlated egress`,\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t}\n\t\t\treport({\n\t\t\t\tkind: \"malformed-egress\",\n\t\t\t\trequestId: correlated?.requestId,\n\t\t\t\tbindingId: correlated?.bindingId,\n\t\t\t\tmessage: malformed,\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\t\tif (scopedBindingId !== undefined && envelope.bindingId !== scopedBindingId) {\n\t\t\treport({\n\t\t\t\tkind: \"binding-mismatch\",\n\t\t\t\trequestId: envelope.requestId,\n\t\t\t\tbindingId: envelope.bindingId,\n\t\t\t\texpectedBindingId: scopedBindingId,\n\t\t\t\tmessage: `toNestHttp(${bindingId}) ignored egress for binding ${envelope.bindingId}`,\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\t\tconst pendingKey = keyOf(envelope.requestId, scopedBindingId);\n\t\tconst entry = pending.get(pendingKey);\n\t\tif (entry === undefined) {\n\t\t\treport({\n\t\t\t\tkind: \"stale-egress\",\n\t\t\t\trequestId: envelope.requestId,\n\t\t\t\tbindingId: envelope.bindingId,\n\t\t\t\tmessage: `toNestHttp(${bindingId}) ignored stale requestId ${envelope.requestId}`,\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\t\tpending.delete(pendingKey);\n\t\ttry {\n\t\t\tentry.handle.resolve(\n\t\t\t\topts.transform?.(envelope.payload, envelope) ?? envelope.payload,\n\t\t\t\tenvelope,\n\t\t\t);\n\t\t} catch (error) {\n\t\t\treport({\n\t\t\t\tkind: \"resolve-threw\",\n\t\t\t\trequestId: envelope.requestId,\n\t\t\t\tbindingId: envelope.bindingId,\n\t\t\t\tmessage: `toNestHttp(${bindingId}) response handle threw while resolving`,\n\t\t\t\terror,\n\t\t\t});\n\t\t\trejectEntry(\n\t\t\t\tentry,\n\t\t\t\terror,\n\t\t\t\tenvelope,\n\t\t\t\t`toNestHttp(${bindingId}) response handle threw while rejecting`,\n\t\t\t);\n\t\t}\n\t});\n\n\treturn {\n\t\tkind: \"http\",\n\t\tbindingId,\n\t\tattach(registration) {\n\t\t\tif (!active) throw new Error(`toNestHttp(${bindingId}) is disposed`);\n\t\t\tassertNonEmptyString(registration.requestId, \"toNestHttp.attach(requestId)\");\n\t\t\tconst registrationBindingId = registration.bindingId ?? scopedBindingId;\n\t\t\tif (scopedBindingId !== undefined && registrationBindingId !== scopedBindingId) {\n\t\t\t\tthrow new Error(\n\t\t\t\t\t`toNestHttp.attach expected bindingId ${scopedBindingId}, got ${registrationBindingId}`,\n\t\t\t\t);\n\t\t\t}\n\t\t\tif (terminal !== undefined) {\n\t\t\t\tconst entry = {\n\t\t\t\t\trequestId: registration.requestId,\n\t\t\t\t\tbindingId: registrationBindingId,\n\t\t\t\t\thandle: registration.handle,\n\t\t\t\t};\n\t\t\t\treport({\n\t\t\t\t\tkind: \"terminal-egress\",\n\t\t\t\t\trequestId: registration.requestId,\n\t\t\t\t\tbindingId: registrationBindingId,\n\t\t\t\t\tmessage: terminal.message,\n\t\t\t\t\terror: terminal.error,\n\t\t\t\t});\n\t\t\t\trejectEntry(\n\t\t\t\t\tentry,\n\t\t\t\t\tterminal.error,\n\t\t\t\t\tundefined,\n\t\t\t\t\t`toNestHttp(${bindingId}) terminal response handle reject threw`,\n\t\t\t\t);\n\t\t\t\treturn () => false;\n\t\t\t}\n\t\t\tconst key = keyOf(registration.requestId, scopedBindingId);\n\t\t\tif (pending.has(key)) {\n\t\t\t\tthrow new Error(`toNestHttp.attach duplicate pending requestId ${registration.requestId}`);\n\t\t\t}\n\t\t\tconst entry = {\n\t\t\t\trequestId: registration.requestId,\n\t\t\t\tbindingId: registrationBindingId,\n\t\t\t\thandle: registration.handle,\n\t\t\t};\n\t\t\tpending.set(key, entry);\n\t\t\treturn () => {\n\t\t\t\tif (pending.get(key) !== entry) return false;\n\t\t\t\treturn pending.delete(key);\n\t\t\t};\n\t\t},\n\t\tpendingCount: () => pending.size,\n\t\tdiagnostics: () => diagnostics.slice(),\n\t\tdispose() {\n\t\t\tif (!active) return;\n\t\t\tactive = false;\n\t\t\trejectPending(\n\t\t\t\t\"dispose-pending\",\n\t\t\t\tnew Error(`toNestHttp(${bindingId}) disposed before response resolution`),\n\t\t\t\t`toNestHttp(${bindingId}) rejected pending requests during dispose`,\n\t\t\t);\n\t\t\tunsubscribe();\n\t\t},\n\t};\n}\n\n/** D478 route-request decorator over an existing ingress boundary. */\nexport function GraphReq<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"request\", boundary, opts);\n}\n\n/** D478 route-guard decorator over an existing ingress boundary. */\nexport function GraphGuard<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"guard\", boundary, opts);\n}\n\n/** D478 route-interceptor decorator over an existing ingress boundary. */\nexport function GraphIntercept<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"interceptor\", boundary, opts);\n}\n\n/** D484 generic filter decorator over an existing ingress boundary. */\nexport function GraphFilter<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestFilterDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"error\", boundary, opts);\n}\n\n/** D484 exception-oriented sugar over GraphFilter. */\nexport function GraphError<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestFilterDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn GraphFilter(boundary, opts);\n}\n\n/** D478 lifecycle decorator over an existing ingress boundary. */\nexport function GraphLifecycle<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"lifecycle\", boundary, opts);\n}\n\n/** D478 cron/schedule decorator over an existing ingress boundary. */\nexport function GraphCron<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"cron\", boundary, opts);\n}\n\n/** D488 WebSocket message ingress decorator over an existing boundary. */\nexport function GraphWs<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"ws\", boundary, opts);\n}\n\n/** D488 microservice/message ingress decorator over an existing boundary. */\nexport function GraphMessage<THost = unknown, TPayload = unknown>(\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> = {},\n): GraphMethodDecorator {\n\treturn graphIngressBinding(\"message\", boundary, opts);\n}\n\n/** D478 HTTP reply decorator over an existing reply node. */\nexport function GraphHttpReply<THost = unknown, TPayload = unknown>(\n\treplyNode: Node<NestReplyEnvelope<TPayload>>,\n\topts: NestHttpReplyDecoratorOptions<THost>,\n): GraphMethodDecorator {\n\tconst bindingId = opts?.bindingId;\n\tif (typeof bindingId !== \"string\" || bindingId.length === 0) {\n\t\tthrow new Error(\"GraphHttpReply requires a non-empty bindingId\");\n\t}\n\treturn registerMeta(NEST_BOUNDARY_BINDINGS, (methodKey) => ({\n\t\tdirection: \"egress\" as const,\n\t\tkind: \"http\" as const,\n\t\tbindingId,\n\t\tmethodKey,\n\t\treplyNode: replyNode as Node<NestReplyEnvelope<unknown>>,\n\t\torder: opts.order,\n\t\tissueResponse: opts.issueResponse as NestIssueResponse<unknown> | undefined,\n\t\tprotocolError: opts.protocolError as NestProtocolErrorResponse<unknown> | undefined,\n\t}));\n}\n\n/** D484 guard decision egress decorator over an existing reply-correlated decision node. */\nexport function GraphGuardDecision<THost = unknown>(\n\tdecisionNode: Node<NestReplyEnvelope<GraphGuardDecision>>,\n\topts: NestGuardDecisionDecoratorOptions<THost>,\n): GraphMethodDecorator {\n\tconst bindingId = opts?.bindingId;\n\tif (typeof bindingId !== \"string\" || bindingId.length === 0) {\n\t\tthrow new Error(\"GraphGuardDecision requires a non-empty bindingId\");\n\t}\n\treturn registerMeta(NEST_BOUNDARY_BINDINGS, (methodKey) => ({\n\t\tdirection: \"egress\" as const,\n\t\tkind: \"guard-decision\" as const,\n\t\tbindingId,\n\t\tmethodKey,\n\t\tdecisionNode,\n\t\torder: opts.order,\n\t\tissueResponse: opts.issueResponse as NestIssueResponse<unknown> | undefined,\n\t\tprotocolError: opts.protocolError as NestProtocolErrorResponse<unknown> | undefined,\n\t}));\n}\n\n/** D488 WebSocket acknowledgement egress decorator over an existing reply-correlated node. */\nexport function GraphWsAck<TPayload = unknown>(\n\tackNode: Node<NestReplyEnvelope<TPayload>>,\n\topts: { readonly bindingId: string; readonly order?: number },\n): GraphMethodDecorator {\n\treturn graphReplyBinding(\"ws-ack\", ackNode, opts, \"GraphWsAck\");\n}\n\n/** D488 WebSocket reply egress decorator over an existing reply-correlated node. */\nexport function GraphWsReply<TPayload = unknown>(\n\treplyNode: Node<NestReplyEnvelope<TPayload>>,\n\topts: { readonly bindingId: string; readonly order?: number },\n): GraphMethodDecorator {\n\treturn graphReplyBinding(\"ws-reply\", replyNode, opts, \"GraphWsReply\");\n}\n\n/** D488 microservice/message reply egress decorator over an existing reply-correlated node. */\nexport function GraphMessageReply<TPayload = unknown>(\n\treplyNode: Node<NestReplyEnvelope<TPayload>>,\n\topts: { readonly bindingId: string; readonly order?: number },\n): GraphMethodDecorator {\n\treturn graphReplyBinding(\"message-reply\", replyNode, opts, \"GraphMessageReply\");\n}\n\nexport function createNestGraphBoundaryRunner(\n\topts: NestGraphBoundaryRunnerOptions = {},\n): NestGraphBoundaryRunner {\n\tconst httpBoundaries = new Map<\n\t\tNode<NestReplyEnvelope<unknown>>,\n\t\tMap<string, NestHttpBoundary<unknown>>\n\t>();\n\tconst httpBoundaryFor = (\n\t\tnode: Node<NestReplyEnvelope<unknown>>,\n\t\tbindingId: string,\n\t): NestHttpBoundary<unknown> => {\n\t\tlet byBinding = httpBoundaries.get(node);\n\t\tif (byBinding === undefined) {\n\t\t\tbyBinding = new Map();\n\t\t\thttpBoundaries.set(node, byBinding);\n\t\t}\n\t\tlet boundary = byBinding.get(bindingId);\n\t\tif (boundary === undefined) {\n\t\t\tboundary = toNestHttp(node, {\n\t\t\t\tbindingId,\n\t\t\t\tdiagnosticBoundary: opts.diagnosticBoundary,\n\t\t\t\tdiagnosticPhase: opts.diagnosticPhase ?? \"http\",\n\t\t\t});\n\t\t\tbyBinding.set(bindingId, boundary);\n\t\t}\n\t\treturn boundary;\n\t};\n\n\treturn {\n\t\trun(target, methodKey, host, opts = {}) {\n\t\t\tconst ctor = typeof target === \"function\" ? target : target.constructor;\n\t\t\tconst bindings = getNestBoundaryBindings(ctor as DecoratorHostConstructor, methodKey);\n\t\t\tif (bindings.length === 0) return undefined;\n\t\t\tconst requestId = requestIdFromRunOptions(host, opts);\n\t\t\tconst replies = bindings.filter(isHttpReplyBinding);\n\t\t\tconst ingress = bindings.filter(\n\t\t\t\t(binding): binding is NestIngressBindingMeta =>\n\t\t\t\t\tbinding.direction === \"ingress\" &&\n\t\t\t\t\t(binding.kind === \"request\" || binding.kind === \"interceptor\"),\n\t\t\t);\n\t\t\tif (replies.length > 0 && ingress.length === 0) {\n\t\t\t\tthrow new Error(\"Nest GraphHttpReply requires at least one ingress boundary\");\n\t\t\t}\n\t\t\tconst ingressEmits = ingress.map((binding) => ({\n\t\t\t\tbinding,\n\t\t\t\trequestId: requestIdFromBinding(host, binding) ?? requestId,\n\t\t\t}));\n\t\t\tconst replyRequestIds = uniqueDefinedStrings(ingressEmits.map((entry) => entry.requestId));\n\t\t\tif (replies.length > 0 && replyRequestIds.length === 0) {\n\t\t\t\tthrow new Error(\"Nest GraphHttpReply requires a stable requestId\");\n\t\t\t}\n\t\t\tconst cleanups: Array<() => boolean> = [];\n\t\t\tlet resolveReply: ((value: unknown) => void) | undefined;\n\t\t\tlet rejectReply: ((reason?: unknown) => void) | undefined;\n\t\t\tconst replyPromise =\n\t\t\t\treplies.length === 0\n\t\t\t\t\t? undefined\n\t\t\t\t\t: new Promise<unknown>((resolve, reject) => {\n\t\t\t\t\t\t\tresolveReply = resolve;\n\t\t\t\t\t\t\trejectReply = reject;\n\t\t\t\t\t\t});\n\t\t\ttry {\n\t\t\t\tfor (const reply of replies) {\n\t\t\t\t\tconst http = httpBoundaryFor(reply.replyNode, reply.bindingId);\n\t\t\t\t\tfor (const replyRequestId of replyRequestIds) {\n\t\t\t\t\t\tcleanups.push(\n\t\t\t\t\t\t\thttp.attach({\n\t\t\t\t\t\t\t\trequestId: replyRequestId,\n\t\t\t\t\t\t\t\tbindingId: reply.bindingId,\n\t\t\t\t\t\t\t\thandle: {\n\t\t\t\t\t\t\t\t\tresolve: resolveReply ?? (() => undefined),\n\t\t\t\t\t\t\t\t\treject: rejectReply ?? (() => undefined),\n\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tfor (const entry of ingressEmits) {\n\t\t\t\t\tentry.binding.boundary.emit(host, {\n\t\t\t\t\t\tbindingId: entry.binding.bindingId,\n\t\t\t\t\t\trequestId: entry.requestId,\n\t\t\t\t\t\t...bindingPayloadEmitOption(host, entry.binding),\n\t\t\t\t\t\trequireRequestId: requiresRequestId(entry.binding.kind),\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t} catch (error) {\n\t\t\t\tfor (const cleanup of cleanups) cleanup();\n\t\t\t\tthrow error;\n\t\t\t}\n\t\t\treturn replyPromise?.finally(() => {\n\t\t\t\tfor (const cleanup of cleanups) cleanup();\n\t\t\t});\n\t\t},\n\t\tdispose() {\n\t\t\tfor (const byBinding of httpBoundaries.values()) {\n\t\t\t\tfor (const boundary of byBinding.values()) boundary.dispose();\n\t\t\t}\n\t\t\thttpBoundaries.clear();\n\t\t},\n\t};\n}\n\nexport function createNestGraphBoundaryInterceptor<THost = unknown>(\n\topts: NestGraphBoundaryInterceptorOptions<THost> = {},\n): NestGraphBoundaryInterceptor {\n\tconst runner = opts.runner ?? createNestGraphBoundaryRunner(opts);\n\tlet nextRequestSeq = 1;\n\treturn {\n\t\tintercept(context, next) {\n\t\t\tconst ctor = context.getClass();\n\t\t\tconst handler = context.getHandler();\n\t\t\tconst methodKey = methodKeyForHandler(ctor, handler);\n\t\t\tif (methodKey === undefined) return next?.handle();\n\t\t\tconst bindings = getNestBoundaryBindings(ctor, methodKey);\n\t\t\tconst needsSyntheticRequestId = bindings.some(\n\t\t\t\t(binding) =>\n\t\t\t\t\tbinding.direction === \"egress\" ||\n\t\t\t\t\t(binding.direction === \"ingress\" && requiresRequestId(binding.kind)),\n\t\t\t);\n\t\t\tconst host =\n\t\t\t\topts.host?.(context) ??\n\t\t\t\t(defaultNestHttpHost(context, () => nextRequestSeq++, needsSyntheticRequestId) as THost) ??\n\t\t\t\t({} as THost);\n\t\t\tconst result = runner.run(ctor, methodKey, host, opts);\n\t\t\treturn result ?? next?.handle();\n\t\t},\n\t\tdispose() {\n\t\t\trunner.dispose();\n\t\t},\n\t};\n}\n\nexport function getNestBoundaryBindings(\n\ttarget: DecoratorHostConstructor | object,\n\tmethodKey?: string | symbol,\n): readonly NestBoundaryBindingMeta[] {\n\tconst ctor =\n\t\ttypeof target === \"function\"\n\t\t\t? (target as DecoratorHostConstructor)\n\t\t\t: ((target as { constructor: DecoratorHostConstructor })\n\t\t\t\t\t.constructor as DecoratorHostConstructor);\n\tconst bindings = boundaryBindingsFor(ctor);\n\treturn sortBoundaryBindings(\n\t\tmethodKey === undefined\n\t\t\t? bindings\n\t\t\t: bindings.filter((binding) => binding.methodKey === methodKey),\n\t);\n}\n\nexport function resolveNestMethodKey(\n\tctor: DecoratorHostConstructor,\n\thandler: DecoratorBoundMethod,\n): string | symbol | undefined {\n\treturn methodKeyForHandler(ctor, handler);\n}\n\nexport function bindingRequestId<THost>(\n\thost: THost,\n\tbinding: NestBoundaryBindingMeta,\n\tfallback?: string | ((host: THost) => string | undefined),\n): string | undefined {\n\tif (binding.direction === \"ingress\") {\n\t\tconst requestId = requestIdFromBinding(host, binding);\n\t\tif (requestId !== undefined) return requestId;\n\t}\n\tif (typeof fallback === \"string\") {\n\t\tassertNonEmptyString(fallback, \"requestId\");\n\t\treturn fallback;\n\t}\n\tif (typeof fallback === \"function\") {\n\t\tconst requestId = fallback(host);\n\t\tif (requestId !== undefined) assertNonEmptyString(requestId, \"requestId\");\n\t\treturn requestId;\n\t}\n\treturn requestIdOf(host, {}, {});\n}\n\nexport function bindingEmitOptions<THost>(\n\thost: THost,\n\tbinding: NestIngressBindingMeta,\n\trequestId?: string,\n): NestIngressEmitOptions<unknown> {\n\treturn {\n\t\tbindingId: binding.bindingId,\n\t\trequestId,\n\t\t...bindingPayloadEmitOption(host, binding),\n\t\trequireRequestId: requiresRequestId(binding.kind),\n\t};\n}\n\nexport function isDataIssue(value: unknown): value is DataIssue {\n\treturn (\n\t\tvalue !== null &&\n\t\ttypeof value === \"object\" &&\n\t\t(value as { kind?: unknown }).kind === \"issue\" &&\n\t\ttypeof (value as { code?: unknown }).code === \"string\" &&\n\t\ttypeof (value as { message?: unknown }).message === \"string\"\n\t);\n}\n\nexport function isHttpDataIssue(value: unknown): value is HttpDataIssue {\n\treturn isDataIssue(value) && Number.isInteger((value as { status?: unknown }).status);\n}\n\nexport function issueResponse<THost = unknown>(\n\tissue: DataIssue,\n\t_host?: THost,\n): NestHttpResponsePayload {\n\tif (isHttpDataIssue(issue)) {\n\t\treturn {\n\t\t\tstatus: issue.status,\n\t\t\tbody: issue.body ?? { code: issue.code, message: issue.message },\n\t\t\theaders: issue.headers,\n\t\t};\n\t}\n\treturn {\n\t\tstatus: 400,\n\t\tbody: { code: issue.code, message: issue.message },\n\t};\n}\n\nexport function protocolError<THost = unknown>(\n\t_errorPayload: unknown,\n\t_host?: THost,\n): NestHttpResponsePayload {\n\treturn {\n\t\tstatus: 500,\n\t\tbody: { code: \"graphrefly.protocol_error\", message: \"GraphReFly reply pipeline failed\" },\n\t};\n}\n\nexport function lowerHttpReplyPayload<THost = unknown>(\n\tpayload: unknown,\n\thost: THost,\n\topts: { readonly issueResponse?: NestIssueResponse<THost> } = {},\n): NestHttpResponsePayload {\n\tif (isHttpResponsePayload(payload)) return payload;\n\tif (isDataIssue(payload)) return (opts.issueResponse ?? issueResponse)(payload, host);\n\treturn { status: 200, body: payload };\n}\n\nexport function lowerProtocolError<THost = unknown>(\n\terrorPayload: unknown,\n\thost: THost,\n\topts: { readonly protocolError?: NestProtocolErrorResponse<THost> } = {},\n): NestHttpResponsePayload {\n\treturn (opts.protocolError ?? protocolError)(errorPayload, host);\n}\n\nexport function sanitizeNestDiagnostic(\n\tdiagnostic: NestDiagnosticInput,\n\tdefaultPhase: NestDiagnosticPhase = \"adapter\",\n): NestDiagnosticPayload {\n\tconst payload: NestDiagnosticPayload = {\n\t\tkind: diagnostic.kind,\n\t\tphase: diagnostic.phase ?? defaultPhase,\n\t\tmessage: diagnostic.message,\n\t\t...optionalStringField(\"requestId\", diagnostic.requestId),\n\t\t...optionalStringField(\"bindingId\", diagnostic.bindingId),\n\t\t...optionalStringField(\"expectedBindingId\", diagnostic.expectedBindingId),\n\t\t...optionalDiagnosticError(diagnostic.error),\n\t};\n\tassertGraphVisibleData(payload, \"NestDiagnosticPayload\", NEST_BOUNDARY_PAYLOAD_MAX_BYTES);\n\treturn payload;\n}\n\nfunction nestIngress<THost, TPayload>(\n\tgraph: Graph,\n\tkind: NestBoundaryKind,\n\topts: NestIngressOptions<THost, TPayload>,\n): NestIngressBoundary<THost, TPayload> {\n\tconst bindingId = stableBindingId(kind, opts);\n\tconst version = parseEnvelopeVersion(opts.version ?? NEST_BOUNDARY_ENVELOPE_VERSION, \"version\");\n\tconst maxPayloadBytes = payloadByteLimit(opts.maxPayloadBytes);\n\tconst node = graph.node<NestBoundaryEnvelope<TPayload>>([], null, {\n\t\tname: opts.name,\n\t\tmeta: { adapter: \"nestjs\", boundary: \"ingress\", kind, bindingId, version },\n\t});\n\n\treturn {\n\t\tkind,\n\t\tbindingId,\n\t\tversion,\n\t\tnode,\n\t\tenvelope(host, emitOpts = {}) {\n\t\t\tconst requestId = requestIdOf(host, opts, {\n\t\t\t\t...emitOpts,\n\t\t\t\trequireRequestId:\n\t\t\t\t\temitOpts.requireRequestId ?? opts.requireRequestId ?? requiresRequestId(kind),\n\t\t\t});\n\t\t\tconst envelopeBindingId = emitOpts.bindingId ?? bindingId;\n\t\t\tassertNonEmptyString(envelopeBindingId, \"NestBoundaryEnvelope.bindingId\");\n\t\t\tconst envelopeVersion = parseEnvelopeVersion(\n\t\t\t\temitOpts.version ?? version,\n\t\t\t\t\"NestBoundaryEnvelope.version\",\n\t\t\t);\n\t\t\tconst payload =\n\t\t\t\t\"payload\" in emitOpts\n\t\t\t\t\t? (emitOpts.payload as TPayload)\n\t\t\t\t\t: opts.payload !== undefined\n\t\t\t\t\t\t? opts.payload(host)\n\t\t\t\t\t\t: (host as unknown as TPayload);\n\t\t\tassertGraphVisibleData(payload, \"NestBoundaryEnvelope.payload\", maxPayloadBytes);\n\t\t\tconst envelope: NestBoundaryEnvelope<TPayload> = {\n\t\t\t\tbindingId: envelopeBindingId,\n\t\t\t\tversion: envelopeVersion,\n\t\t\t\tpayload,\n\t\t\t};\n\t\t\treturn requestId === undefined ? envelope : { ...envelope, requestId };\n\t\t},\n\t\temit(host, emitOpts = {}) {\n\t\t\tconst envelope = this.envelope(host, emitOpts);\n\t\t\tnode.down([[\"DATA\", envelope]]);\n\t\t\treturn envelope;\n\t\t},\n\t};\n}\n\nfunction stableBindingId(\n\tkind: NestBoundaryKind | NestEgressKind,\n\topts: { readonly bindingId?: string; readonly name?: string },\n): string {\n\tconst bindingId = opts.bindingId ?? opts.name ?? `nestjs.${kind}`;\n\tassertNonEmptyString(bindingId, \"bindingId\");\n\treturn bindingId;\n}\n\nfunction requiresRequestId(kind: NestBoundaryKind): boolean {\n\treturn kind === \"request\" || kind === \"guard\" || kind === \"interceptor\" || kind === \"error\";\n}\n\nfunction requestIdFromRunOptions<THost>(\n\thost: THost,\n\topts: NestGraphRunOptions<THost>,\n): string | undefined {\n\tif (typeof opts.requestId === \"string\") {\n\t\tassertNonEmptyString(opts.requestId, \"requestId\");\n\t\treturn opts.requestId;\n\t}\n\tif (typeof opts.requestId === \"function\") {\n\t\tconst requestId = opts.requestId(host);\n\t\tif (requestId !== undefined) assertNonEmptyString(requestId, \"requestId\");\n\t\treturn requestId;\n\t}\n\treturn requestIdOf(host, {}, {});\n}\n\nfunction requestIdFromBinding<THost>(\n\thost: THost,\n\tbinding: NestIngressBindingMeta,\n): string | undefined {\n\tif (typeof binding.requestId === \"string\") {\n\t\tassertNonEmptyString(binding.requestId, \"requestId\");\n\t\treturn binding.requestId;\n\t}\n\tif (typeof binding.requestId === \"function\") {\n\t\tconst requestId = binding.requestId(host);\n\t\tif (requestId !== undefined) assertNonEmptyString(requestId, \"requestId\");\n\t\treturn requestId;\n\t}\n\treturn undefined;\n}\n\nfunction bindingPayloadEmitOption<THost>(\n\thost: THost,\n\tbinding: NestIngressBindingMeta,\n): { readonly payload: unknown } | Record<string, never> {\n\treturn binding.payload === undefined ? {} : { payload: binding.payload(host) };\n}\n\nfunction isHttpResponsePayload(value: unknown): value is NestHttpResponsePayload {\n\tif (value === null || typeof value !== \"object\") return false;\n\tconst status = (value as { status?: unknown }).status;\n\tif (!Number.isInteger(status)) return false;\n\tconst headers = (value as { headers?: unknown }).headers;\n\treturn headers === undefined || isStringRecord(headers);\n}\n\nfunction isStringRecord(value: unknown): value is Record<string, string> {\n\tif (value === null || typeof value !== \"object\" || Array.isArray(value)) return false;\n\tfor (const entry of Object.values(value)) if (typeof entry !== \"string\") return false;\n\treturn true;\n}\n\nfunction isHttpReplyBinding(binding: NestBoundaryBindingMeta): binding is NestHttpReplyBindingMeta {\n\treturn binding.direction === \"egress\" && binding.kind === \"http\";\n}\n\nfunction uniqueDefinedStrings(values: readonly (string | undefined)[]): string[] {\n\tconst seen = new Set<string>();\n\tfor (const value of values) {\n\t\tif (value !== undefined) seen.add(value);\n\t}\n\treturn [...seen];\n}\n\nfunction defaultNestHttpHost(\n\tcontext: NestExecutionContextLike,\n\tnextSeq: () => number,\n\tneedsSyntheticRequestId: boolean,\n): unknown | undefined {\n\tconst request = context.switchToHttp?.().getRequest<Record<string, unknown>>();\n\tif (request === undefined || request === null || typeof request !== \"object\") return request;\n\tif (requestIdFromRecord(request) !== undefined) return request;\n\tconst headerId = requestIdFromHeaders(request.headers);\n\tif (headerId !== undefined || needsSyntheticRequestId) {\n\t\treturn { ...request, requestId: headerId ?? `nestjs-request:${nextSeq()}` };\n\t}\n\treturn request;\n}\n\nfunction requestIdFromRecord(record: Record<string, unknown>): string | undefined {\n\tfor (const key of [\"requestId\", \"id\"]) {\n\t\tconst value = record[key];\n\t\tif (typeof value === \"string\" && value.length > 0) return value;\n\t}\n\treturn undefined;\n}\n\nfunction requestIdFromHeaders(headers: unknown): string | undefined {\n\tif (headers === null || typeof headers !== \"object\") return undefined;\n\tfor (const key of [\"x-request-id\", \"x-correlation-id\"]) {\n\t\tconst value = (headers as Record<string, unknown>)[key];\n\t\tconst first = Array.isArray(value) ? value[0] : value;\n\t\tif (typeof first === \"string\" && first.trim().length > 0) return first.trim();\n\t}\n\treturn undefined;\n}\n\nfunction graphIngressBinding<THost, TPayload>(\n\tkind: NestBoundaryKind,\n\tboundary: NestIngressBoundary<THost, TPayload>,\n\topts: NestBoundaryDecoratorOptions<THost, TPayload> & NestFilterDecoratorOptions<THost, TPayload>,\n): GraphMethodDecorator {\n\tif (boundary.kind !== kind) {\n\t\tthrow new Error(`Graph${kind} expected a ${kind} boundary, got ${boundary.kind}`);\n\t}\n\tconst bindingId = opts.bindingId ?? boundary.bindingId;\n\tassertNonEmptyString(bindingId, \"bindingId\");\n\treturn registerMeta(NEST_BOUNDARY_BINDINGS, (methodKey) => ({\n\t\tdirection: \"ingress\" as const,\n\t\tkind,\n\t\tbindingId,\n\t\tmethodKey,\n\t\tboundary: boundary as NestIngressBoundary<unknown, unknown>,\n\t\tpayload: opts.payload as ((host: unknown) => unknown) | undefined,\n\t\trequestId: opts.requestId as string | ((host: unknown) => string | undefined) | undefined,\n\t\torder: opts.order,\n\t\tmode: opts.mode,\n\t\tissueResponse: opts.issueResponse as NestIssueResponse<unknown> | undefined,\n\t\tprotocolError: opts.protocolError as NestProtocolErrorResponse<unknown> | undefined,\n\t}));\n}\n\nfunction graphReplyBinding<TPayload>(\n\tkind: \"ws-ack\" | \"ws-reply\" | \"message-reply\",\n\tnode: Node<NestReplyEnvelope<TPayload>>,\n\topts: { readonly bindingId: string; readonly order?: number },\n\tdecoratorName: string,\n): GraphMethodDecorator {\n\tconst bindingId = opts?.bindingId;\n\tif (typeof bindingId !== \"string\" || bindingId.length === 0) {\n\t\tthrow new Error(`${decoratorName} requires a non-empty bindingId`);\n\t}\n\tconst replyNode = node as Node<NestReplyEnvelope<unknown>>;\n\treturn registerMeta(NEST_BOUNDARY_BINDINGS, (methodKey) => {\n\t\tif (kind === \"ws-ack\") {\n\t\t\treturn {\n\t\t\t\tdirection: \"egress\" as const,\n\t\t\t\tkind,\n\t\t\t\tbindingId,\n\t\t\t\tmethodKey,\n\t\t\t\tackNode: replyNode,\n\t\t\t\torder: opts.order,\n\t\t\t};\n\t\t}\n\t\treturn {\n\t\t\tdirection: \"egress\" as const,\n\t\t\tkind,\n\t\t\tbindingId,\n\t\t\tmethodKey,\n\t\t\treplyNode,\n\t\t\torder: opts.order,\n\t\t};\n\t});\n}\n\nfunction methodKeyForHandler(\n\tctor: DecoratorHostConstructor,\n\thandler: DecoratorBoundMethod,\n): string | symbol | undefined {\n\tfor (const binding of boundaryBindingsFor(ctor)) {\n\t\tconst candidate = methodOnPrototypeChain(ctor, binding.methodKey);\n\t\tif (candidate === handler || String(binding.methodKey) === handler.name)\n\t\t\treturn binding.methodKey;\n\t}\n\treturn undefined;\n}\n\nfunction boundaryBindingsFor(ctor: DecoratorHostConstructor): NestBoundaryBindingMeta[] {\n\tconst bindings: NestBoundaryBindingMeta[] = [];\n\tconst seen = new Set<NestBoundaryBindingMeta>();\n\tlet current: unknown = ctor;\n\twhile (typeof current === \"function\" && current !== Function.prototype) {\n\t\tfor (const binding of NEST_BOUNDARY_BINDINGS.get(current as DecoratorHostConstructor) ?? []) {\n\t\t\tif (seen.has(binding)) continue;\n\t\t\tseen.add(binding);\n\t\t\tbindings.push(binding);\n\t\t}\n\t\tcurrent = Object.getPrototypeOf(current);\n\t}\n\treturn bindings;\n}\n\nfunction sortBoundaryBindings(\n\tbindings: readonly NestBoundaryBindingMeta[],\n): readonly NestBoundaryBindingMeta[] {\n\treturn bindings\n\t\t.map((binding, index) => ({ binding, index }))\n\t\t.sort((a, b) => (a.binding.order ?? 0) - (b.binding.order ?? 0) || a.index - b.index)\n\t\t.map(({ binding }) => binding);\n}\n\nfunction methodOnPrototypeChain(\n\tctor: DecoratorHostConstructor,\n\tmethodKey: string | symbol,\n): unknown {\n\tlet proto: unknown = ctor.prototype;\n\twhile (proto !== null && typeof proto === \"object\") {\n\t\tif (Object.hasOwn(proto, methodKey)) {\n\t\t\treturn (proto as Record<string | symbol, unknown>)[methodKey];\n\t\t}\n\t\tproto = Object.getPrototypeOf(proto);\n\t}\n\treturn undefined;\n}\n\nfunction requestIdOf<THost, TPayload>(\n\thost: THost,\n\topts: NestIngressOptions<THost, TPayload>,\n\temitOpts: NestIngressEmitOptions<TPayload>,\n): string | undefined {\n\tconst fromEmit = emitOpts.requestId;\n\tif (fromEmit !== undefined) {\n\t\tassertNonEmptyString(fromEmit, \"requestId\");\n\t\treturn fromEmit;\n\t}\n\tif (typeof opts.requestId === \"string\") {\n\t\tassertNonEmptyString(opts.requestId, \"requestId\");\n\t\treturn opts.requestId;\n\t}\n\tif (typeof opts.requestId === \"function\") {\n\t\tconst requestId = opts.requestId(host);\n\t\tif (requestId !== undefined) assertNonEmptyString(requestId, \"requestId\");\n\t\treturn requestId;\n\t}\n\tconst record = host as { requestId?: unknown; id?: unknown };\n\tif (typeof record?.requestId === \"string\" && record.requestId.length > 0) return record.requestId;\n\tif (typeof record?.id === \"string\" && record.id.length > 0) return record.id;\n\tif (emitOpts.requireRequestId ?? opts.requireRequestId ?? false) {\n\t\tthrow new Error(\"Nest boundary ingress requires a stable requestId\");\n\t}\n\treturn undefined;\n}\n\nfunction validateEnvelope(value: unknown, maxPayloadBytes: number): string | undefined {\n\ttry {\n\t\tassertGraphVisibleData(value, \"NestBoundaryEnvelope\", maxPayloadBytes);\n\t} catch (error) {\n\t\treturn error instanceof Error ? error.message : \"egress envelope must be data-only material\";\n\t}\n\tif (value === null || typeof value !== \"object\") return \"egress DATA is not an envelope object\";\n\tconst envelope = value as Partial<NestBoundaryEnvelope>;\n\tif (typeof envelope.requestId !== \"string\" || envelope.requestId.length === 0) {\n\t\treturn \"egress envelope requestId must be a non-empty string\";\n\t}\n\tif (typeof envelope.bindingId !== \"string\" || envelope.bindingId.length === 0) {\n\t\treturn \"egress envelope bindingId must be a non-empty string\";\n\t}\n\ttry {\n\t\tparseEnvelopeVersion(envelope.version, \"egress envelope version\");\n\t} catch {\n\t\treturn `egress envelope version must be ${NEST_BOUNDARY_ENVELOPE_VERSION}`;\n\t}\n\treturn undefined;\n}\n\nfunction malformedCorrelation(\n\tvalue: unknown,\n\tscopedBindingId: string | undefined,\n): { readonly requestId: string; readonly bindingId: string } | undefined {\n\tif (value === null || typeof value !== \"object\") return undefined;\n\tconst requestId = (value as { readonly requestId?: unknown }).requestId;\n\tconst bindingId = (value as { readonly bindingId?: unknown }).bindingId;\n\tif (typeof requestId !== \"string\" || requestId.length === 0) return undefined;\n\tif (typeof bindingId !== \"string\" || bindingId.length === 0) return undefined;\n\tif (scopedBindingId !== undefined && bindingId !== scopedBindingId) return undefined;\n\treturn { requestId, bindingId };\n}\n\nfunction parseEnvelopeVersion(value: unknown, label: string): number {\n\tif (value !== NEST_BOUNDARY_ENVELOPE_VERSION) {\n\t\tthrow new Error(`${label} must be ${NEST_BOUNDARY_ENVELOPE_VERSION}`);\n\t}\n\treturn value;\n}\n\nfunction assertNonEmptyString(value: string, label: string): void {\n\tif (value.length === 0) throw new Error(`${label} must be a non-empty string`);\n}\n\nfunction optionalStringField<K extends \"requestId\" | \"bindingId\" | \"expectedBindingId\">(\n\tkey: K,\n\tvalue: string | undefined,\n): Record<K, string> | Record<string, never> {\n\treturn value === undefined ? {} : ({ [key]: value } as Record<K, string>);\n}\n\nfunction optionalDiagnosticError(\n\terror: unknown,\n): { readonly error: NestDiagnosticErrorPayload } | Record<string, never> {\n\tconst summarized = summarizeDiagnosticError(error);\n\treturn summarized === undefined ? {} : { error: summarized };\n}\n\nfunction summarizeDiagnosticError(error: unknown): NestDiagnosticErrorPayload | undefined {\n\tif (error === undefined) return undefined;\n\tif (error instanceof Error) {\n\t\treturn {\n\t\t\t...optionalDiagnosticName(safeDiagnosticString(() => error.name)),\n\t\t\tmessage: safeDiagnosticString(() => error.message) ?? \"diagnostic error\",\n\t\t};\n\t}\n\tif (typeof error === \"string\") return { message: error };\n\tif (typeof error === \"number\" || typeof error === \"boolean\" || typeof error === \"bigint\") {\n\t\treturn { message: String(error) };\n\t}\n\tif (typeof error === \"symbol\") return { message: error.description ?? \"symbol\" };\n\tif (typeof error === \"function\") return { message: \"opaque diagnostic function\" };\n\tif (error !== null && typeof error === \"object\") {\n\t\tconst record = error as { readonly name?: unknown; readonly message?: unknown };\n\t\tconst message = safeDiagnosticString(() => record.message);\n\t\tif (message !== undefined) {\n\t\t\treturn {\n\t\t\t\t...optionalDiagnosticName(safeDiagnosticString(() => record.name)),\n\t\t\t\tmessage,\n\t\t\t};\n\t\t}\n\t\treturn { message: \"opaque diagnostic error\" };\n\t}\n\treturn { message: String(error) };\n}\n\nfunction safeDiagnosticString(read: () => unknown): string | undefined {\n\ttry {\n\t\tconst value = read();\n\t\treturn typeof value === \"string\" ? value : undefined;\n\t} catch {\n\t\treturn undefined;\n\t}\n}\n\nfunction optionalDiagnosticName(\n\tname: string | undefined,\n): { readonly name: string } | Record<string, never> {\n\treturn name === undefined || name.length === 0 ? {} : { name };\n}\n\nfunction payloadByteLimit(value: number | undefined): number {\n\tif (value === undefined) return NEST_BOUNDARY_PAYLOAD_MAX_BYTES;\n\tif (!Number.isSafeInteger(value) || value < 1) {\n\t\tthrow new Error(\"Nest boundary maxPayloadBytes must be a positive safe integer\");\n\t}\n\treturn value;\n}\n\nfunction diagnosticsRetainedLimit(value: number | undefined): number {\n\tif (value === undefined) return NEST_HTTP_DIAGNOSTICS_MAX_RETAINED;\n\tif (!Number.isSafeInteger(value) || value < 0) {\n\t\tthrow new Error(\"toNestHttp maxDiagnostics must be a non-negative safe integer\");\n\t}\n\treturn value;\n}\n\nfunction pushDiagnostic(\n\tdiagnostics: NestBoundaryDiagnostic[],\n\tdiagnostic: NestBoundaryDiagnostic,\n\tmaxDiagnostics: number,\n): void {\n\tif (maxDiagnostics === 0) return;\n\tdiagnostics.push(diagnostic);\n\tif (diagnostics.length > maxDiagnostics)\n\t\tdiagnostics.splice(0, diagnostics.length - maxDiagnostics);\n}\n\nfunction assertGraphVisibleData(\n\tvalue: unknown,\n\tpath: string,\n\tmaxPayloadBytes: number,\n\tseen = new WeakSet<object>(),\n): void {\n\tif (value === undefined) {\n\t\tthrow new TypeError(`${path} cannot be undefined; undefined is SENTINEL/no DATA`);\n\t}\n\tif (value === null) return;\n\tconst type = typeof value;\n\tif (type === \"string\" || type === \"boolean\") return;\n\tif (type === \"number\") {\n\t\tif (!Number.isFinite(value)) throw new TypeError(`${path} number must be finite`);\n\t\treturn;\n\t}\n\tif (type === \"function\" || type === \"symbol\" || type === \"bigint\") {\n\t\tthrow new TypeError(`${path} must be data-only; found ${type}`);\n\t}\n\tif (type !== \"object\") return;\n\tif (seen.has(value as object)) throw new TypeError(`${path} must be acyclic data`);\n\tseen.add(value as object);\n\tif (Array.isArray(value)) {\n\t\ttry {\n\t\t\tfor (let i = 0; i < value.length; i += 1) {\n\t\t\t\tconst descriptor = Object.getOwnPropertyDescriptor(value, i);\n\t\t\t\tif (descriptor === undefined) {\n\t\t\t\t\tthrow new TypeError(`${path}[${i}] cannot be a sparse array hole`);\n\t\t\t\t}\n\t\t\t\tif (!descriptor.enumerable || !(\"value\" in descriptor)) {\n\t\t\t\t\tthrow new TypeError(`${path}[${i}] must be enumerable plain data`);\n\t\t\t\t}\n\t\t\t\tassertGraphVisibleData(descriptor.value, `${path}[${i}]`, maxPayloadBytes, seen);\n\t\t\t}\n\t\t\tfor (const key of Reflect.ownKeys(value)) {\n\t\t\t\tif (key === \"length\") continue;\n\t\t\t\tif (typeof key === \"symbol\" || !/^(0|[1-9]\\d*)$/.test(key)) {\n\t\t\t\t\tthrow new TypeError(`${path} arrays must not carry hidden or extra properties`);\n\t\t\t\t}\n\t\t\t}\n\t\t\tassertPayloadSize(value, path, maxPayloadBytes);\n\t\t} finally {\n\t\t\tseen.delete(value as object);\n\t\t}\n\t\treturn;\n\t}\n\tconst proto = Object.getPrototypeOf(value);\n\tif (proto !== Object.prototype && proto !== null) {\n\t\tthrow new TypeError(`${path} must be a plain data object or array`);\n\t}\n\ttry {\n\t\tfor (const key of Reflect.ownKeys(value)) {\n\t\t\tif (typeof key === \"symbol\") throw new TypeError(`${path} must not carry symbol keys`);\n\t\t\tconst descriptor = Object.getOwnPropertyDescriptor(value, key);\n\t\t\tif (descriptor === undefined) continue;\n\t\t\tif (!descriptor.enumerable || !(\"value\" in descriptor)) {\n\t\t\t\tthrow new TypeError(`${path}.${key} must be enumerable plain data`);\n\t\t\t}\n\t\t\tassertGraphVisibleData(descriptor.value, `${path}.${key}`, maxPayloadBytes, seen);\n\t\t}\n\t\tassertPayloadSize(value, path, maxPayloadBytes);\n\t} finally {\n\t\tseen.delete(value as object);\n\t}\n}\n\nfunction assertPayloadSize(value: unknown, path: string, maxPayloadBytes: number): void {\n\tconst serialized = JSON.stringify(value);\n\tif (serialized !== undefined && utf8ByteLength(serialized) > maxPayloadBytes) {\n\t\tthrow new TypeError(`${path} exceeds ${maxPayloadBytes} bytes`);\n\t}\n}\n\nfunction utf8ByteLength(value: string): number {\n\tlet bytes = 0;\n\tfor (let i = 0; i < value.length; i += 1) {\n\t\tconst code = value.charCodeAt(i);\n\t\tif (code < 0x80) {\n\t\t\tbytes += 1;\n\t\t} else if (code < 0x800) {\n\t\t\tbytes += 2;\n\t\t} else if (code >= 0xd800 && code <= 0xdbff && i + 1 < value.length) {\n\t\t\tconst next = value.charCodeAt(i + 1);\n\t\t\tif (next >= 0xdc00 && next <= 0xdfff) {\n\t\t\t\tbytes += 4;\n\t\t\t\ti += 1;\n\t\t\t} else {\n\t\t\t\tbytes += 3;\n\t\t\t}\n\t\t} else {\n\t\t\tbytes += 3;\n\t\t}\n\t}\n\treturn bytes;\n}\n\nfunction sameMeta<T>(a: T, b: T): boolean {\n\tconst left = a as Record<string | symbol, unknown>;\n\tconst right = b as Record<string | symbol, unknown>;\n\tconst keys = Reflect.ownKeys(left);\n\tif (keys.length !== Reflect.ownKeys(right).length) return false;\n\tfor (const key of keys) {\n\t\tif (!Object.is(left[key], right[key])) return false;\n\t}\n\treturn true;\n}\n\nfunction pushUniqueMeta<T>(\n\tregistry: WeakMap<DecoratorHostConstructor, T[]>,\n\tctor: DecoratorHostConstructor,\n\titem: T,\n): void {\n\tconst existing = registry.get(ctor) ?? [];\n\tif (existing.some((current) => sameMeta(current, item))) return;\n\tregistry.set(ctor, [...existing, item]);\n}\n\nfunction registerMeta<T>(\n\tregistry: WeakMap<DecoratorHostConstructor, T[]>,\n\tmeta: (methodKey: string | symbol) => T,\n): GraphMethodDecorator {\n\treturn ((targetOrValue: object, contextOrKey: ClassMethodDecoratorContext | string | symbol) => {\n\t\tif (typeof contextOrKey === \"object\" && contextOrKey !== null) {\n\t\t\tconst methodKey = contextOrKey.name;\n\t\t\tcontextOrKey.addInitializer(function (this: unknown) {\n\t\t\t\tconst ctor = (this as { constructor: DecoratorHostConstructor }).constructor;\n\t\t\t\tpushUniqueMeta(registry, ctor, meta(methodKey));\n\t\t\t});\n\t\t\treturn;\n\t\t}\n\n\t\tconst ctor = (targetOrValue as { constructor: DecoratorHostConstructor }).constructor;\n\t\tpushUniqueMeta(registry, ctor, meta(contextOrKey));\n\t}) as GraphMethodDecorator;\n}\n\n/** Register a method as a DATA-event handler for a graph observe path. */\nexport function OnGraphEvent(nodeName: string): GraphMethodDecorator {\n\treturn registerMeta(EVENT_HANDLERS, (methodKey) => ({ nodeName, methodKey }));\n}\n\n/** Register fixed-interval metadata for a user-land NestJS scheduler bridge. */\nexport function GraphInterval(ms: number): GraphMethodDecorator {\n\treturn registerMeta(INTERVAL_HANDLERS, (methodKey) => ({ ms, methodKey }));\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;;;ACcO,IAAM,iCAAiC;AACvC,IAAM,kCAAkC,KAAK;AAC7C,IAAM,qCAAqC;AAuX3C,IAAM,yBAAyB,oBAAI,QAGxC;AAqGK,SAAS,gBACf,OACA,OAA4C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CAAC,GAAG,IAAI;AAChB;","names":["pendingKey","entry","ctor"]}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { CustomTransportStrategy } from '@nestjs/microservices';
|
|
2
|
+
import { DecoratorHostConstructor, NestGraphRunOptions, NestBoundaryDiagnostic, NestDiagnosticIngressBoundary, NestProviderBinding } from '../nestjs.cjs';
|
|
3
|
+
export { GraphMessage, GraphMessageReply, NestBoundaryEnvelope, NestIngressBoundary, NestIngressEmitOptions, NestIngressOptions, NestReplyEnvelope, fromNestMessage } from '../nestjs.cjs';
|
|
4
|
+
import '../../data/index.cjs';
|
|
5
|
+
import '../../graph-CWK3HLPB.cjs';
|
|
6
|
+
import '../../core/index.cjs';
|
|
7
|
+
import '../../types-BS6CyR-x.cjs';
|
|
8
|
+
import '../../messages-CAzUPPJM.cjs';
|
|
9
|
+
import '../../codec-BB7p8fJc.cjs';
|
|
10
|
+
import '../../describe-CQRrkv-Q.cjs';
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* NestJS microservice/message native phase bridge (D488).
|
|
14
|
+
*
|
|
15
|
+
* This focused subpath may import `@nestjs/microservices`; the dependency-light
|
|
16
|
+
* structural layer and HTTP native bridge stay free of that optional peer.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/** D488 provider token for the focused Nest microservice/message native bridge. */
|
|
20
|
+
declare const GRAPHREFLY_NEST_MESSAGE_BRIDGE: unique symbol;
|
|
21
|
+
/** Options for the D488 Nest message bridge; transport contexts stay host-private. */
|
|
22
|
+
interface GraphMessageBridgeOptions<THost = unknown> extends NestGraphRunOptions<THost> {
|
|
23
|
+
readonly diagnosticBoundary?: NestDiagnosticIngressBoundary;
|
|
24
|
+
readonly timeoutMs?: number;
|
|
25
|
+
readonly maxDiagnostics?: number;
|
|
26
|
+
}
|
|
27
|
+
/** D495 focused microservice/message provider bundle options. */
|
|
28
|
+
interface GraphMessageProviderBundleOptions<THost = unknown> {
|
|
29
|
+
readonly bridge?: GraphMessageBridgeOptions<THost> | false;
|
|
30
|
+
}
|
|
31
|
+
/** Explicit Nest message-pattern phase bridge over `GraphMessage` and `GraphMessageReply` metadata. */
|
|
32
|
+
interface GraphMessageBridge<THost = unknown> extends Pick<CustomTransportStrategy, "close"> {
|
|
33
|
+
handleMessage(target: DecoratorHostConstructor | object, methodKey: string | symbol, host: THost, opts?: NestGraphRunOptions<THost>): Promise<unknown> | undefined;
|
|
34
|
+
onModuleDestroy(): void;
|
|
35
|
+
diagnostics(): readonly NestBoundaryDiagnostic[];
|
|
36
|
+
dispose(): void;
|
|
37
|
+
}
|
|
38
|
+
/** Build a dependency-light Nest provider for the focused message bridge token. */
|
|
39
|
+
declare function provideGraphMessageBridge<THost = unknown>(opts?: GraphMessageBridgeOptions<THost>): NestProviderBinding<GraphMessageBridge<THost>>;
|
|
40
|
+
/** Build the D495 focused message provider bundle without adding a router or event bus. */
|
|
41
|
+
declare function provideGraphMessageProviders<THost = unknown>(opts?: GraphMessageProviderBundleOptions<THost>): NestProviderBinding<GraphMessageBridge<THost>>[];
|
|
42
|
+
/** Create a host-private message bridge instance without adding a router or event bus. */
|
|
43
|
+
declare function createGraphMessageBridge<THost = unknown>(opts?: GraphMessageBridgeOptions<THost>): GraphMessageBridge<THost>;
|
|
44
|
+
|
|
45
|
+
export { GRAPHREFLY_NEST_MESSAGE_BRIDGE, type GraphMessageBridge, type GraphMessageBridgeOptions, type GraphMessageProviderBundleOptions, createGraphMessageBridge, provideGraphMessageBridge, provideGraphMessageProviders };
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
import { CustomTransportStrategy } from '@nestjs/microservices';
|
|
2
|
+
import { DecoratorHostConstructor, NestGraphRunOptions, NestBoundaryDiagnostic, NestDiagnosticIngressBoundary, NestProviderBinding } from '../nestjs.js';
|
|
3
|
+
export { GraphMessage, GraphMessageReply, NestBoundaryEnvelope, NestIngressBoundary, NestIngressEmitOptions, NestIngressOptions, NestReplyEnvelope, fromNestMessage } from '../nestjs.js';
|
|
4
|
+
import '../../data/index.js';
|
|
5
|
+
import '../../graph-ho5sotHP.js';
|
|
6
|
+
import '../../core/index.js';
|
|
7
|
+
import '../../types-C9NOgNJw.js';
|
|
8
|
+
import '../../messages-CAzUPPJM.js';
|
|
9
|
+
import '../../codec-BB7p8fJc.js';
|
|
10
|
+
import '../../describe-B_A5fbXH.js';
|
|
11
|
+
|
|
12
|
+
/**
|
|
13
|
+
* NestJS microservice/message native phase bridge (D488).
|
|
14
|
+
*
|
|
15
|
+
* This focused subpath may import `@nestjs/microservices`; the dependency-light
|
|
16
|
+
* structural layer and HTTP native bridge stay free of that optional peer.
|
|
17
|
+
*/
|
|
18
|
+
|
|
19
|
+
/** D488 provider token for the focused Nest microservice/message native bridge. */
|
|
20
|
+
declare const GRAPHREFLY_NEST_MESSAGE_BRIDGE: unique symbol;
|
|
21
|
+
/** Options for the D488 Nest message bridge; transport contexts stay host-private. */
|
|
22
|
+
interface GraphMessageBridgeOptions<THost = unknown> extends NestGraphRunOptions<THost> {
|
|
23
|
+
readonly diagnosticBoundary?: NestDiagnosticIngressBoundary;
|
|
24
|
+
readonly timeoutMs?: number;
|
|
25
|
+
readonly maxDiagnostics?: number;
|
|
26
|
+
}
|
|
27
|
+
/** D495 focused microservice/message provider bundle options. */
|
|
28
|
+
interface GraphMessageProviderBundleOptions<THost = unknown> {
|
|
29
|
+
readonly bridge?: GraphMessageBridgeOptions<THost> | false;
|
|
30
|
+
}
|
|
31
|
+
/** Explicit Nest message-pattern phase bridge over `GraphMessage` and `GraphMessageReply` metadata. */
|
|
32
|
+
interface GraphMessageBridge<THost = unknown> extends Pick<CustomTransportStrategy, "close"> {
|
|
33
|
+
handleMessage(target: DecoratorHostConstructor | object, methodKey: string | symbol, host: THost, opts?: NestGraphRunOptions<THost>): Promise<unknown> | undefined;
|
|
34
|
+
onModuleDestroy(): void;
|
|
35
|
+
diagnostics(): readonly NestBoundaryDiagnostic[];
|
|
36
|
+
dispose(): void;
|
|
37
|
+
}
|
|
38
|
+
/** Build a dependency-light Nest provider for the focused message bridge token. */
|
|
39
|
+
declare function provideGraphMessageBridge<THost = unknown>(opts?: GraphMessageBridgeOptions<THost>): NestProviderBinding<GraphMessageBridge<THost>>;
|
|
40
|
+
/** Build the D495 focused message provider bundle without adding a router or event bus. */
|
|
41
|
+
declare function provideGraphMessageProviders<THost = unknown>(opts?: GraphMessageProviderBundleOptions<THost>): NestProviderBinding<GraphMessageBridge<THost>>[];
|
|
42
|
+
/** Create a host-private message bridge instance without adding a router or event bus. */
|
|
43
|
+
declare function createGraphMessageBridge<THost = unknown>(opts?: GraphMessageBridgeOptions<THost>): GraphMessageBridge<THost>;
|
|
44
|
+
|
|
45
|
+
export { GRAPHREFLY_NEST_MESSAGE_BRIDGE, type GraphMessageBridge, type GraphMessageBridgeOptions, type GraphMessageProviderBundleOptions, createGraphMessageBridge, provideGraphMessageBridge, provideGraphMessageProviders };
|
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
import {
|
|
2
|
+
GraphMessage,
|
|
3
|
+
GraphMessageReply,
|
|
4
|
+
bindingEmitOptions,
|
|
5
|
+
bindingRequestId,
|
|
6
|
+
fromNestMessage,
|
|
7
|
+
getNestBoundaryBindings,
|
|
8
|
+
sanitizeNestDiagnostic,
|
|
9
|
+
toNestHttp
|
|
10
|
+
} from "../../chunk-MQEQMS7B.js";
|
|
11
|
+
import "../../chunk-DGUM43GV.js";
|
|
12
|
+
|
|
13
|
+
// src/adapters/nestjs/microservices.ts
|
|
14
|
+
var GRAPHREFLY_NEST_MESSAGE_BRIDGE = /* @__PURE__ */ Symbol.for("graphrefly:nest:message-bridge");
|
|
15
|
+
function provideGraphMessageBridge(opts = {}) {
|
|
16
|
+
return { provide: GRAPHREFLY_NEST_MESSAGE_BRIDGE, useValue: createGraphMessageBridge(opts) };
|
|
17
|
+
}
|
|
18
|
+
function provideGraphMessageProviders(opts = {}) {
|
|
19
|
+
return opts.bridge === false ? [] : [provideGraphMessageBridge(opts.bridge ?? {})];
|
|
20
|
+
}
|
|
21
|
+
function createGraphMessageBridge(opts = {}) {
|
|
22
|
+
return new GraphMessageBridgeImpl(opts);
|
|
23
|
+
}
|
|
24
|
+
var GraphMessageBridgeImpl = class {
|
|
25
|
+
constructor(opts) {
|
|
26
|
+
this.opts = opts;
|
|
27
|
+
}
|
|
28
|
+
boundaries = /* @__PURE__ */ new WeakMap();
|
|
29
|
+
disposable = /* @__PURE__ */ new Set();
|
|
30
|
+
localDiagnostics = [];
|
|
31
|
+
active = true;
|
|
32
|
+
close() {
|
|
33
|
+
this.dispose();
|
|
34
|
+
}
|
|
35
|
+
onModuleDestroy() {
|
|
36
|
+
this.dispose();
|
|
37
|
+
}
|
|
38
|
+
handleMessage(target, methodKey, host, runOpts = {}) {
|
|
39
|
+
if (!this.active) throw new Error("GraphMessage native bridge is disposed");
|
|
40
|
+
const bindings = getNestBoundaryBindings(target, methodKey);
|
|
41
|
+
const ingress = bindings.filter(isMessageIngress);
|
|
42
|
+
if (ingress.length === 0) return void 0;
|
|
43
|
+
const replies = bindings.filter(isMessageReply);
|
|
44
|
+
const needsRequestId = replies.length > 0;
|
|
45
|
+
for (const binding of ingress) assertExplicitNativePayload(binding, "GraphMessage");
|
|
46
|
+
const ingressEmits = ingress.map((binding) => ({
|
|
47
|
+
binding,
|
|
48
|
+
requestId: bindingRequestId(host, binding, runOpts.requestId ?? this.opts.requestId)
|
|
49
|
+
}));
|
|
50
|
+
if (needsRequestId && ingressEmits.some((entry) => entry.requestId === void 0)) {
|
|
51
|
+
throw new Error("GraphMessage native bridge requires a stable requestId for reply egress");
|
|
52
|
+
}
|
|
53
|
+
const requestIds = uniqueDefinedStrings(ingressEmits.map((entry) => entry.requestId));
|
|
54
|
+
const cleanups = [];
|
|
55
|
+
let timeout;
|
|
56
|
+
let settled = false;
|
|
57
|
+
let resolvePromise;
|
|
58
|
+
let rejectPromise;
|
|
59
|
+
let cleaned = false;
|
|
60
|
+
const cleanupAll = () => {
|
|
61
|
+
if (cleaned) return;
|
|
62
|
+
cleaned = true;
|
|
63
|
+
for (const cleanup of cleanups) cleanup();
|
|
64
|
+
this.clearTimeout(timeout);
|
|
65
|
+
};
|
|
66
|
+
const handle = {
|
|
67
|
+
resolve(payload) {
|
|
68
|
+
if (settled) return;
|
|
69
|
+
settled = true;
|
|
70
|
+
resolvePromise?.(payload);
|
|
71
|
+
},
|
|
72
|
+
reject(error) {
|
|
73
|
+
if (settled) return;
|
|
74
|
+
settled = true;
|
|
75
|
+
rejectPromise?.(error);
|
|
76
|
+
}
|
|
77
|
+
};
|
|
78
|
+
const promise = replies.length === 0 ? void 0 : new Promise((resolve, reject) => {
|
|
79
|
+
resolvePromise = resolve;
|
|
80
|
+
rejectPromise = reject;
|
|
81
|
+
});
|
|
82
|
+
if (promise !== void 0) {
|
|
83
|
+
try {
|
|
84
|
+
for (const requestId of requestIds) {
|
|
85
|
+
for (const reply of replies) {
|
|
86
|
+
cleanups.push(
|
|
87
|
+
this.boundaryFor(reply).attach({
|
|
88
|
+
requestId,
|
|
89
|
+
bindingId: reply.bindingId,
|
|
90
|
+
handle
|
|
91
|
+
})
|
|
92
|
+
);
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
} catch (error) {
|
|
96
|
+
cleanupAll();
|
|
97
|
+
handle.reject(error);
|
|
98
|
+
return promise;
|
|
99
|
+
}
|
|
100
|
+
if (settled) {
|
|
101
|
+
cleanupAll();
|
|
102
|
+
return promise;
|
|
103
|
+
}
|
|
104
|
+
if (this.opts.timeoutMs !== void 0) {
|
|
105
|
+
timeout = setTimeout(() => {
|
|
106
|
+
cleanupAll();
|
|
107
|
+
const error = new Error(
|
|
108
|
+
`GraphMessage native bridge timed out waiting for ${requestIds[0]}`
|
|
109
|
+
);
|
|
110
|
+
this.diagnose({
|
|
111
|
+
kind: "timeout",
|
|
112
|
+
requestId: requestIds[0],
|
|
113
|
+
message: error.message,
|
|
114
|
+
error
|
|
115
|
+
});
|
|
116
|
+
handle.reject(error);
|
|
117
|
+
}, this.opts.timeoutMs);
|
|
118
|
+
}
|
|
119
|
+
}
|
|
120
|
+
try {
|
|
121
|
+
for (const { binding, requestId } of ingressEmits) {
|
|
122
|
+
binding.boundary.emit(host, {
|
|
123
|
+
...bindingEmitOptions(host, binding, requestId),
|
|
124
|
+
requireRequestId: needsRequestId
|
|
125
|
+
});
|
|
126
|
+
}
|
|
127
|
+
} catch (error) {
|
|
128
|
+
cleanupAll();
|
|
129
|
+
throw error;
|
|
130
|
+
}
|
|
131
|
+
return promise?.finally(() => {
|
|
132
|
+
cleanupAll();
|
|
133
|
+
});
|
|
134
|
+
}
|
|
135
|
+
diagnostics() {
|
|
136
|
+
return [
|
|
137
|
+
...this.localDiagnostics,
|
|
138
|
+
...[...this.disposable].flatMap((boundary) => boundary.diagnostics())
|
|
139
|
+
];
|
|
140
|
+
}
|
|
141
|
+
dispose() {
|
|
142
|
+
if (!this.active) return;
|
|
143
|
+
this.active = false;
|
|
144
|
+
for (const boundary of this.disposable) boundary.dispose();
|
|
145
|
+
}
|
|
146
|
+
boundaryFor(binding) {
|
|
147
|
+
let byBinding = this.boundaries.get(binding.replyNode);
|
|
148
|
+
if (byBinding === void 0) {
|
|
149
|
+
byBinding = /* @__PURE__ */ new Map();
|
|
150
|
+
this.boundaries.set(binding.replyNode, byBinding);
|
|
151
|
+
}
|
|
152
|
+
const existing = byBinding.get(binding.bindingId);
|
|
153
|
+
if (existing !== void 0) return existing;
|
|
154
|
+
const boundary = toNestHttp(binding.replyNode, {
|
|
155
|
+
bindingId: binding.bindingId,
|
|
156
|
+
diagnosticBoundary: this.opts.diagnosticBoundary,
|
|
157
|
+
diagnosticPhase: "message",
|
|
158
|
+
name: "nestjs.message-reply",
|
|
159
|
+
maxDiagnostics: this.opts.maxDiagnostics
|
|
160
|
+
});
|
|
161
|
+
byBinding.set(binding.bindingId, boundary);
|
|
162
|
+
this.disposable.add(boundary);
|
|
163
|
+
return boundary;
|
|
164
|
+
}
|
|
165
|
+
diagnose(diagnostic) {
|
|
166
|
+
this.localDiagnostics.push(diagnostic);
|
|
167
|
+
try {
|
|
168
|
+
const phase = diagnostic.phase ?? "message";
|
|
169
|
+
const payload = sanitizeNestDiagnostic({ ...diagnostic, phase }, phase);
|
|
170
|
+
this.opts.diagnosticBoundary?.emit(payload, { payload });
|
|
171
|
+
} catch {
|
|
172
|
+
}
|
|
173
|
+
if (this.opts.maxDiagnostics !== void 0 && this.localDiagnostics.length > this.opts.maxDiagnostics) {
|
|
174
|
+
this.localDiagnostics.splice(0, this.localDiagnostics.length - this.opts.maxDiagnostics);
|
|
175
|
+
}
|
|
176
|
+
}
|
|
177
|
+
clearTimeout(timeout) {
|
|
178
|
+
if (timeout !== void 0) clearTimeout(timeout);
|
|
179
|
+
}
|
|
180
|
+
};
|
|
181
|
+
function isMessageIngress(binding) {
|
|
182
|
+
return binding.direction === "ingress" && binding.kind === "message";
|
|
183
|
+
}
|
|
184
|
+
function isMessageReply(binding) {
|
|
185
|
+
return binding.direction === "egress" && binding.kind === "message-reply";
|
|
186
|
+
}
|
|
187
|
+
function assertExplicitNativePayload(binding, label) {
|
|
188
|
+
if (binding.payload === void 0) {
|
|
189
|
+
throw new Error(`${label} native bridge requires an explicit payload selector`);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
function uniqueDefinedStrings(values) {
|
|
193
|
+
const seen = /* @__PURE__ */ new Set();
|
|
194
|
+
for (const value of values) if (value !== void 0) seen.add(value);
|
|
195
|
+
return [...seen];
|
|
196
|
+
}
|
|
197
|
+
export {
|
|
198
|
+
GRAPHREFLY_NEST_MESSAGE_BRIDGE,
|
|
199
|
+
GraphMessage,
|
|
200
|
+
GraphMessageReply,
|
|
201
|
+
createGraphMessageBridge,
|
|
202
|
+
fromNestMessage,
|
|
203
|
+
provideGraphMessageBridge,
|
|
204
|
+
provideGraphMessageProviders
|
|
205
|
+
};
|
|
206
|
+
//# sourceMappingURL=microservices.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/adapters/nestjs/microservices.ts"],"sourcesContent":["/**\n * NestJS microservice/message native phase bridge (D488).\n *\n * This focused subpath may import `@nestjs/microservices`; the dependency-light\n * structural layer and HTTP native bridge stay free of that optional peer.\n */\n\nimport type { CustomTransportStrategy } from \"@nestjs/microservices\";\nimport {\n\tbindingEmitOptions,\n\tbindingRequestId,\n\ttype DecoratorHostConstructor,\n\tfromNestMessage,\n\tGraphMessage,\n\tGraphMessageReply,\n\tgetNestBoundaryBindings,\n\ttype NestBoundaryBindingMeta,\n\ttype NestBoundaryDiagnostic,\n\ttype NestBoundaryEnvelope,\n\ttype NestDiagnosticIngressBoundary,\n\ttype NestGraphRunOptions,\n\ttype NestIngressBindingMeta,\n\ttype NestIngressBoundary,\n\ttype NestIngressEmitOptions,\n\ttype NestIngressOptions,\n\ttype NestMessageReplyBindingMeta,\n\ttype NestProviderBinding,\n\ttype NestReplyEnvelope,\n\ttype NestReplyResponseHandle,\n\tsanitizeNestDiagnostic,\n\ttoNestHttp,\n} from \"../nestjs.js\";\n\n/** D488 provider token for the focused Nest microservice/message native bridge. */\nexport const GRAPHREFLY_NEST_MESSAGE_BRIDGE = Symbol.for(\"graphrefly:nest:message-bridge\");\n\n/** Options for the D488 Nest message bridge; transport contexts stay host-private. */\nexport interface GraphMessageBridgeOptions<THost = unknown> extends NestGraphRunOptions<THost> {\n\treadonly diagnosticBoundary?: NestDiagnosticIngressBoundary;\n\treadonly timeoutMs?: number;\n\treadonly maxDiagnostics?: number;\n}\n\n/** D495 focused microservice/message provider bundle options. */\nexport interface GraphMessageProviderBundleOptions<THost = unknown> {\n\treadonly bridge?: GraphMessageBridgeOptions<THost> | false;\n}\n\n/** Explicit Nest message-pattern phase bridge over `GraphMessage` and `GraphMessageReply` metadata. */\nexport interface GraphMessageBridge<THost = unknown>\n\textends Pick<CustomTransportStrategy, \"close\"> {\n\thandleMessage(\n\t\ttarget: DecoratorHostConstructor | object,\n\t\tmethodKey: string | symbol,\n\t\thost: THost,\n\t\topts?: NestGraphRunOptions<THost>,\n\t): Promise<unknown> | undefined;\n\tonModuleDestroy(): void;\n\tdiagnostics(): readonly NestBoundaryDiagnostic[];\n\tdispose(): void;\n}\n\ntype MessageBoundary = ReturnType<typeof toNestHttp<unknown>>;\n\n/** Build a dependency-light Nest provider for the focused message bridge token. */\nexport function provideGraphMessageBridge<THost = unknown>(\n\topts: GraphMessageBridgeOptions<THost> = {},\n): NestProviderBinding<GraphMessageBridge<THost>> {\n\treturn { provide: GRAPHREFLY_NEST_MESSAGE_BRIDGE, useValue: createGraphMessageBridge(opts) };\n}\n\n/** Build the D495 focused message provider bundle without adding a router or event bus. */\nexport function provideGraphMessageProviders<THost = unknown>(\n\topts: GraphMessageProviderBundleOptions<THost> = {},\n): NestProviderBinding<GraphMessageBridge<THost>>[] {\n\treturn opts.bridge === false ? [] : [provideGraphMessageBridge(opts.bridge ?? {})];\n}\n\n/** Create a host-private message bridge instance without adding a router or event bus. */\nexport function createGraphMessageBridge<THost = unknown>(\n\topts: GraphMessageBridgeOptions<THost> = {},\n): GraphMessageBridge<THost> {\n\treturn new GraphMessageBridgeImpl(opts);\n}\n\nclass GraphMessageBridgeImpl<THost> implements GraphMessageBridge<THost> {\n\tprivate readonly boundaries = new WeakMap<object, Map<string, MessageBoundary>>();\n\tprivate readonly disposable = new Set<MessageBoundary>();\n\tprivate readonly localDiagnostics: NestBoundaryDiagnostic[] = [];\n\tprivate active = true;\n\n\tconstructor(private readonly opts: GraphMessageBridgeOptions<THost>) {}\n\n\tclose(): void {\n\t\tthis.dispose();\n\t}\n\n\tonModuleDestroy(): void {\n\t\tthis.dispose();\n\t}\n\n\thandleMessage(\n\t\ttarget: DecoratorHostConstructor | object,\n\t\tmethodKey: string | symbol,\n\t\thost: THost,\n\t\trunOpts: NestGraphRunOptions<THost> = {},\n\t): Promise<unknown> | undefined {\n\t\tif (!this.active) throw new Error(\"GraphMessage native bridge is disposed\");\n\t\tconst bindings = getNestBoundaryBindings(target, methodKey);\n\t\tconst ingress = bindings.filter(isMessageIngress);\n\t\tif (ingress.length === 0) return undefined;\n\t\tconst replies = bindings.filter(isMessageReply);\n\t\tconst needsRequestId = replies.length > 0;\n\t\tfor (const binding of ingress) assertExplicitNativePayload(binding, \"GraphMessage\");\n\t\tconst ingressEmits = ingress.map((binding) => ({\n\t\t\tbinding,\n\t\t\trequestId: bindingRequestId(host, binding, runOpts.requestId ?? this.opts.requestId),\n\t\t}));\n\t\tif (needsRequestId && ingressEmits.some((entry) => entry.requestId === undefined)) {\n\t\t\tthrow new Error(\"GraphMessage native bridge requires a stable requestId for reply egress\");\n\t\t}\n\t\tconst requestIds = uniqueDefinedStrings(ingressEmits.map((entry) => entry.requestId));\n\t\tconst cleanups: Array<() => boolean> = [];\n\t\tlet timeout: ReturnType<typeof setTimeout> | undefined;\n\t\tlet settled = false;\n\t\tlet resolvePromise: ((payload: unknown) => void) | undefined;\n\t\tlet rejectPromise: ((error: unknown) => void) | undefined;\n\t\tlet cleaned = false;\n\t\tconst cleanupAll = () => {\n\t\t\tif (cleaned) return;\n\t\t\tcleaned = true;\n\t\t\tfor (const cleanup of cleanups) cleanup();\n\t\t\tthis.clearTimeout(timeout);\n\t\t};\n\t\tconst handle: NestReplyResponseHandle<unknown> = {\n\t\t\tresolve(payload) {\n\t\t\t\tif (settled) return;\n\t\t\t\tsettled = true;\n\t\t\t\tresolvePromise?.(payload);\n\t\t\t},\n\t\t\treject(error) {\n\t\t\t\tif (settled) return;\n\t\t\t\tsettled = true;\n\t\t\t\trejectPromise?.(error);\n\t\t\t},\n\t\t};\n\t\tconst promise =\n\t\t\treplies.length === 0\n\t\t\t\t? undefined\n\t\t\t\t: new Promise<unknown>((resolve, reject) => {\n\t\t\t\t\t\tresolvePromise = resolve;\n\t\t\t\t\t\trejectPromise = reject;\n\t\t\t\t\t});\n\t\tif (promise !== undefined) {\n\t\t\ttry {\n\t\t\t\tfor (const requestId of requestIds) {\n\t\t\t\t\tfor (const reply of replies) {\n\t\t\t\t\t\tcleanups.push(\n\t\t\t\t\t\t\tthis.boundaryFor(reply).attach({\n\t\t\t\t\t\t\t\trequestId,\n\t\t\t\t\t\t\t\tbindingId: reply.bindingId,\n\t\t\t\t\t\t\t\thandle,\n\t\t\t\t\t\t\t}),\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t} catch (error) {\n\t\t\t\tcleanupAll();\n\t\t\t\thandle.reject(error);\n\t\t\t\treturn promise;\n\t\t\t}\n\t\t\tif (settled) {\n\t\t\t\tcleanupAll();\n\t\t\t\treturn promise;\n\t\t\t}\n\t\t\tif (this.opts.timeoutMs !== undefined) {\n\t\t\t\ttimeout = setTimeout(() => {\n\t\t\t\t\tcleanupAll();\n\t\t\t\t\tconst error = new Error(\n\t\t\t\t\t\t`GraphMessage native bridge timed out waiting for ${requestIds[0]}`,\n\t\t\t\t\t);\n\t\t\t\t\tthis.diagnose({\n\t\t\t\t\t\tkind: \"timeout\",\n\t\t\t\t\t\trequestId: requestIds[0],\n\t\t\t\t\t\tmessage: error.message,\n\t\t\t\t\t\terror,\n\t\t\t\t\t});\n\t\t\t\t\thandle.reject(error);\n\t\t\t\t}, this.opts.timeoutMs);\n\t\t\t}\n\t\t}\n\t\ttry {\n\t\t\tfor (const { binding, requestId } of ingressEmits) {\n\t\t\t\tbinding.boundary.emit(host, {\n\t\t\t\t\t...bindingEmitOptions(host, binding, requestId),\n\t\t\t\t\trequireRequestId: needsRequestId,\n\t\t\t\t});\n\t\t\t}\n\t\t} catch (error) {\n\t\t\tcleanupAll();\n\t\t\tthrow error;\n\t\t}\n\t\treturn promise?.finally(() => {\n\t\t\tcleanupAll();\n\t\t});\n\t}\n\n\tdiagnostics(): readonly NestBoundaryDiagnostic[] {\n\t\treturn [\n\t\t\t...this.localDiagnostics,\n\t\t\t...[...this.disposable].flatMap((boundary) => boundary.diagnostics()),\n\t\t];\n\t}\n\n\tdispose(): void {\n\t\tif (!this.active) return;\n\t\tthis.active = false;\n\t\tfor (const boundary of this.disposable) boundary.dispose();\n\t}\n\n\tprivate boundaryFor(binding: NestMessageReplyBindingMeta): MessageBoundary {\n\t\tlet byBinding = this.boundaries.get(binding.replyNode);\n\t\tif (byBinding === undefined) {\n\t\t\tbyBinding = new Map();\n\t\t\tthis.boundaries.set(binding.replyNode, byBinding);\n\t\t}\n\t\tconst existing = byBinding.get(binding.bindingId);\n\t\tif (existing !== undefined) return existing;\n\t\tconst boundary = toNestHttp(binding.replyNode, {\n\t\t\tbindingId: binding.bindingId,\n\t\t\tdiagnosticBoundary: this.opts.diagnosticBoundary,\n\t\t\tdiagnosticPhase: \"message\",\n\t\t\tname: \"nestjs.message-reply\",\n\t\t\tmaxDiagnostics: this.opts.maxDiagnostics,\n\t\t});\n\t\tbyBinding.set(binding.bindingId, boundary);\n\t\tthis.disposable.add(boundary);\n\t\treturn boundary;\n\t}\n\n\tprivate diagnose(diagnostic: NestBoundaryDiagnostic): void {\n\t\tthis.localDiagnostics.push(diagnostic);\n\t\ttry {\n\t\t\tconst phase = diagnostic.phase ?? \"message\";\n\t\t\tconst payload = sanitizeNestDiagnostic({ ...diagnostic, phase }, phase);\n\t\t\tthis.opts.diagnosticBoundary?.emit(payload, { payload });\n\t\t} catch {\n\t\t\t// Graph-visible diagnostics are optional and must not interrupt host cleanup.\n\t\t}\n\t\tif (\n\t\t\tthis.opts.maxDiagnostics !== undefined &&\n\t\t\tthis.localDiagnostics.length > this.opts.maxDiagnostics\n\t\t) {\n\t\t\tthis.localDiagnostics.splice(0, this.localDiagnostics.length - this.opts.maxDiagnostics);\n\t\t}\n\t}\n\n\tprivate clearTimeout(timeout: ReturnType<typeof setTimeout> | undefined): void {\n\t\tif (timeout !== undefined) clearTimeout(timeout);\n\t}\n}\n\nfunction isMessageIngress(binding: NestBoundaryBindingMeta): binding is NestIngressBindingMeta {\n\treturn binding.direction === \"ingress\" && binding.kind === \"message\";\n}\n\nfunction isMessageReply(binding: NestBoundaryBindingMeta): binding is NestMessageReplyBindingMeta {\n\treturn binding.direction === \"egress\" && binding.kind === \"message-reply\";\n}\n\nfunction assertExplicitNativePayload(binding: NestIngressBindingMeta, label: string): void {\n\tif (binding.payload === undefined) {\n\t\tthrow new Error(`${label} native bridge requires an explicit payload selector`);\n\t}\n}\n\nfunction uniqueDefinedStrings(values: readonly (string | undefined)[]): string[] {\n\tconst seen = new Set<string>();\n\tfor (const value of values) if (value !== undefined) seen.add(value);\n\treturn [...seen];\n}\n\nexport {\n\tfromNestMessage,\n\tGraphMessage,\n\tGraphMessageReply,\n\ttype NestBoundaryEnvelope,\n\ttype NestIngressBoundary,\n\ttype NestIngressEmitOptions,\n\ttype NestIngressOptions,\n\ttype NestReplyEnvelope,\n};\n"],"mappings":";;;;;;;;;;;;;AAkCO,IAAM,iCAAiC,uBAAO,IAAI,gCAAgC;AA+BlF,SAAS,0BACf,OAAyC,CAAC,GACO;AACjD,SAAO,EAAE,SAAS,gCAAgC,UAAU,yBAAyB,IAAI,EAAE;AAC5F;AAGO,SAAS,6BACf,OAAiD,CAAC,GACC;AACnD,SAAO,KAAK,WAAW,QAAQ,CAAC,IAAI,CAAC,0BAA0B,KAAK,UAAU,CAAC,CAAC,CAAC;AAClF;AAGO,SAAS,yBACf,OAAyC,CAAC,GACd;AAC5B,SAAO,IAAI,uBAAuB,IAAI;AACvC;AAEA,IAAM,yBAAN,MAAyE;AAAA,EAMxE,YAA6B,MAAwC;AAAxC;AAAA,EAAyC;AAAA,EALrD,aAAa,oBAAI,QAA8C;AAAA,EAC/D,aAAa,oBAAI,IAAqB;AAAA,EACtC,mBAA6C,CAAC;AAAA,EACvD,SAAS;AAAA,EAIjB,QAAc;AACb,SAAK,QAAQ;AAAA,EACd;AAAA,EAEA,kBAAwB;AACvB,SAAK,QAAQ;AAAA,EACd;AAAA,EAEA,cACC,QACA,WACA,MACA,UAAsC,CAAC,GACR;AAC/B,QAAI,CAAC,KAAK,OAAQ,OAAM,IAAI,MAAM,wCAAwC;AAC1E,UAAM,WAAW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