@demlik/tea 0.13.0 → 0.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -9
- package/dist/agent/index.d.ts +637 -45
- package/dist/agent/index.js +9 -19
- package/dist/{chunk-25LBDCBC.js → chunk-6IQPODUF.js} +2 -2
- package/dist/{chunk-25LBDCBC.js.map → chunk-6IQPODUF.js.map} +1 -1
- package/dist/chunk-AQ6ZIMEA.js +421 -0
- package/dist/chunk-AQ6ZIMEA.js.map +1 -0
- package/dist/{chunk-MUUROGIH.js → chunk-BLJ2JQSH.js} +62 -12
- package/dist/chunk-BLJ2JQSH.js.map +1 -0
- package/dist/{chunk-RH5EFRVJ.js → chunk-F2US5BW6.js} +25 -5
- package/dist/chunk-F2US5BW6.js.map +1 -0
- package/dist/{batch-window/index.js → chunk-F7FMAWLA.js} +4 -8
- package/dist/chunk-F7FMAWLA.js.map +1 -0
- package/dist/{chunk-O4MVQTEJ.js → chunk-HUKZQX6U.js} +20 -16
- package/dist/chunk-HUKZQX6U.js.map +1 -0
- package/dist/{chunk-EWJP3YYP.js → chunk-HWVW4AXC.js} +3 -3
- package/dist/chunk-HWVW4AXC.js.map +1 -0
- package/dist/{chunk-DMYGQB4O.js → chunk-HYDWG35Q.js} +23 -6
- package/dist/chunk-HYDWG35Q.js.map +1 -0
- package/dist/{chunk-YUXP55T2.js → chunk-I5MQMJDW.js} +57 -7
- package/dist/chunk-I5MQMJDW.js.map +1 -0
- package/dist/{chunk-J6527VRQ.js → chunk-LFZUK6J2.js} +3 -3
- package/dist/chunk-LFZUK6J2.js.map +1 -0
- package/dist/{chunk-ZVJZ72HY.js → chunk-LYLTKJWM.js} +25 -11
- package/dist/chunk-LYLTKJWM.js.map +1 -0
- package/dist/{chunk-D736QUGF.js → chunk-MYXFNWAJ.js} +4 -5
- package/dist/chunk-MYXFNWAJ.js.map +1 -0
- package/dist/{chunk-K575PT4S.js → chunk-PR6TB3BL.js} +15 -4
- package/dist/chunk-PR6TB3BL.js.map +1 -0
- package/dist/chunk-RQULHGYH.js +1804 -0
- package/dist/chunk-RQULHGYH.js.map +1 -0
- package/dist/{chunk-FV3Z5MBE.js → chunk-TXN2KFHF.js} +14 -4
- package/dist/chunk-TXN2KFHF.js.map +1 -0
- package/dist/{chunk-Q2UM7BXU.js → chunk-VBDU4JL6.js} +2 -2
- package/dist/chunk-VBDU4JL6.js.map +1 -0
- package/dist/chunk-Z2L3LSNV.js +1470 -0
- package/dist/chunk-Z2L3LSNV.js.map +1 -0
- package/dist/{core-Co0LWkIA.d.ts → core-CTzMJ82M.d.ts} +72 -23
- package/dist/devtools/index.d.ts +2 -2
- package/dist/devtools/index.js +207 -2
- package/dist/devtools/index.js.map +1 -1
- package/dist/do/index.d.ts +42 -29
- package/dist/do/index.js +36 -25
- package/dist/do/index.js.map +1 -1
- package/dist/{durable-effects-C6uwzjb5.d.ts → durable-effects-B0-qGQDy.d.ts} +2 -2
- package/dist/extension/index.d.ts +300 -3
- package/dist/extension/index.js +596 -5
- package/dist/extension/index.js.map +1 -1
- package/dist/flow/index.d.ts +1295 -0
- package/dist/flow/index.js +732 -0
- package/dist/flow/index.js.map +1 -0
- package/dist/idempotency/index.d.ts +90 -116
- package/dist/idempotency/index.js +4 -1
- package/dist/{batch-window/index.d.ts → index-4vZzljCD.d.ts} +7 -12
- package/dist/{fan-out/index.d.ts → index-6A7dB8f6.d.ts} +7 -9
- package/dist/index-B5BZ-_cT.d.ts +616 -0
- package/dist/index-Bc40JWVl.d.ts +131 -0
- package/dist/{debounce/index.d.ts → index-DHSUmQTR.d.ts} +7 -7
- package/dist/index-DJWIER_3.d.ts +69 -0
- package/dist/{snapshot/index.d.ts → index-DMCeMPMJ.d.ts} +15 -78
- package/dist/{monitored-run/index.d.ts → index-NjrT3fL2.d.ts} +37 -13
- package/dist/{recorder/index.d.ts → index-TvRb1KVf.d.ts} +4 -7
- package/dist/{deadline/index.d.ts → index-q0hXFeZ0.d.ts} +155 -9
- package/dist/index.d.ts +711 -6
- package/dist/index.js +1 -2
- package/dist/jev/index.d.ts +634 -0
- package/dist/jev/index.js +433 -0
- package/dist/jev/index.js.map +1 -0
- package/dist/machine-CdIcN2Xm.d.ts +1773 -0
- package/dist/machine-viz/index.d.ts +1 -1
- package/dist/machine-viz/index.js +12 -5
- package/dist/machine-viz/index.js.map +1 -1
- package/dist/mem/index.d.ts +18 -3
- package/dist/mem/index.js +22 -2
- package/dist/mem/index.js.map +1 -1
- package/dist/node/index.d.ts +104 -6
- package/dist/node/index.js +132 -9
- package/dist/node/index.js.map +1 -1
- package/dist/{paginator → paginate}/index.d.ts +151 -6
- package/dist/paginate/index.js +7 -0
- package/dist/parity/index.d.ts +4 -10
- package/dist/parity/index.js +4 -7
- package/dist/parity/index.js.map +1 -1
- package/dist/pbt/index.d.ts +247 -5
- package/dist/pbt/index.js +124 -5
- package/dist/pbt/index.js.map +1 -1
- package/dist/{trace-replay → persistence}/index.d.ts +7 -5
- package/dist/persistence/index.js +6 -0
- package/dist/react/index.d.ts +2 -2
- package/dist/react/index.js +1 -2
- package/dist/react/index.js.map +1 -1
- package/dist/resilience/index.d.ts +743 -0
- package/dist/resilience/index.js +657 -0
- package/dist/resilience/index.js.map +1 -0
- package/dist/retry-backoff/index.d.ts +3 -2
- package/dist/retry-backoff/index.js +1 -1
- package/dist/runtime-types-LWDoi943.d.ts +998 -0
- package/dist/testing/index.d.ts +2 -2
- package/dist/testing/index.js +1 -2
- package/dist/testing/index.js.map +1 -1
- package/dist/{throttled-input → timing}/index.d.ts +143 -12
- package/dist/{throttled-input → timing}/index.js +57 -12
- package/dist/timing/index.js.map +1 -0
- package/dist/{types-XS_miRnB.d.ts → types-DP3f5NIl.d.ts} +1 -1
- package/dist/work-queue/index.d.ts +130 -54
- package/dist/work-queue/index.js +3 -2
- package/dist/work-queue/index.js.map +1 -1
- package/package.json +45 -218
- package/dist/authed-call/index.d.ts +0 -120
- package/dist/authed-call/index.js +0 -134
- package/dist/authed-call/index.js.map +0 -1
- package/dist/await-terminal/index.d.ts +0 -101
- package/dist/await-terminal/index.js +0 -76
- package/dist/await-terminal/index.js.map +0 -1
- package/dist/batch-window/index.js.map +0 -1
- package/dist/cache/index.d.ts +0 -152
- package/dist/cache/index.js +0 -8
- package/dist/chart/index.d.ts +0 -218
- package/dist/chart/index.js +0 -16
- package/dist/chart/index.js.map +0 -1
- package/dist/chart/inspect/index.d.ts +0 -86
- package/dist/chart/inspect/index.js +0 -5
- package/dist/chart/inspect/react.d.ts +0 -113
- package/dist/chart/inspect/react.js +0 -11
- package/dist/chart/inspect/react.js.map +0 -1
- package/dist/chart/inspect/styles.css +0 -286
- package/dist/chart/lane/index.d.ts +0 -362
- package/dist/chart/lane/index.js +0 -9
- package/dist/chart/lane/index.js.map +0 -1
- package/dist/chart/lane/react.d.ts +0 -84
- package/dist/chart/lane/react.js +0 -559
- package/dist/chart/lane/react.js.map +0 -1
- package/dist/chart/lane/server.d.ts +0 -148
- package/dist/chart/lane/server.js +0 -209
- package/dist/chart/lane/server.js.map +0 -1
- package/dist/chart/lane/styles.css +0 -498
- package/dist/chart/lane/viewer/assets/abnfDiagram-N423BO3Z-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/architectureDiagram-T3A2C74G-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/blockDiagram-VBNYF7ZC-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/c4Diagram-5PPSVZJV-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/chunk-2GRJ4B5K-HdDf8SI3.js +0 -1
- package/dist/chart/lane/viewer/assets/chunk-5RXB4S5H-CcNtpUd7.js +0 -231
- package/dist/chart/lane/viewer/assets/chunk-5VM5RSS4-BP4fRS_5.js +0 -15
- package/dist/chart/lane/viewer/assets/chunk-KBJHAD2P-DZOw7xU6.js +0 -1
- package/dist/chart/lane/viewer/assets/chunk-NSK5VX7P-CBCyTZMs.js +0 -128
- package/dist/chart/lane/viewer/assets/classDiagram-JCYQIIEL-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/classDiagram-v2-OCEON4UE-D4uAiFr8.js +0 -206
- package/dist/chart/lane/viewer/assets/cose-bilkent-JH36ORCC-DOwCrGXH.js +0 -1
- package/dist/chart/lane/viewer/assets/cynefinDiagram-MW4NZA55-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/dagre-K_PewWfS.js +0 -1
- package/dist/chart/lane/viewer/assets/dagre-VZM6K2ZE-831qZcA8.js +0 -4
- package/dist/chart/lane/viewer/assets/diagram-7IWD3JNH-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/diagram-B4RE2ZJO-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/diagram-LBJQPF4R-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/diagram-Q27KOJAE-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/diagram-UB23O5K3-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/ebnfDiagram-BXEA7PRR-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/erDiagram-JOGREHBK-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/flowDiagram-UKHOOZJN-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/ganttDiagram-PKOTCBZU-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/gitGraphDiagram-DS77QQ5N-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/index-9SkH5NA3.css +0 -1
- package/dist/chart/lane/viewer/assets/index-Bgt4sXpW.js +0 -195
- package/dist/chart/lane/viewer/assets/infoDiagram-6WML65LV-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/ishikawaDiagram-WSZJBQD7-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/journeyDiagram-NVQOT4AX-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/kanban-definition-27J2QSJJ-G7PaPzy-.js +0 -89
- package/dist/chart/lane/viewer/assets/katex-DOwCrGXH.js +0 -1
- package/dist/chart/lane/viewer/assets/mindmap-definition-FAOFIHXS-CGj9nrVk.js +0 -96
- package/dist/chart/lane/viewer/assets/path-fybaL0A-.js +0 -1
- package/dist/chart/lane/viewer/assets/pegDiagram-VL7TDLO6-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/pieDiagram-7S7Q4E2Y-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/quadrantDiagram-CIZ2JOQS-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/railroadDiagram-AXF67PYL-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/requirementDiagram-LRYGKXZP-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/sankeyDiagram-W5VNT64P-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/sequenceDiagram-SI44F4Z6-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/stateDiagram-OKZ733FA-B_88AzBS.js +0 -1
- package/dist/chart/lane/viewer/assets/stateDiagram-v2-UEYNNEHI-CR5gcgq6.js +0 -1
- package/dist/chart/lane/viewer/assets/swimlanes-SLNWSIFB-B4xK-rwg.js +0 -1
- package/dist/chart/lane/viewer/assets/swimlanesDiagram-ULZ7WXOC-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/timeline-definition-Z64GVDOM-CCv52MfY.js +0 -120
- package/dist/chart/lane/viewer/assets/vennDiagram-T6HMQDX7-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/wardleyDiagram-T6FBY63Y-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/assets/xychartDiagram-ELKLHX3M-C729LI31.js +0 -1
- package/dist/chart/lane/viewer/index.html +0 -15
- package/dist/chart/report/index.d.ts +0 -117
- package/dist/chart/report/index.js +0 -32
- package/dist/chart/report/index.js.map +0 -1
- package/dist/chunk-2YFLOCWX.js +0 -15
- package/dist/chunk-2YFLOCWX.js.map +0 -1
- package/dist/chunk-3I52QZZ5.js +0 -519
- package/dist/chunk-3I52QZZ5.js.map +0 -1
- package/dist/chunk-3ZAFFRRB.js +0 -457
- package/dist/chunk-3ZAFFRRB.js.map +0 -1
- package/dist/chunk-4EQZ76JC.js +0 -33
- package/dist/chunk-4EQZ76JC.js.map +0 -1
- package/dist/chunk-4KLG43GY.js +0 -223
- package/dist/chunk-4KLG43GY.js.map +0 -1
- package/dist/chunk-7FRZ2CT2.js +0 -424
- package/dist/chunk-7FRZ2CT2.js.map +0 -1
- package/dist/chunk-AZZLE7XR.js +0 -62
- package/dist/chunk-AZZLE7XR.js.map +0 -1
- package/dist/chunk-BYQUGDD3.js +0 -16
- package/dist/chunk-BYQUGDD3.js.map +0 -1
- package/dist/chunk-CIQG5L42.js +0 -685
- package/dist/chunk-CIQG5L42.js.map +0 -1
- package/dist/chunk-CLM6ERNO.js +0 -61
- package/dist/chunk-CLM6ERNO.js.map +0 -1
- package/dist/chunk-COS5MSTO.js +0 -88
- package/dist/chunk-COS5MSTO.js.map +0 -1
- package/dist/chunk-CRPZJVD2.js +0 -71
- package/dist/chunk-CRPZJVD2.js.map +0 -1
- package/dist/chunk-D62FDQKE.js +0 -53
- package/dist/chunk-D62FDQKE.js.map +0 -1
- package/dist/chunk-D736QUGF.js.map +0 -1
- package/dist/chunk-DGE4PV4A.js +0 -26
- package/dist/chunk-DGE4PV4A.js.map +0 -1
- package/dist/chunk-DMYGQB4O.js.map +0 -1
- package/dist/chunk-EWJP3YYP.js.map +0 -1
- package/dist/chunk-FV3Z5MBE.js.map +0 -1
- package/dist/chunk-HCEVHFJ7.js +0 -54
- package/dist/chunk-HCEVHFJ7.js.map +0 -1
- package/dist/chunk-J6527VRQ.js.map +0 -1
- package/dist/chunk-JELSZN25.js +0 -47
- package/dist/chunk-JELSZN25.js.map +0 -1
- package/dist/chunk-K575PT4S.js.map +0 -1
- package/dist/chunk-L57ZOT5K.js +0 -184
- package/dist/chunk-L57ZOT5K.js.map +0 -1
- package/dist/chunk-MU6MCIAC.js +0 -15
- package/dist/chunk-MU6MCIAC.js.map +0 -1
- package/dist/chunk-MUUROGIH.js.map +0 -1
- package/dist/chunk-NR7BU22N.js +0 -758
- package/dist/chunk-NR7BU22N.js.map +0 -1
- package/dist/chunk-O4MVQTEJ.js.map +0 -1
- package/dist/chunk-OOYD44JI.js +0 -317
- package/dist/chunk-OOYD44JI.js.map +0 -1
- package/dist/chunk-Q2UM7BXU.js.map +0 -1
- package/dist/chunk-RH5EFRVJ.js.map +0 -1
- package/dist/chunk-S2EGRPCM.js +0 -47
- package/dist/chunk-S2EGRPCM.js.map +0 -1
- package/dist/chunk-SINXE47Y.js +0 -55
- package/dist/chunk-SINXE47Y.js.map +0 -1
- package/dist/chunk-UF4MZSLT.js +0 -53
- package/dist/chunk-UF4MZSLT.js.map +0 -1
- package/dist/chunk-UOC2PL46.js +0 -13
- package/dist/chunk-UOC2PL46.js.map +0 -1
- package/dist/chunk-VYFAZN3F.js +0 -372
- package/dist/chunk-VYFAZN3F.js.map +0 -1
- package/dist/chunk-WRAA7GVZ.js +0 -209
- package/dist/chunk-WRAA7GVZ.js.map +0 -1
- package/dist/chunk-XGELA764.js +0 -163
- package/dist/chunk-XGELA764.js.map +0 -1
- package/dist/chunk-YUXP55T2.js.map +0 -1
- package/dist/chunk-YWIKDKHY.js +0 -307
- package/dist/chunk-YWIKDKHY.js.map +0 -1
- package/dist/chunk-ZJ5AOYBH.js +0 -8
- package/dist/chunk-ZJ5AOYBH.js.map +0 -1
- package/dist/chunk-ZSUUOEPL.js +0 -731
- package/dist/chunk-ZSUUOEPL.js.map +0 -1
- package/dist/chunk-ZVJZ72HY.js.map +0 -1
- package/dist/circuit-breaker/index.d.ts +0 -197
- package/dist/circuit-breaker/index.js +0 -3
- package/dist/circuit-breaker/index.js.map +0 -1
- package/dist/deadline/index.js +0 -6
- package/dist/deadline/index.js.map +0 -1
- package/dist/debounce/index.js +0 -3
- package/dist/debounce/index.js.map +0 -1
- package/dist/extension/react.d.ts +0 -121
- package/dist/extension/react.js +0 -75
- package/dist/extension/react.js.map +0 -1
- package/dist/extension/subs/index.d.ts +0 -45
- package/dist/extension/subs/index.js +0 -80
- package/dist/extension/subs/index.js.map +0 -1
- package/dist/extension/test-utils.d.ts +0 -128
- package/dist/extension/test-utils.js +0 -277
- package/dist/extension/test-utils.js.map +0 -1
- package/dist/fan-out/index.js +0 -5
- package/dist/fan-out/index.js.map +0 -1
- package/dist/fold-BJPdjc9w.d.ts +0 -435
- package/dist/graph-B3L5e0N1.d.ts +0 -923
- package/dist/idempotency/adapter.d.ts +0 -62
- package/dist/idempotency/adapter.js +0 -4
- package/dist/idempotency/adapter.js.map +0 -1
- package/dist/idempotent-intake/index.d.ts +0 -188
- package/dist/idempotent-intake/index.js +0 -7
- package/dist/idempotent-intake/index.js.map +0 -1
- package/dist/journal/index.d.ts +0 -373
- package/dist/journal/index.js +0 -3
- package/dist/journal/index.js.map +0 -1
- package/dist/llm-call/index.d.ts +0 -311
- package/dist/llm-call/index.js +0 -16
- package/dist/llm-call/index.js.map +0 -1
- package/dist/machine-BtFWQmmq.d.ts +0 -804
- package/dist/monitored-run/index.js +0 -10
- package/dist/monitored-run/index.js.map +0 -1
- package/dist/paginated-walk/index.d.ts +0 -235
- package/dist/paginated-walk/index.js +0 -16
- package/dist/paginated-walk/index.js.map +0 -1
- package/dist/paginator/index.js +0 -3
- package/dist/paginator/index.js.map +0 -1
- package/dist/pbt/arbitraries/index.d.ts +0 -136
- package/dist/pbt/arbitraries/index.js +0 -3
- package/dist/pbt/arbitraries/index.js.map +0 -1
- package/dist/pbt/runners/index.d.ts +0 -118
- package/dist/pbt/runners/index.js +0 -5
- package/dist/pbt/runners/index.js.map +0 -1
- package/dist/poller/index.d.ts +0 -352
- package/dist/poller/index.js +0 -115
- package/dist/poller/index.js.map +0 -1
- package/dist/prediction/index.d.ts +0 -131
- package/dist/prediction/index.js +0 -4
- package/dist/prediction/index.js.map +0 -1
- package/dist/protocol-B5YmJr0d.d.ts +0 -45
- package/dist/pure/index.d.ts +0 -3
- package/dist/pure/index.js +0 -4
- package/dist/pure/index.js.map +0 -1
- package/dist/rate-limit/index.d.ts +0 -115
- package/dist/rate-limit/index.js +0 -3
- package/dist/rate-limit/index.js.map +0 -1
- package/dist/reconciler/index.d.ts +0 -193
- package/dist/reconciler/index.js +0 -164
- package/dist/reconciler/index.js.map +0 -1
- package/dist/recorder/index.js +0 -3
- package/dist/recorder/index.js.map +0 -1
- package/dist/reducer-4GNR6b8B.d.ts +0 -447
- package/dist/resilient-call/index.d.ts +0 -320
- package/dist/resilient-call/index.js +0 -14
- package/dist/resilient-call/index.js.map +0 -1
- package/dist/retry-to-success/index.d.ts +0 -109
- package/dist/retry-to-success/index.js +0 -37
- package/dist/retry-to-success/index.js.map +0 -1
- package/dist/run-pAcmBpah.d.ts +0 -713
- package/dist/runtime-types-CNLmhWif.d.ts +0 -517
- package/dist/saga/index.d.ts +0 -241
- package/dist/saga/index.js +0 -150
- package/dist/saga/index.js.map +0 -1
- package/dist/samples-B3My5oh2.d.ts +0 -59
- package/dist/snapshot/index.js +0 -5
- package/dist/snapshot/index.js.map +0 -1
- package/dist/subs/index.d.ts +0 -472
- package/dist/subs/index.js +0 -7
- package/dist/subs/index.js.map +0 -1
- package/dist/throttle/index.d.ts +0 -134
- package/dist/throttle/index.js +0 -3
- package/dist/throttle/index.js.map +0 -1
- package/dist/throttled-input/index.js.map +0 -1
- package/dist/token-refresh/index.d.ts +0 -216
- package/dist/token-refresh/index.js +0 -6
- package/dist/token-refresh/index.js.map +0 -1
- package/dist/trace-replay/index.js +0 -6
- package/dist/trace-replay/index.js.map +0 -1
- package/dist/with-deadline/index.d.ts +0 -197
- package/dist/with-deadline/index.js +0 -111
- package/dist/with-deadline/index.js.map +0 -1
- package/dist/with-resilience/index.d.ts +0 -225
- package/dist/with-resilience/index.js +0 -240
- package/dist/with-resilience/index.js.map +0 -1
- package/dist/with-telemetry/index.d.ts +0 -150
- package/dist/with-telemetry/index.js +0 -70
- package/dist/with-telemetry/index.js.map +0 -1
- package/dist/work-queue/adapter.d.ts +0 -84
- package/dist/work-queue/adapter.js +0 -4
- package/dist/work-queue/adapter.js.map +0 -1
- package/dist/work-queue/ops.d.ts +0 -71
- package/dist/work-queue/ops.js +0 -3
- package/dist/work-queue/ops.js.map +0 -1
- package/dist/workflow/index.d.ts +0 -485
- package/dist/workflow/index.js +0 -244
- package/dist/workflow/index.js.map +0 -1
- /package/dist/{cache → paginate}/index.js.map +0 -0
- /package/dist/{chart/inspect → persistence}/index.js.map +0 -0
|
@@ -1,9 +1,155 @@
|
|
|
1
|
-
import { S as Sub,
|
|
2
|
-
import { S as SubscribeHandler } from '
|
|
3
|
-
import 'zod';
|
|
1
|
+
import { S as Sub, c as SubId } from './core-CTzMJ82M.js';
|
|
2
|
+
import { S as SubscribeHandler } from './types-DP3f5NIl.js';
|
|
4
3
|
|
|
5
4
|
/**
|
|
6
|
-
*
|
|
5
|
+
* internal/resilience/cache — a TTL cache as pure state, PLUS a periodic eviction Sub.
|
|
6
|
+
*
|
|
7
|
+
* Same pure-state-ops shape as `../../idempotency/` and
|
|
8
|
+
* `../../work-queue/ops.ts`: a state type plus pure transition functions. Host-
|
|
9
|
+
* agnostic by construction — no `Date.now()`, no timers, no I/O inside the ops.
|
|
10
|
+
* The caller injects the clock (`nowMs`) and folds the result through its own
|
|
11
|
+
* reducer, keeping the store inside TEA's invariant 2 (transitions are pure:
|
|
12
|
+
* same inputs → same outputs) so a consumer can exercise it with `replay`
|
|
13
|
+
* without a fake clock.
|
|
14
|
+
*
|
|
15
|
+
* Every op returns a NEW cache value and never mutates its input (invariant 1 —
|
|
16
|
+
* state is a value, not a place). `get` / `has` are read-shaped; `set` /
|
|
17
|
+
* `remove` / `evictExpired` return a new cache.
|
|
18
|
+
*
|
|
19
|
+
* **Distinct from `/idempotency`.** Both are TTL-bounded key maps, but they
|
|
20
|
+
* answer different questions and so carry different shapes:
|
|
21
|
+
*
|
|
22
|
+
* - `/idempotency` is DEDUPE-focused — "have I already processed this key?"
|
|
23
|
+
* TTL is a single store-level policy (`ttlMs`), each entry stores the
|
|
24
|
+
* `atMs` it was remembered at, and expiry is derived (`now - atMs >=
|
|
25
|
+
* ttlMs`). It carries an `order` ledger + `capacity` because the use case
|
|
26
|
+
* (webhook receivers, retried messages) needs bounded LRU eviction.
|
|
27
|
+
* - `/cache` is RETRIEVAL-focused — "what is the value for this key right
|
|
28
|
+
* now?" TTL is set PER ENTRY at write time: `set(key, value, nowMs,
|
|
29
|
+
* ttlMs)` bakes the absolute `expiresAtMs = nowMs + ttlMs` into the entry.
|
|
30
|
+
* Different keys can carry different lifetimes (a hot key cached for 1s, a
|
|
31
|
+
* cold one for 1h) — the dimension idempotency's single store-level
|
|
32
|
+
* `ttlMs` cannot express. No `order`, no `capacity`: a cache bounds itself
|
|
33
|
+
* by TTL + periodic eviction, not by LRU count.
|
|
34
|
+
*
|
|
35
|
+
* The eviction Sub is the "eviction is a Msg" half: a `setInterval`-shaped Sub
|
|
36
|
+
* (composed directly on `fromInterval`, from `src/subs/`) that periodically
|
|
37
|
+
* dispatches a `cache_evict` Msg the consumer's reducer handles by calling
|
|
38
|
+
* `evictExpired`. Time still never enters the reducer — the Sub fires the Msg,
|
|
39
|
+
* the reducer reads `nowMs` off the Msg (the consumer stamps it at the Sub
|
|
40
|
+
* boundary), and `evictExpired` does the pure drop.
|
|
41
|
+
*
|
|
42
|
+
* Internal to the package (`src/internal/resilience/`), not a published
|
|
43
|
+
* subpath (#46); same one-shape-per-module rule as `work-queue`, `idempotency`,
|
|
44
|
+
* and `rate-limit`.
|
|
45
|
+
*/
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* A cached entry: the `value` and the absolute clock reading `expiresAtMs` it
|
|
49
|
+
* expires at. Unlike `/idempotency`'s entry (which stores `atMs` and derives
|
|
50
|
+
* expiry from a store-level `ttlMs`), the expiry instant is baked in at write
|
|
51
|
+
* time — so per-entry TTLs are a first-class capability. Both fields are plain
|
|
52
|
+
* data so the whole cache is trivially JSON-serializable into a consumer's
|
|
53
|
+
* `Store<S>`.
|
|
54
|
+
*/
|
|
55
|
+
interface CacheEntry<V> {
|
|
56
|
+
readonly value: V;
|
|
57
|
+
readonly expiresAtMs: number;
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* The cache: a map of `key → entry`. No `order` ledger and no `capacity` (cf.
|
|
61
|
+
* `/idempotency`) — a TTL cache bounds itself by expiry + periodic eviction,
|
|
62
|
+
* not by LRU count. Each entry carries its own `expiresAtMs`, so the cache
|
|
63
|
+
* needs no store-level TTL policy field.
|
|
64
|
+
*/
|
|
65
|
+
interface TtlCache<V> {
|
|
66
|
+
readonly entries: Readonly<Record<string, CacheEntry<V>>>;
|
|
67
|
+
}
|
|
68
|
+
/** Create an empty cache. */
|
|
69
|
+
declare function initCache<V>(): TtlCache<V>;
|
|
70
|
+
/**
|
|
71
|
+
* The cached `value` for `key` iff present AND unexpired at `nowMs`, else
|
|
72
|
+
* `undefined`. An expired entry reads as absent even though it is physically
|
|
73
|
+
* still in `entries` until the next `evictExpired` (or an overwriting `set`)
|
|
74
|
+
* drops it. PURE — reads only, never mutates.
|
|
75
|
+
*/
|
|
76
|
+
declare function get<V>(cache: TtlCache<V>, key: string, nowMs: number): V | undefined;
|
|
77
|
+
/**
|
|
78
|
+
* True iff `key` is present AND unexpired at `nowMs`. The boolean sibling of
|
|
79
|
+
* `get` for callers that only need presence, not the value. PURE.
|
|
80
|
+
*/
|
|
81
|
+
declare function has<V>(cache: TtlCache<V>, key: string, nowMs: number): boolean;
|
|
82
|
+
/**
|
|
83
|
+
* Write `key → value` with an absolute expiry of `nowMs + ttlMs`. Re-`set`ting
|
|
84
|
+
* an existing key overwrites both the value and the expiry — the TTL clock
|
|
85
|
+
* restarts from the new `nowMs`. PURE — returns a new cache; the input is
|
|
86
|
+
* untouched (a fresh shallow copy of `entries`).
|
|
87
|
+
*/
|
|
88
|
+
declare function set<V>(cache: TtlCache<V>, key: string, value: V, nowMs: number, ttlMs: number): TtlCache<V>;
|
|
89
|
+
/**
|
|
90
|
+
* Drop `key` regardless of expiry. PURE — returns a new cache; the input is
|
|
91
|
+
* untouched. Removing an absent key returns an equivalent cache (the shallow
|
|
92
|
+
* copy still happens, but no entry is dropped).
|
|
93
|
+
*/
|
|
94
|
+
declare function remove<V>(cache: TtlCache<V>, key: string): TtlCache<V>;
|
|
95
|
+
/**
|
|
96
|
+
* Physically drop every entry expired at `nowMs` (`nowMs >= expiresAtMs`).
|
|
97
|
+
* Returns a NEW cache with the survivors. This is the pure work the eviction
|
|
98
|
+
* Sub's `cache_evict` Msg triggers — `get` / `has` already treat expired
|
|
99
|
+
* entries as absent, so eviction is purely a memory-reclaim pass, not a
|
|
100
|
+
* correctness one. PURE — the input cache is never mutated.
|
|
101
|
+
*/
|
|
102
|
+
declare function evictExpired<V>(cache: TtlCache<V>, nowMs: number): TtlCache<V>;
|
|
103
|
+
/**
|
|
104
|
+
* The Msg the eviction Sub dispatches each tick. `id` is the Sub's own id so a
|
|
105
|
+
* consumer with multiple caches can route the tick to the matching cache. The
|
|
106
|
+
* reducer reads `Date.now()`-free time by stamping `nowMs` itself at the Sub
|
|
107
|
+
* boundary if needed; the canonical reducer cell is
|
|
108
|
+
* `cache_evict: (s) => [{ ...s, cache: evictExpired(s.cache, nowMs) }, []]`.
|
|
109
|
+
*/
|
|
110
|
+
interface CacheEvictMsg {
|
|
111
|
+
readonly type: "cache_evict";
|
|
112
|
+
readonly id: string;
|
|
113
|
+
}
|
|
114
|
+
/** Construct a `cache_evict` Msg for the cache identified by `id`. */
|
|
115
|
+
declare function cacheEvictMsg(id: string): CacheEvictMsg;
|
|
116
|
+
/**
|
|
117
|
+
* The Sub shape the eviction factory installs: a `setInterval`-shaped Sub
|
|
118
|
+
* carrying its tick period (`intervalMs`) per the substrate's
|
|
119
|
+
* reconcile-by-id-with-data-on-the-Sub contract. `type: "cache"` is the
|
|
120
|
+
* lowercase source-noun Sub convention (canon §2.5 / naming-style).
|
|
121
|
+
*/
|
|
122
|
+
type CacheEvictionSub = Sub<"cache"> & {
|
|
123
|
+
readonly intervalMs: number;
|
|
124
|
+
};
|
|
125
|
+
/**
|
|
126
|
+
* Declare an eviction Sub for the cache identified by `id`, ticking every
|
|
127
|
+
* `everyMs`. Drop the result into `subscriptions(state)`:
|
|
128
|
+
*
|
|
129
|
+
* subscriptions: (s) => [cacheEvictionSub("session-cache", 30_000)]
|
|
130
|
+
*
|
|
131
|
+
* Same id ⇒ same running interval across transitions (no reconcile churn);
|
|
132
|
+
* changing `everyMs` alone will NOT re-arm the timer (the substrate leaves a
|
|
133
|
+
* same-id Sub running) — change the `id` too if the period must change. This
|
|
134
|
+
* mirrors `fromInterval`'s data-on-the-Sub tradeoff exactly.
|
|
135
|
+
*/
|
|
136
|
+
declare function cacheEvictionSub(id: string, everyMs: number): CacheEvictionSub;
|
|
137
|
+
/**
|
|
138
|
+
* The `subscribe` cell for the eviction Sub. Assign it to
|
|
139
|
+
* `machine.subscribe.cache`:
|
|
140
|
+
*
|
|
141
|
+
* subscribe: { cache: cacheEvictionSubscribe }
|
|
142
|
+
*
|
|
143
|
+
* Composed directly on `fromInterval` — it owns the `setInterval` /
|
|
144
|
+
* `clearInterval` lifecycle; this cell only pins the Msg the tick dispatches
|
|
145
|
+
* (`cacheEvictMsg(sub.id)`). The cleanup `fromInterval` returns stops the
|
|
146
|
+
* interval when the Sub is reconciled out (the cache's state exits the phase
|
|
147
|
+
* that declared it).
|
|
148
|
+
*/
|
|
149
|
+
declare const cacheEvictionSubscribe: SubscribeHandler<CacheEvictionSub, CacheEvictMsg, unknown>;
|
|
150
|
+
|
|
151
|
+
/**
|
|
152
|
+
* internal/resilience/deadline — a one-shot Sub that fires when an ABSOLUTE wall-clock
|
|
7
153
|
* deadline is reached.
|
|
8
154
|
*
|
|
9
155
|
* Generalizes the recurring "auto-fail a machine at T+N" / "15-minute stale
|
|
@@ -24,7 +170,7 @@ import 'zod';
|
|
|
24
170
|
*
|
|
25
171
|
* Composition over reinvention: the timer lifecycle is `fromTimeout`'s, not
|
|
26
172
|
* redrawn here. `deadlineSub` produces the Sub literal carrying `atMs`; the
|
|
27
|
-
* `subscribe`
|
|
173
|
+
* `subscribe` handler (`subscribeDeadline`) translates `atMs` → a relative delay
|
|
28
174
|
* and delegates the `setTimeout` / `clearTimeout` to `fromTimeout`. The clock
|
|
29
175
|
* read (`Date.now()`) lives only in the subscribe handler — never in a reducer
|
|
30
176
|
* (invariant 2) — and is exercised in tests via vitest fake timers, matching
|
|
@@ -35,7 +181,7 @@ import 'zod';
|
|
|
35
181
|
* live `setTimeout` to wake it, so its deadline must be backed by a `do_alarm`
|
|
36
182
|
* registered on the alarm registry; a test host wants a fake-timer schedule.
|
|
37
183
|
* That backing is the `ArmTimer` seam — `subscribeWith(armTimer)` builds the
|
|
38
|
-
* `subscribe.deadline`
|
|
184
|
+
* `subscribe.deadline` handler from a host-plugged timer, and `subscribeDeadline`
|
|
39
185
|
* IS `subscribeWith(setTimeoutArmTimer())`. One deadline surface, three hosts;
|
|
40
186
|
* there is no second Sub type and no second `atMs` anchor to keep in sync.
|
|
41
187
|
*
|
|
@@ -173,7 +319,7 @@ declare function subscribeWith(armTimer: ArmTimer<DeadlineExceeded>): SubscribeH
|
|
|
173
319
|
*/
|
|
174
320
|
declare function setTimeoutArmTimer(): ArmTimer<DeadlineExceeded>;
|
|
175
321
|
/**
|
|
176
|
-
* The `subscribe["deadline"]`
|
|
322
|
+
* The `subscribe["deadline"]` handler for the DEFAULT `setTimeout` backing. Arms a
|
|
177
323
|
* one-shot timer for the remaining delay `max(0, atMs - Date.now())` and
|
|
178
324
|
* dispatches `deadlineExceeded(...)` when it fires; returns a cleanup that
|
|
179
325
|
* clears the pending timer.
|
|
@@ -182,7 +328,7 @@ declare function setTimeoutArmTimer(): ArmTimer<DeadlineExceeded>;
|
|
|
182
328
|
* a separate implementation, so the host-plugged path and the default path can
|
|
183
329
|
* never disagree about the anchor.
|
|
184
330
|
*
|
|
185
|
-
* Assign directly to a `Subscribe`
|
|
331
|
+
* Assign directly to a `Subscribe` handler:
|
|
186
332
|
*
|
|
187
333
|
* subscribe: {
|
|
188
334
|
* deadline: subscribeDeadline,
|
|
@@ -196,4 +342,4 @@ declare const subscribeDeadline: SubscribeHandler<DeadlineSub, DeadlineExceeded,
|
|
|
196
342
|
*/
|
|
197
343
|
declare function deadlineExceeded(id: string, atMs: number): DeadlineExceeded;
|
|
198
344
|
|
|
199
|
-
export { type ArmTimer, type DeadlineExceeded, type
|
|
345
|
+
export { type ArmTimer as A, type CacheEvictionSub as C, type DeadlineExceeded as D, type TtlCache as T, type DeadlineSub as a, deadlineSub as b, type CacheEvictMsg as c, deadlineExceeded as d, type CacheEntry as e, type DeadlineOpts as f, cacheEvictMsg as g, cacheEvictionSub as h, cacheEvictionSubscribe as i, evictExpired as j, get as k, has as l, initCache as m, set as n, setTimeoutArmTimer as o, subscribeWith as p, remove as r, subscribeDeadline as s };
|