@geekmidas/constructs 10.0.0-alpha.12 → 10.0.0-alpha.121
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 +222 -158
- package/dist/Construct-B7AXn0xH.d.mts +230 -0
- package/dist/Construct-B7AXn0xH.d.mts.map +1 -0
- package/dist/Construct-CFW0zjdD.d.cts +230 -0
- package/dist/Construct-CFW0zjdD.d.cts.map +1 -0
- package/dist/{Construct-BD5neF7w.mjs → Construct-CKUA-CTA.mjs} +35 -35
- package/dist/Construct-CKUA-CTA.mjs.map +1 -0
- package/dist/{Construct-CyS3RpTL.cjs → Construct-DEOVauyA.cjs} +55 -49
- package/dist/Construct-DEOVauyA.cjs.map +1 -0
- package/dist/{Cron-DmQ8vQ4b.d.cts → Cron-bdGRSROY.d.cts} +15 -9
- package/dist/Cron-bdGRSROY.d.cts.map +1 -0
- package/dist/{Cron-dh4rUgib.d.mts → Cron-i4Uetezh.d.mts} +15 -9
- package/dist/Cron-i4Uetezh.d.mts.map +1 -0
- package/dist/CronBuilder-9H4BnD6W.d.mts +47 -0
- package/dist/CronBuilder-9H4BnD6W.d.mts.map +1 -0
- package/dist/{CronBuilder-Da0C0edR.cjs → CronBuilder-BXTG10u5.cjs} +47 -31
- package/dist/CronBuilder-BXTG10u5.cjs.map +1 -0
- package/dist/CronBuilder-B_24LZpn.d.cts +47 -0
- package/dist/CronBuilder-B_24LZpn.d.cts.map +1 -0
- package/dist/{CronBuilder-CYKT5RiO.mjs → CronBuilder-D3sF9tS_.mjs} +37 -21
- package/dist/CronBuilder-D3sF9tS_.mjs.map +1 -0
- package/dist/{Endpoint-BjWKinFA.d.mts → Endpoint-CeFkSwh5.d.mts} +129 -99
- package/dist/Endpoint-CeFkSwh5.d.mts.map +1 -0
- package/dist/{Endpoint-dav89W6-.d.cts → Endpoint-DgrpG15P.d.cts} +127 -97
- package/dist/Endpoint-DgrpG15P.d.cts.map +1 -0
- package/dist/{Endpoint-DCQPMdUX.mjs → Endpoint-gPXhHKhJ.mjs} +208 -100
- package/dist/Endpoint-gPXhHKhJ.mjs.map +1 -0
- package/dist/{Endpoint-DcWXE-SZ.cjs → Endpoint-yhR2T2Wt.cjs} +248 -122
- package/dist/Endpoint-yhR2T2Wt.cjs.map +1 -0
- package/dist/{EndpointFactory-CdWB7wPw.cjs → EndpointFactory-CSrAyazj.cjs} +361 -112
- package/dist/EndpointFactory-CSrAyazj.cjs.map +1 -0
- package/dist/{index-lAO9egTb.d.mts → EndpointFactory-Cc863XJS.d.cts} +190 -136
- package/dist/EndpointFactory-Cc863XJS.d.cts.map +1 -0
- package/dist/{index-Bd5FqCoe.d.cts → EndpointFactory-Dbw9ugkX.d.mts} +189 -135
- package/dist/EndpointFactory-Dbw9ugkX.d.mts.map +1 -0
- package/dist/{EndpointFactory-CjV8F_lJ.mjs → EndpointFactory-c2ZugGig.mjs} +283 -76
- package/dist/EndpointFactory-c2ZugGig.mjs.map +1 -0
- package/dist/Function-B0uZhZnU.d.cts +76 -0
- package/dist/Function-B0uZhZnU.d.cts.map +1 -0
- package/dist/Function-B_9R7Zy1.d.mts +76 -0
- package/dist/Function-B_9R7Zy1.d.mts.map +1 -0
- package/dist/{HonoEndpointAdaptor-DtL9j19R.cjs → HonoEndpointAdaptor-CN1jjUBJ.cjs} +115 -71
- package/dist/HonoEndpointAdaptor-CN1jjUBJ.cjs.map +1 -0
- package/dist/{HonoEndpointAdaptor-P1ahhZHu.mjs → HonoEndpointAdaptor-euH1oSdY.mjs} +105 -64
- package/dist/HonoEndpointAdaptor-euH1oSdY.mjs.map +1 -0
- package/dist/{Queue-D7ZuwBhy.d.cts → Queue-B-dDXyjF.d.mts} +48 -48
- package/dist/Queue-B-dDXyjF.d.mts.map +1 -0
- package/dist/Queue-BhuofM3k.cjs +109 -0
- package/dist/Queue-BhuofM3k.cjs.map +1 -0
- package/dist/{Queue-gVGfi2Yk.d.mts → Queue-JbIjVtTf.d.cts} +49 -49
- package/dist/Queue-JbIjVtTf.d.cts.map +1 -0
- package/dist/Queue-cmhqEBOB.mjs +104 -0
- package/dist/Queue-cmhqEBOB.mjs.map +1 -0
- package/dist/QueueBuilder-48W-q8In.d.mts +75 -0
- package/dist/QueueBuilder-48W-q8In.d.mts.map +1 -0
- package/dist/QueueBuilder-DXu1qxT1.mjs +118 -0
- package/dist/QueueBuilder-DXu1qxT1.mjs.map +1 -0
- package/dist/QueueBuilder-DdU2klPu.cjs +135 -0
- package/dist/QueueBuilder-DdU2klPu.cjs.map +1 -0
- package/dist/QueueBuilder-MfpkJ3R9.d.cts +75 -0
- package/dist/QueueBuilder-MfpkJ3R9.d.cts.map +1 -0
- package/dist/{Subscriber-2mEi0ImH.d.cts → Subscriber-CEt7kHkc.d.cts} +29 -20
- package/dist/Subscriber-CEt7kHkc.d.cts.map +1 -0
- package/dist/{Subscriber-xTJ9ayPN.d.mts → Subscriber-dsxc5LKa.d.mts} +29 -20
- package/dist/Subscriber-dsxc5LKa.d.mts.map +1 -0
- package/dist/SubscriberBuilder-BRa_nrmH.d.cts +67 -0
- package/dist/SubscriberBuilder-BRa_nrmH.d.cts.map +1 -0
- package/dist/SubscriberBuilder-D9bkrYzH.d.mts +67 -0
- package/dist/SubscriberBuilder-D9bkrYzH.d.mts.map +1 -0
- package/dist/{SubscriberBuilder-BjkbeT9l.mjs → SubscriberBuilder-DRXfxWn_.mjs} +50 -24
- package/dist/SubscriberBuilder-DRXfxWn_.mjs.map +1 -0
- package/dist/{SubscriberBuilder-4OPehf2R.cjs → SubscriberBuilder-M2EAgQhC.cjs} +61 -36
- package/dist/SubscriberBuilder-M2EAgQhC.cjs.map +1 -0
- package/dist/Topic-D2R0r24C.mjs +99 -0
- package/dist/Topic-D2R0r24C.mjs.map +1 -0
- package/dist/Topic-DwS3QO0m.cjs +104 -0
- package/dist/Topic-DwS3QO0m.cjs.map +1 -0
- package/dist/adaptors/aws.cjs +200 -246
- package/dist/adaptors/aws.cjs.map +1 -1
- package/dist/adaptors/aws.d.cts +58 -62
- package/dist/adaptors/aws.d.cts.map +1 -1
- package/dist/adaptors/aws.d.mts +59 -63
- package/dist/adaptors/aws.d.mts.map +1 -1
- package/dist/adaptors/aws.mjs +171 -219
- package/dist/adaptors/aws.mjs.map +1 -1
- package/dist/adaptors/hono.cjs +3 -10
- package/dist/adaptors/hono.d.cts +7 -16
- package/dist/adaptors/hono.d.cts.map +1 -1
- package/dist/adaptors/hono.d.mts +9 -18
- package/dist/adaptors/hono.d.mts.map +1 -1
- package/dist/adaptors/hono.mjs +2 -10
- package/dist/adaptors/testing.cjs +765 -99
- package/dist/adaptors/testing.cjs.map +1 -1
- package/dist/adaptors/testing.d.cts +351 -54
- package/dist/adaptors/testing.d.cts.map +1 -1
- package/dist/adaptors/testing.d.mts +351 -54
- package/dist/adaptors/testing.d.mts.map +1 -1
- package/dist/adaptors/testing.mjs +726 -78
- package/dist/adaptors/testing.mjs.map +1 -1
- package/dist/auth-BMCJN30Y.d.cts +268 -0
- package/dist/auth-BMCJN30Y.d.cts.map +1 -0
- package/dist/auth-D_0788uW.d.mts +268 -0
- package/dist/auth-D_0788uW.d.mts.map +1 -0
- package/dist/auth.cjs +301 -33
- package/dist/auth.cjs.map +1 -1
- package/dist/auth.d.cts +2 -108
- package/dist/auth.d.mts +2 -108
- package/dist/auth.mjs +289 -27
- package/dist/auth.mjs.map +1 -1
- package/dist/{cache-BrRz3fEB.d.mts → cache-5QZzh5Er.d.mts} +3 -6
- package/dist/cache-5QZzh5Er.d.mts.map +1 -0
- package/dist/{cache-BtZY_tHe.d.cts → cache-DnGDGly3.d.cts} +3 -6
- package/dist/cache-DnGDGly3.d.cts.map +1 -0
- package/dist/cache.cjs +68 -2
- package/dist/cache.cjs.map +1 -0
- package/dist/cache.d.cts +1 -2
- package/dist/cache.d.mts +1 -2
- package/dist/cache.mjs +67 -2
- package/dist/cache.mjs.map +1 -0
- package/dist/cipher-C1lEFX63.mjs +225 -0
- package/dist/cipher-C1lEFX63.mjs.map +1 -0
- package/dist/cipher-CVxfwLjk.cjs +332 -0
- package/dist/cipher-CVxfwLjk.cjs.map +1 -0
- package/dist/cipher-DSDxPRIp.d.cts +106 -0
- package/dist/cipher-DSDxPRIp.d.cts.map +1 -0
- package/dist/cipher-DSDxPRIp.d.mts +106 -0
- package/dist/cipher-DSDxPRIp.d.mts.map +1 -0
- package/dist/{clone-DblgEZZa.mjs → clone-EKNovYHu.mjs} +3 -3
- package/dist/clone-EKNovYHu.mjs.map +1 -0
- package/dist/{clone-Dy0cR2SZ.cjs → clone-UGJpvQnL.cjs} +7 -8
- package/dist/clone-UGJpvQnL.cjs.map +1 -0
- package/dist/{construct-interface-D9d4Gm4p.d.cts → construct-interface-B1AfqRl4.d.cts} +42 -11
- package/dist/construct-interface-B1AfqRl4.d.cts.map +1 -0
- package/dist/{construct-interface-g5GM5pwR.d.mts → construct-interface-ZvYQbivO.d.mts} +42 -11
- package/dist/construct-interface-ZvYQbivO.d.mts.map +1 -0
- package/dist/construct-interface.cjs +113 -7
- package/dist/construct-interface.cjs.map +1 -0
- package/dist/construct-interface.d.cts +2 -2
- package/dist/construct-interface.d.mts +2 -2
- package/dist/construct-interface.mjs +106 -2
- package/dist/construct-interface.mjs.map +1 -0
- package/dist/credential-DYymbp_7.cjs +257 -0
- package/dist/credential-DYymbp_7.cjs.map +1 -0
- package/dist/credential-DfSAOOdY.mjs +222 -0
- package/dist/credential-DfSAOOdY.mjs.map +1 -0
- package/dist/credential.cjs +8 -96
- package/dist/credential.d.cts +2 -61
- package/dist/credential.d.mts +2 -61
- package/dist/credential.mjs +2 -94
- package/dist/crons/index.cjs +129 -7
- package/dist/crons/index.cjs.map +1 -1
- package/dist/crons/index.d.cts +45 -11
- package/dist/crons/index.d.cts.map +1 -1
- package/dist/crons/index.d.mts +45 -11
- package/dist/crons/index.d.mts.map +1 -1
- package/dist/crons/index.mjs +127 -8
- package/dist/crons/index.mjs.map +1 -1
- package/dist/database/kysely.cjs +4 -181
- package/dist/database/kysely.d.cts +2 -152
- package/dist/database/kysely.d.mts +2 -152
- package/dist/database/kysely.mjs +2 -180
- package/dist/email.cjs +25 -12
- package/dist/email.cjs.map +1 -1
- package/dist/email.d.cts +3 -7
- package/dist/email.d.cts.map +1 -1
- package/dist/email.d.mts +4 -8
- package/dist/email.d.mts.map +1 -1
- package/dist/email.mjs +16 -3
- package/dist/email.mjs.map +1 -1
- package/dist/encryption/kms.cjs +95 -0
- package/dist/encryption/kms.cjs.map +1 -0
- package/dist/encryption/kms.d.cts +7 -0
- package/dist/encryption/kms.d.cts.map +1 -0
- package/dist/encryption/kms.d.mts +7 -0
- package/dist/encryption/kms.d.mts.map +1 -0
- package/dist/encryption/kms.mjs +93 -0
- package/dist/encryption/kms.mjs.map +1 -0
- package/dist/encryption.cjs +116 -0
- package/dist/encryption.cjs.map +1 -0
- package/dist/encryption.d.cts +37 -0
- package/dist/encryption.d.cts.map +1 -0
- package/dist/encryption.d.mts +37 -0
- package/dist/encryption.d.mts.map +1 -0
- package/dist/encryption.mjs +101 -0
- package/dist/encryption.mjs.map +1 -0
- package/dist/endpoints/index.cjs +27 -16
- package/dist/endpoints/index.d.cts +105 -7
- package/dist/endpoints/index.d.cts.map +1 -0
- package/dist/endpoints/index.d.mts +105 -7
- package/dist/endpoints/index.d.mts.map +1 -0
- package/dist/endpoints/index.mjs +6 -10
- package/dist/expire-C586zznE.d.cts +38 -0
- package/dist/expire-C586zznE.d.cts.map +1 -0
- package/dist/expire-C586zznE.d.mts +38 -0
- package/dist/expire-C586zznE.d.mts.map +1 -0
- package/dist/expire-CieftS01.cjs +67 -0
- package/dist/expire-CieftS01.cjs.map +1 -0
- package/dist/expire-CpzUAfr9.mjs +50 -0
- package/dist/expire-CpzUAfr9.mjs.map +1 -0
- package/dist/external-api.cjs +106 -0
- package/dist/external-api.cjs.map +1 -0
- package/dist/external-api.d.cts +2 -0
- package/dist/external-api.d.mts +2 -0
- package/dist/external-api.mjs +103 -0
- package/dist/external-api.mjs.map +1 -0
- package/dist/fake-B7rvi4Qp.d.cts +201 -0
- package/dist/fake-B7rvi4Qp.d.cts.map +1 -0
- package/dist/fake-JXbkdao8.d.mts +201 -0
- package/dist/fake-JXbkdao8.d.mts.map +1 -0
- package/dist/file-server.cjs +66 -11
- package/dist/file-server.cjs.map +1 -1
- package/dist/file-server.d.cts +25 -10
- package/dist/file-server.d.cts.map +1 -1
- package/dist/file-server.d.mts +25 -10
- package/dist/file-server.d.mts.map +1 -1
- package/dist/file-server.mjs +58 -4
- package/dist/file-server.mjs.map +1 -1
- package/dist/functions/index.cjs +3 -6
- package/dist/functions/index.d.cts +3 -4
- package/dist/functions/index.d.mts +3 -4
- package/dist/functions/index.mjs +2 -6
- package/dist/{functions-14lpEFL4.mjs → functions-CTI-hDem.mjs} +376 -238
- package/dist/{functions-14lpEFL4.mjs.map → functions-CTI-hDem.mjs.map} +1 -1
- package/dist/{functions-i_la-N5r.cjs → functions-D7O5SGVc.cjs} +414 -264
- package/dist/functions-D7O5SGVc.cjs.map +1 -0
- package/dist/index-Cd2w-DRL.d.cts +115 -0
- package/dist/index-Cd2w-DRL.d.cts.map +1 -0
- package/dist/index-DdRjYhiJ.d.cts +119 -0
- package/dist/index-DdRjYhiJ.d.cts.map +1 -0
- package/dist/index-DdRjYhiJ.d.mts +119 -0
- package/dist/index-DdRjYhiJ.d.mts.map +1 -0
- package/dist/index-aBIcAiH5.d.mts +115 -0
- package/dist/index-aBIcAiH5.d.mts.map +1 -0
- package/dist/index.cjs +6 -3
- package/dist/index.d.cts +27 -4
- package/dist/index.d.cts.map +1 -0
- package/dist/index.d.mts +27 -4
- package/dist/index.d.mts.map +1 -0
- package/dist/index.mjs +3 -3
- package/dist/kysely-BHYV-WC-.d.cts +216 -0
- package/dist/kysely-BHYV-WC-.d.cts.map +1 -0
- package/dist/kysely-CAW3QSqp.d.mts +216 -0
- package/dist/kysely-CAW3QSqp.d.mts.map +1 -0
- package/dist/kysely-Cs4uPO8k.mjs +371 -0
- package/dist/kysely-Cs4uPO8k.mjs.map +1 -0
- package/dist/kysely-CukArHJ0.cjs +384 -0
- package/dist/kysely-CukArHJ0.cjs.map +1 -0
- package/dist/{telemetry-C3L0iS28.d.cts → lambdaTelemetry-8vnmVZQ5.d.cts} +3 -6
- package/dist/lambdaTelemetry-8vnmVZQ5.d.cts.map +1 -0
- package/dist/{telemetry-D7bVFLGi.d.mts → lambdaTelemetry-8vnmVZQ5.d.mts} +3 -6
- package/dist/lambdaTelemetry-8vnmVZQ5.d.mts.map +1 -0
- package/dist/mobile-app.cjs +74 -0
- package/dist/mobile-app.cjs.map +1 -0
- package/dist/mobile-app.d.cts +73 -0
- package/dist/mobile-app.d.cts.map +1 -0
- package/dist/mobile-app.d.mts +73 -0
- package/dist/mobile-app.d.mts.map +1 -0
- package/dist/mobile-app.mjs +73 -0
- package/dist/mobile-app.mjs.map +1 -0
- package/dist/object-storage.cjs +26 -11
- package/dist/object-storage.cjs.map +1 -1
- package/dist/object-storage.d.cts +12 -7
- package/dist/object-storage.d.cts.map +1 -1
- package/dist/object-storage.d.mts +12 -7
- package/dist/object-storage.d.mts.map +1 -1
- package/dist/object-storage.mjs +18 -5
- package/dist/object-storage.mjs.map +1 -1
- package/dist/queue/index.cjs +6 -189
- package/dist/queue/index.d.cts +3 -60
- package/dist/queue/index.d.mts +3 -60
- package/dist/queue/index.mjs +3 -186
- package/dist/random-password.cjs +86 -0
- package/dist/random-password.cjs.map +1 -0
- package/dist/random-password.d.cts +30 -0
- package/dist/random-password.d.cts.map +1 -0
- package/dist/random-password.d.mts +30 -0
- package/dist/random-password.d.mts.map +1 -0
- package/dist/random-password.mjs +84 -0
- package/dist/random-password.mjs.map +1 -0
- package/dist/{lazyAccessors-BoJN3SMd.mjs → readRequestBody-BTIl3k-D.mjs} +117 -60
- package/dist/readRequestBody-BTIl3k-D.mjs.map +1 -0
- package/dist/readRequestBody-Dej_L3c4.cjs +342 -0
- package/dist/readRequestBody-Dej_L3c4.cjs.map +1 -0
- package/dist/requestLogger-BZcXwdBs.cjs +207 -0
- package/dist/requestLogger-BZcXwdBs.cjs.map +1 -0
- package/dist/requestLogger-pA4gi3E1.mjs +178 -0
- package/dist/requestLogger-pA4gi3E1.mjs.map +1 -0
- package/dist/rest-api.cjs +90 -59
- package/dist/rest-api.cjs.map +1 -1
- package/dist/rest-api.d.cts +70 -42
- package/dist/rest-api.d.cts.map +1 -1
- package/dist/rest-api.d.mts +70 -42
- package/dist/rest-api.d.mts.map +1 -1
- package/dist/rest-api.mjs +82 -51
- package/dist/rest-api.mjs.map +1 -1
- package/dist/{chunk-DWy1uDak.cjs → rolldown-runtime-y5ARvAq5.cjs} +14 -18
- package/dist/runSubscriber-BHvJ8POr.mjs +109 -0
- package/dist/runSubscriber-BHvJ8POr.mjs.map +1 -0
- package/dist/runSubscriber-D8nLXIv1.cjs +126 -0
- package/dist/runSubscriber-D8nLXIv1.cjs.map +1 -0
- package/dist/shutdown-BMJmAhSt.cjs +38 -0
- package/dist/shutdown-BMJmAhSt.cjs.map +1 -0
- package/dist/shutdown-C7xa8x9S.mjs +27 -0
- package/dist/shutdown-C7xa8x9S.mjs.map +1 -0
- package/dist/site.cjs +33 -7
- package/dist/site.cjs.map +1 -1
- package/dist/site.d.cts +17 -7
- package/dist/site.d.cts.map +1 -1
- package/dist/site.d.mts +17 -7
- package/dist/site.d.mts.map +1 -1
- package/dist/site.mjs +29 -3
- package/dist/site.mjs.map +1 -1
- package/dist/stages-BSCF19o2.d.cts +56 -0
- package/dist/stages-BSCF19o2.d.cts.map +1 -0
- package/dist/stages-BSCF19o2.d.mts +56 -0
- package/dist/stages-BSCF19o2.d.mts.map +1 -0
- package/dist/subscribers/index.cjs +118 -6
- package/dist/subscribers/index.cjs.map +1 -0
- package/dist/subscribers/index.d.cts +51 -6
- package/dist/subscribers/index.d.cts.map +1 -0
- package/dist/subscribers/index.d.mts +51 -6
- package/dist/subscribers/index.d.mts.map +1 -0
- package/dist/subscribers/index.mjs +115 -5
- package/dist/subscribers/index.mjs.map +1 -0
- package/dist/surfaceEnv-CNimK76p.cjs +56 -0
- package/dist/surfaceEnv-CNimK76p.cjs.map +1 -0
- package/dist/surfaceEnv-wMT5QzgZ.mjs +45 -0
- package/dist/surfaceEnv-wMT5QzgZ.mjs.map +1 -0
- package/dist/telemetry-B48RLjyk.d.cts +40 -0
- package/dist/telemetry-B48RLjyk.d.cts.map +1 -0
- package/dist/telemetry-BEoBn6GO.d.mts +40 -0
- package/dist/telemetry-BEoBn6GO.d.mts.map +1 -0
- package/dist/telemetry.cjs +56 -0
- package/dist/telemetry.cjs.map +1 -0
- package/dist/telemetry.d.cts +2 -0
- package/dist/telemetry.d.mts +2 -0
- package/dist/telemetry.mjs +55 -0
- package/dist/telemetry.mjs.map +1 -0
- package/dist/topic/index.cjs +3 -137
- package/dist/topic/index.d.cts +2 -4
- package/dist/topic/index.d.mts +2 -4
- package/dist/topic/index.mjs +2 -134
- package/dist/tracing-Bbj1uoFJ.mjs +127 -0
- package/dist/tracing-Bbj1uoFJ.mjs.map +1 -0
- package/dist/tracing-C0ooU0V2.cjs +150 -0
- package/dist/tracing-C0ooU0V2.cjs.map +1 -0
- package/dist/{types-BlAkSuGI.d.cts → types-DMuSQeLL.d.cts} +3 -5
- package/dist/types-DMuSQeLL.d.cts.map +1 -0
- package/dist/{types-aKksMEWL.d.mts → types-DMuSQeLL.d.mts} +3 -5
- package/dist/types-DMuSQeLL.d.mts.map +1 -0
- package/dist/types.d.cts +1 -1
- package/dist/types.d.mts +1 -1
- package/dist/types.mjs +1 -0
- package/dist/worker.cjs +59 -34
- package/dist/worker.cjs.map +1 -1
- package/dist/worker.d.cts +70 -45
- package/dist/worker.d.cts.map +1 -1
- package/dist/worker.d.mts +71 -45
- package/dist/worker.d.mts.map +1 -1
- package/dist/worker.mjs +54 -29
- package/dist/worker.mjs.map +1 -1
- package/package.json +115 -41
- package/dist/Construct-BD5neF7w.mjs.map +0 -1
- package/dist/Construct-C0ijr2qp.d.cts +0 -117
- package/dist/Construct-C0ijr2qp.d.cts.map +0 -1
- package/dist/Construct-Ct8nalEi.d.mts +0 -117
- package/dist/Construct-Ct8nalEi.d.mts.map +0 -1
- package/dist/Construct-CyS3RpTL.cjs.map +0 -1
- package/dist/Cron-DmQ8vQ4b.d.cts.map +0 -1
- package/dist/Cron-dh4rUgib.d.mts.map +0 -1
- package/dist/CronBuilder-BquXDbDI.d.cts +0 -44
- package/dist/CronBuilder-BquXDbDI.d.cts.map +0 -1
- package/dist/CronBuilder-CGgY2080.d.mts +0 -44
- package/dist/CronBuilder-CGgY2080.d.mts.map +0 -1
- package/dist/CronBuilder-CYKT5RiO.mjs.map +0 -1
- package/dist/CronBuilder-Da0C0edR.cjs.map +0 -1
- package/dist/Endpoint-BjWKinFA.d.mts.map +0 -1
- package/dist/Endpoint-DCQPMdUX.mjs.map +0 -1
- package/dist/Endpoint-DcWXE-SZ.cjs.map +0 -1
- package/dist/Endpoint-dav89W6-.d.cts.map +0 -1
- package/dist/EndpointFactory-CdWB7wPw.cjs.map +0 -1
- package/dist/EndpointFactory-CjV8F_lJ.mjs.map +0 -1
- package/dist/HonoEndpointAdaptor-DtL9j19R.cjs.map +0 -1
- package/dist/HonoEndpointAdaptor-P1ahhZHu.mjs.map +0 -1
- package/dist/Queue-D7ZuwBhy.d.cts.map +0 -1
- package/dist/Queue-gVGfi2Yk.d.mts.map +0 -1
- package/dist/Subscriber-2mEi0ImH.d.cts.map +0 -1
- package/dist/Subscriber-xTJ9ayPN.d.mts.map +0 -1
- package/dist/SubscriberBuilder-4OPehf2R.cjs.map +0 -1
- package/dist/SubscriberBuilder-BjkbeT9l.mjs.map +0 -1
- package/dist/SubscriberBuilder-Dptmo-1A.d.mts +0 -62
- package/dist/SubscriberBuilder-Dptmo-1A.d.mts.map +0 -1
- package/dist/SubscriberBuilder-waNhzjSM.d.cts +0 -62
- package/dist/SubscriberBuilder-waNhzjSM.d.cts.map +0 -1
- package/dist/Topic-19QeHBIR.d.cts +0 -91
- package/dist/Topic-19QeHBIR.d.cts.map +0 -1
- package/dist/Topic-DuFeqkBh.d.mts +0 -91
- package/dist/Topic-DuFeqkBh.d.mts.map +0 -1
- package/dist/auth.d.cts.map +0 -1
- package/dist/auth.d.mts.map +0 -1
- package/dist/cache-0ANvRQnD.mjs +0 -51
- package/dist/cache-0ANvRQnD.mjs.map +0 -1
- package/dist/cache-3WSvAulx.cjs +0 -57
- package/dist/cache-3WSvAulx.cjs.map +0 -1
- package/dist/cache-BrRz3fEB.d.mts.map +0 -1
- package/dist/cache-BtZY_tHe.d.cts.map +0 -1
- package/dist/clone-DblgEZZa.mjs.map +0 -1
- package/dist/clone-Dy0cR2SZ.cjs.map +0 -1
- package/dist/construct-interface-BfjcOD_E.cjs +0 -117
- package/dist/construct-interface-BfjcOD_E.cjs.map +0 -1
- package/dist/construct-interface-D9d4Gm4p.d.cts.map +0 -1
- package/dist/construct-interface-Z4CpS8tK.mjs +0 -81
- package/dist/construct-interface-Z4CpS8tK.mjs.map +0 -1
- package/dist/construct-interface-g5GM5pwR.d.mts.map +0 -1
- package/dist/credential.cjs.map +0 -1
- package/dist/credential.d.cts.map +0 -1
- package/dist/credential.d.mts.map +0 -1
- package/dist/credential.mjs.map +0 -1
- package/dist/database/kysely.cjs.map +0 -1
- package/dist/database/kysely.d.cts.map +0 -1
- package/dist/database/kysely.d.mts.map +0 -1
- package/dist/database/kysely.mjs.map +0 -1
- package/dist/functions-i_la-N5r.cjs.map +0 -1
- package/dist/index-Bd5FqCoe.d.cts.map +0 -1
- package/dist/index-BknhM6Ux.d.mts +0 -31
- package/dist/index-BknhM6Ux.d.mts.map +0 -1
- package/dist/index-CBSfrowv.d.cts +0 -31
- package/dist/index-CBSfrowv.d.cts.map +0 -1
- package/dist/index-D24Xm79M.d.cts +0 -171
- package/dist/index-D24Xm79M.d.cts.map +0 -1
- package/dist/index-_ajboYxK.d.mts +0 -171
- package/dist/index-_ajboYxK.d.mts.map +0 -1
- package/dist/index-lAO9egTb.d.mts.map +0 -1
- package/dist/lazyAccessors-BoJN3SMd.mjs.map +0 -1
- package/dist/lazyAccessors-e3j2oE2m.cjs +0 -274
- package/dist/lazyAccessors-e3j2oE2m.cjs.map +0 -1
- package/dist/processAudits-CGqttuXm.cjs +0 -92
- package/dist/processAudits-CGqttuXm.cjs.map +0 -1
- package/dist/processAudits-Dmts9H_b.mjs +0 -80
- package/dist/processAudits-Dmts9H_b.mjs.map +0 -1
- package/dist/queue/index.cjs.map +0 -1
- package/dist/queue/index.d.cts.map +0 -1
- package/dist/queue/index.d.mts.map +0 -1
- package/dist/queue/index.mjs.map +0 -1
- package/dist/surfaceEnv-BFXEms2f.cjs +0 -39
- package/dist/surfaceEnv-BFXEms2f.cjs.map +0 -1
- package/dist/surfaceEnv-C3Ktahea.mjs +0 -27
- package/dist/surfaceEnv-C3Ktahea.mjs.map +0 -1
- package/dist/telemetry-C3L0iS28.d.cts.map +0 -1
- package/dist/telemetry-D7bVFLGi.d.mts.map +0 -1
- package/dist/topic/index.cjs.map +0 -1
- package/dist/topic/index.mjs.map +0 -1
- package/dist/types-BlAkSuGI.d.cts.map +0 -1
- package/dist/types-aKksMEWL.d.mts.map +0 -1
package/dist/worker.cjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worker.cjs","names":["id: ConstructName<TName>","config: WorkerConfig","dependencies: readonly Dependency[]","scheduleStore?: Consumable<string, unknown>","DEFAULT_LOGGER","source: Consumable<TDbName, T>","schedule: ScheduleExpression","CronBuilder","topic: Topic<TTopicName, TEvents>","SubscriberBuilder","service: Service<TPubName, T> | Consumable<TPubName, T>","schema: T","ms: number","mb: number","constructs: T","services: T","FunctionBuilder","constructs: readonly Declarable[]","edgeTo","builder: T"],"sources":["../src/worker.ts"],"sourcesContent":["/**\n * A process with no port.\n *\n * `RestApi` is the process that answers HTTP. This is the one that does not —\n * the thing that runs a schedule, drains a queue, consumes a topic. Until it\n * existed, those had nowhere to say they belonged: a cron declared a schedule\n * and nothing else, and which container ran it was decided by the directory the\n * file sat in. A glob owned it.\n *\n * The cost of that shows up in the scaffolds. `gkm init --template worker` —\n * a project that is background jobs and nothing else — declared\n * `new RestApi('Api', { defaultAuthorizer: 'none', logger })`: an HTTP surface\n * with no HTTP on it, written because it was the only construct that made an\n * app exist and the only way to get a logger into the generated runtime.\n *\n * It takes no authorizer, and that is the tell that these are two constructs\n * rather than one with a flag: a `RestApi` needs one because an HTTP surface\n * can ship open by omission, and nothing reaches a worker from outside.\n *\n * ## Crons on a server target need a database\n *\n * A cron becomes an EventBridge rule on AWS and nothing here is consulted. A\n * server has nothing firing its crons but itself, and a process that schedules\n * in memory fires every job once per replica while reporting success — so the\n * schedule is kept in Postgres, and the worker says which one with\n * `.database(db)`.\n *\n * A worker with crons and no `.database(…)` schedules nothing on a server\n * target and says so at startup. That is a limitation of workers today rather\n * than a design: the store could be a cache, or something the target\n * provisions, and Postgres is what exists.\n *\n * It is not an app. A worker names the process that runs its crons and\n * subscribers, and that process is the app's server — the same one the\n * endpoints run in, minus the HTTP surface. Giving a worker a container of its\n * own made a second thing to build, deploy and keep alive for work that was\n * always going to run somewhere already. Declare as many as the shape of the\n * work wants: they are groupings, not deployments.\n *\n * @example\n * ```ts\n * // constructs/worker.ts\n * import { Worker } from '@geekmidas/constructs/worker';\n * import { logger } from './logger.js';\n *\n * export const worker = new Worker('Worker', { logger }).calls([database]);\n *\n * // crons/cleanup.ts\n * import { worker } from '@acme/constructs/worker.js';\n *\n * export const cleanup = worker\n * .cron('rate(1 day)')\n * .handle(async ({ logger }) => { … });\n * ```\n */\n\nimport type { EnvironmentParser } from '@geekmidas/envkit';\nimport type { EventPublisher } from '@geekmidas/events';\nimport type { Logger } from '@geekmidas/logger';\nimport { DEFAULT_LOGGER } from '@geekmidas/logger/console';\nimport {\n\ttype ConstructName,\n\tcanonicalId,\n\ttype Declaration,\n\ttype Dependency,\n} from '@geekmidas/manifest';\nimport type { ComposableStandardSchema } from '@geekmidas/schema';\nimport type { Service } from '@geekmidas/services';\nimport type { StandardSchemaV1 } from '@standard-schema/spec';\nimport {\n\ttype Consumable,\n\ttype Declarable,\n\tedgeTo,\n} from './construct-interface';\nimport type { ScheduleExpression } from './crons/Cron';\nimport { CronBuilder } from './crons/CronBuilder';\nimport { envParserFor } from './endpoints/surfaceEnv';\nimport { FunctionBuilder } from './functions/FunctionBuilder';\nimport { SubscriberBuilder } from './subscribers/SubscriberBuilder';\nimport type { Topic, TopicEvents } from './topic/Topic';\n\nexport interface WorkerConfig {\n\t/**\n\t * The logger everything built from this worker runs with.\n\t *\n\t * The actual logger, not a path to one — the same reason `RestApi` takes\n\t * one. Every cron and subscriber in a scaffolded project used to open with\n\t * `import { logger } from '…/constructs/logger.js'`, which is the line this\n\t * removes.\n\t */\n\tlogger?: Logger;\n\t/**\n\t * The environment parser everything built from this worker runs with.\n\t *\n\t * Defaults to `process.env` merged with the credentials `gkm dev` injected,\n\t * which is what an application's own `config/env.ts` always was.\n\t */\n\tenvParser?: EnvironmentParser<{}>;\n}\n\nexport class Worker<TName extends string = string>\n\timplements Declarable<TName>\n{\n\treadonly id: TName;\n\n\t/** Always defined — the worker's own, or the console logger. */\n\treadonly logger: Logger;\n\n\t/** Always defined, and normally the default. */\n\treadonly envParser: EnvironmentParser<{}>;\n\n\t/**\n\t * Where this worker's schedules live, when it has crons and a server runs\n\t * them. `undefined` until `.database(…)` says.\n\t */\n\treadonly scheduleStore?: Consumable<string, unknown>;\n\n\tconstructor(\n\t\tid: ConstructName<TName>,\n\t\tprivate readonly config: WorkerConfig = {},\n\t\t/** Internal: how `.calls()` carries edges into the copy it returns. */\n\t\tprivate readonly dependencies: readonly Dependency[] = [],\n\t\tscheduleStore?: Consumable<string, unknown>,\n\t) {\n\t\tconst canonical = canonicalId(id as string);\n\n\t\tthis.id = canonical as TName;\n\t\tthis.logger = config.logger ?? DEFAULT_LOGGER;\n\t\tthis.envParser = envParserFor(\n\t\t\tconfig.envParser\n\t\t\t\t? { id: canonical, envParser: config.envParser }\n\t\t\t\t: undefined,\n\t\t);\n\t\tthis.scheduleStore = scheduleStore;\n\t}\n\n\t/**\n\t * The database this worker keeps its schedules in.\n\t *\n\t * Only a server target uses it. On AWS a cron is an EventBridge rule\n\t * invoking a Lambda and nothing here is consulted — but a server has nothing\n\t * firing its crons except itself, and a process that schedules in memory\n\t * fires every job once per replica while reporting that all is well.\n\t *\n\t * So the store is declared rather than discovered. It could have been\n\t * inferred — from a database the app happens to declare, or from the events\n\t * backend when that backend is pg-boss — and both would work until an app\n\t * had two databases, or moved its events to SNS, at which point the\n\t * schedules would quietly move or stop. Naming it is one line and cannot\n\t * drift.\n\t *\n\t * @example\n\t * ```ts\n\t * export const jobs = new Worker('Jobs', { logger }).database(database);\n\t * ```\n\t */\n\tdatabase<T, TDbName extends string>(\n\t\tsource: Consumable<TDbName, T>,\n\t): Worker<TName> {\n\t\treturn new Worker<TName>(\n\t\t\tthis.id as ConstructName<TName>,\n\t\t\tthis.config,\n\t\t\t[...this.dependencies, edgeTo(source)],\n\t\t\tsource as unknown as Consumable<string, unknown>,\n\t\t);\n\t}\n\n\t/**\n\t * A scheduled runnable.\n\t *\n\t * @example `worker.cron('rate(1 day)').handle(async ({ logger }) => { … })`\n\t */\n\tcron(schedule: ScheduleExpression) {\n\t\treturn this.own(new CronBuilder().logger(this.logger)).schedule(schedule);\n\t}\n\n\t/**\n\t * A runnable that consumes a topic.\n\t *\n\t * Binding is not publishing: a consumer is handed the topic's event types\n\t * and no connection string it could publish with. Chain `.publishes(…)` when\n\t * the handler emits follow-up events, which is the only reason it would need\n\t * one.\n\t *\n\t * @example `worker.topic(users).subscribe(['user.created']).handle(…)`\n\t */\n\ttopic<TTopicName extends string, TEvents extends TopicEvents>(\n\t\ttopic: Topic<TTopicName, TEvents>,\n\t) {\n\t\treturn this.own(new SubscriberBuilder().logger(this.logger)).topic(topic);\n\t}\n\n\t/**\n\t * A runnable that consumes events typed from a publisher service.\n\t *\n\t * The older of the two ways to bind a subscriber, kept for a project whose\n\t * events come from a hand-written publisher rather than a `Topic`\n\t * construct. `topic()` is the one to reach for: it types the events the same\n\t * way and hands the consumer no connection string it could publish with.\n\t */\n\tpublisher<T extends EventPublisher<any>, TPubName extends string>(\n\t\tservice: Service<TPubName, T> | Consumable<TPubName, T>,\n\t) {\n\t\treturn this.own(new SubscriberBuilder().logger(this.logger)).publisher(\n\t\t\tservice as never,\n\t\t);\n\t}\n\n\t/**\n\t * Everything below builds a function — the runnable with no schedule and no\n\t * topic, invoked by something else.\n\t *\n\t * These sit on the worker rather than behind a `functions` namespace because\n\t * the namespace was a hop that said nothing: `worker.functions.input(…)`\n\t * names a collection to reach one member of it. What kind of runnable is\n\t * being built is decided by which of these is called first — a schedule\n\t * makes a cron, a topic makes a subscriber, and anything else makes a\n\t * function.\n\t */\n\tinput<T extends ComposableStandardSchema>(schema: T) {\n\t\treturn this.functions.input(schema);\n\t}\n\n\toutput<T extends StandardSchemaV1>(schema: T) {\n\t\treturn this.functions.output(schema);\n\t}\n\n\ttimeout(ms: number) {\n\t\treturn this.functions.timeout(ms);\n\t}\n\n\tmemorySize(mb: number) {\n\t\treturn this.functions.memorySize(mb);\n\t}\n\n\tdependsOn<const T extends readonly Consumable[]>(constructs: T) {\n\t\treturn this.functions.dependsOn(constructs);\n\t}\n\n\tservices<T extends Service[]>(services: T) {\n\t\treturn this.functions.services(services);\n\t}\n\n\t/**\n\t * A function with no input schema — the shortest runnable there is.\n\t *\n\t * @example `worker.handle(async ({ logger }) => { … })`\n\t */\n\thandle(\n\t\t...args: Parameters<\n\t\t\tReturnType<Worker<TName>['schemalessFunction']>['handle']\n\t\t>\n\t) {\n\t\treturn this.schemalessFunction().handle(...args);\n\t}\n\n\t/** The builder `handle` delegates to, named so its type can be referred to. */\n\tprivate schemalessFunction() {\n\t\treturn this.functions;\n\t}\n\n\t/** The function builder the delegating methods above are built on. */\n\tprivate get functions() {\n\t\treturn this.own(new FunctionBuilder().logger(this.logger));\n\t}\n\n\t/**\n\t * Resources and surfaces this worker calls.\n\t *\n\t * Not `.dependsOn()`: this records the edge that derives the worker's\n\t * environment and its access, the same distinction `RestApi.calls()` draws.\n\t */\n\tcalls(constructs: readonly Declarable[]): Worker<TName> {\n\t\treturn new Worker<TName>(\n\t\t\tthis.id as ConstructName<TName>,\n\t\t\tthis.config,\n\t\t\t[...this.dependencies, ...constructs.map(edgeTo)],\n\t\t\tthis.scheduleStore,\n\t\t);\n\t}\n\n\t/**\n\t * Stamps this worker's id onto a builder, so everything built from it says\n\t * which process runs it.\n\t */\n\tprivate own<T extends { _owner?: string; _scheduleStore?: unknown }>(\n\t\tbuilder: T,\n\t): T {\n\t\tbuilder._owner = this.id;\n\t\tbuilder._scheduleStore = this.scheduleStore;\n\n\t\treturn builder;\n\t}\n\n\tdeclare(): Declaration[] {\n\t\treturn [\n\t\t\t{\n\t\t\t\tkind: 'worker',\n\t\t\t\tid: this.id,\n\t\t\t\t...(this.dependencies.length\n\t\t\t\t\t? { dependencies: this.dependencies }\n\t\t\t\t\t: {}),\n\t\t\t\t// Nothing calls a worker, so it publishes no address.\n\t\t\t\tprovides: [],\n\t\t\t},\n\t\t];\n\t}\n}\n"],"mappings":";;;;;;;;;;;;AAoGA,IAAa,SAAb,MAAa,OAEb;CACC,AAAS;;CAGT,AAAS;;CAGT,AAAS;;;;;CAMT,AAAS;CAET,YACCA,IACiBC,SAAuB,CAAE,GAEzBC,eAAsC,CAAE,GACzDC,eACC;EAJgB;EAEA;EAGjB,MAAM,YAAY,sCAAY,GAAa;AAE3C,OAAK,KAAK;AACV,OAAK,SAAS,OAAO,UAAUC;AAC/B,OAAK,YAAY,gCAChB,OAAO,YACJ;GAAE,IAAI;GAAW,WAAW,OAAO;EAAW,WAEjD;AACD,OAAK,gBAAgB;CACrB;;;;;;;;;;;;;;;;;;;;;CAsBD,SACCC,QACgB;AAChB,SAAO,IAAI,OACV,KAAK,IACL,KAAK,QACL,CAAC,GAAG,KAAK,cAAc,mCAAO,OAAO,AAAC,GACtC;CAED;;;;;;CAOD,KAAKC,UAA8B;AAClC,SAAO,KAAK,IAAI,IAAIC,kCAAc,OAAO,KAAK,OAAO,CAAC,CAAC,SAAS,SAAS;CACzE;;;;;;;;;;;CAYD,MACCC,OACC;AACD,SAAO,KAAK,IAAI,IAAIC,8CAAoB,OAAO,KAAK,OAAO,CAAC,CAAC,MAAM,MAAM;CACzE;;;;;;;;;CAUD,UACCC,SACC;AACD,SAAO,KAAK,IAAI,IAAID,8CAAoB,OAAO,KAAK,OAAO,CAAC,CAAC,UAC5D,QACA;CACD;;;;;;;;;;;;CAaD,MAA0CE,QAAW;AACpD,SAAO,KAAK,UAAU,MAAM,OAAO;CACnC;CAED,OAAmCA,QAAW;AAC7C,SAAO,KAAK,UAAU,OAAO,OAAO;CACpC;CAED,QAAQC,IAAY;AACnB,SAAO,KAAK,UAAU,QAAQ,GAAG;CACjC;CAED,WAAWC,IAAY;AACtB,SAAO,KAAK,UAAU,WAAW,GAAG;CACpC;CAED,UAAiDC,YAAe;AAC/D,SAAO,KAAK,UAAU,UAAU,WAAW;CAC3C;CAED,SAA8BC,UAAa;AAC1C,SAAO,KAAK,UAAU,SAAS,SAAS;CACxC;;;;;;CAOD,OACC,GAAG,MAGF;AACD,SAAO,KAAK,oBAAoB,CAAC,OAAO,GAAG,KAAK;CAChD;;CAGD,AAAQ,qBAAqB;AAC5B,SAAO,KAAK;CACZ;;CAGD,IAAY,YAAY;AACvB,SAAO,KAAK,IAAI,IAAIC,oCAAkB,OAAO,KAAK,OAAO,CAAC;CAC1D;;;;;;;CAQD,MAAMC,YAAkD;AACvD,SAAO,IAAI,OACV,KAAK,IACL,KAAK,QACL,CAAC,GAAG,KAAK,cAAc,GAAG,WAAW,IAAIC,mCAAO,AAAC,GACjD,KAAK;CAEN;;;;;CAMD,AAAQ,IACPC,SACI;AACJ,UAAQ,SAAS,KAAK;AACtB,UAAQ,iBAAiB,KAAK;AAE9B,SAAO;CACP;CAED,UAAyB;AACxB,SAAO,CACN;GACC,MAAM;GACN,IAAI,KAAK;GACT,GAAI,KAAK,aAAa,SACnB,EAAE,cAAc,KAAK,aAAc,IACnC,CAAE;GAEL,UAAU,CAAE;EACZ,CACD;CACD;AACD"}
|
|
1
|
+
{"version":3,"file":"worker.cjs","names":["canonicalId","DEFAULT_LOGGER","envParserFor","edgeTo","CronBuilder","QueueBuilder","SubscriberBuilder","FunctionBuilder"],"sources":["../src/worker.ts"],"sourcesContent":["/**\n * A process with no port.\n *\n * `RestApi` is the process that answers HTTP. This is the one that does not —\n * the thing that runs a schedule, drains a queue, consumes a topic. Until it\n * existed, those had nowhere to say they belonged: a cron declared a schedule\n * and nothing else, and which container ran it was decided by the directory the\n * file sat in. A glob owned it.\n *\n * The cost of that shows up in the scaffolds. `gkm init --template worker` —\n * a project that is background jobs and nothing else — declared\n * `new RestApi('Api', { defaultAuthorizer: 'none', logger })`: an HTTP surface\n * with no HTTP on it, written because it was the only construct that made an\n * app exist and the only way to get a logger into the generated runtime.\n *\n * It takes no authorizer, and that is the tell that these are two constructs\n * rather than one with a flag: a `RestApi` needs one because an HTTP surface\n * can ship open by omission, and nothing reaches a worker from outside.\n *\n * ## Crons on a server target need a database\n *\n * A cron becomes an EventBridge rule on AWS and nothing here is consulted. A\n * server has nothing firing its crons but itself, and a process that schedules\n * in memory fires every job once per replica while reporting success — so the\n * schedule is kept in Postgres, and the worker says which one with\n * `.database(db)`.\n *\n * A worker with crons and no `.database(…)` schedules nothing on a server\n * target and says so at startup. That is a limitation of workers today rather\n * than a design: the store could be a cache, or something the target\n * provisions, and Postgres is what exists.\n *\n * ## The database is everything's default\n *\n * The same `.database(db)` is the database every cron, queue, subscriber and\n * function built from the worker receives as `db`. The work a worker groups is\n * usually work against one database, and naming it per handler was a line\n * repeated in every file that could drift in any one of them. A runnable that\n * works against another names its own with `.database(other)`, which replaces\n * the worker's — client and manifest edge both — rather than adding to it.\n *\n * It is not an app: it declares no path, and its code lives in an app's\n * directory. But it is a process of its own. On a server target each worker\n * with work to do is built — from the app that holds that work — into an image\n * that runs its crons, consumers and subscribers and answers only a health\n * check, so a slow queue never shares a process with the requests an API\n * serves. `gkm dev` still runs everything in one process. Declare as many as\n * the shape of the work wants: each is one container.\n *\n * @example\n * ```ts\n * // constructs/worker.ts\n * import { Worker } from '@geekmidas/constructs/worker';\n * import { logger } from './logger.js';\n *\n * export const worker = new Worker('Worker', { logger }).database(database);\n *\n * // crons/cleanup.ts\n * import { worker } from '@acme/constructs/worker.js';\n *\n * export const cleanup = worker\n * .cron('rate(1 day)')\n * .handle(async ({ db, logger }) => { … });\n *\n * // queues/reports.ts — against another database than the worker's\n * export const reports = worker\n * .queue('Reports')\n * .database(analytics)\n * .message(z.object({ id: z.uuid() }))\n * .handle(async ({ messages, db }) => { … });\n * ```\n */\n\nimport type { EnvironmentParser } from '@geekmidas/envkit';\nimport type { EventPublisher } from '@geekmidas/events';\nimport type { Logger } from '@geekmidas/logger';\nimport { DEFAULT_LOGGER } from '@geekmidas/logger/console';\nimport {\n\ttype ConstructName,\n\tcanonicalId,\n\ttype Declaration,\n\ttype Dependency,\n} from '@geekmidas/manifest';\nimport type { ComposableStandardSchema } from '@geekmidas/schema';\nimport type { Service } from '@geekmidas/services';\nimport type { StandardSchemaV1 } from '@standard-schema/spec';\nimport {\n\ttype Consumable,\n\ttype Declarable,\n\tedgeTo,\n} from './construct-interface';\nimport type { ScheduleExpression } from './crons/Cron';\nimport { CronBuilder } from './crons/CronBuilder';\nimport { envParserFor } from './endpoints/surfaceEnv';\nimport { FunctionBuilder } from './functions/FunctionBuilder';\nimport { QueueBuilder } from './queue/QueueBuilder';\nimport { SubscriberBuilder } from './subscribers/SubscriberBuilder';\nimport type { Telemetry } from './telemetry';\nimport type { Topic, TopicEvents } from './topic/Topic';\n\nexport interface WorkerConfig {\n\t/**\n\t * The logger everything built from this worker runs with.\n\t *\n\t * The actual logger, not a path to one — the same reason `RestApi` takes\n\t * one. Every cron and subscriber in a scaffolded project used to open with\n\t * `import { logger } from '…/constructs/logger.js'`, which is the line this\n\t * removes.\n\t */\n\tlogger?: Logger;\n\t/**\n\t * The environment parser everything built from this worker runs with.\n\t *\n\t * Defaults to `process.env` merged with the credentials `gkm dev` injected,\n\t * which is what an application's own `config/env.ts` always was.\n\t */\n\tenvParser?: EnvironmentParser<{}>;\n\t/**\n\t * What the worker's process emits — the `Telemetry` construct, passed like\n\t * the logger. An edge to the node: the deploy hands the process the\n\t * `OTEL_*` keys its stage resolves.\n\t */\n\ttelemetry?: Telemetry;\n}\n\nexport class Worker<\n\tTName extends string = string,\n\tTDatabase = undefined,\n\tTDatabaseServiceName extends string = string,\n> implements Declarable<TName>\n{\n\treadonly id: TName;\n\n\t/** Always defined — the worker's own, or the console logger. */\n\treadonly logger: Logger;\n\n\t/** Always defined, and normally the default. */\n\treadonly envParser: EnvironmentParser<{}>;\n\n\t/**\n\t * Where this worker's schedules live, when it has crons and a server runs\n\t * them — and the database everything built from it receives as `db`.\n\t * `undefined` until `.database(…)` says.\n\t */\n\treadonly scheduleStore?: Consumable<string, unknown>;\n\n\tconstructor(\n\t\tid: ConstructName<TName>,\n\t\tprivate readonly config: WorkerConfig = {},\n\t\t/** Internal: how `.calls()` carries edges into the copy it returns. */\n\t\tprivate readonly dependencies: readonly Dependency[] = [],\n\t\tscheduleStore?: Consumable<string, unknown>,\n\t) {\n\t\tconst canonical = canonicalId(id as string);\n\n\t\tthis.id = canonical as TName;\n\t\tthis.logger = config.logger ?? DEFAULT_LOGGER;\n\t\tthis.envParser = envParserFor(\n\t\t\tconfig.envParser\n\t\t\t\t? { id: canonical, envParser: config.envParser }\n\t\t\t\t: undefined,\n\t\t);\n\t\tthis.scheduleStore = scheduleStore;\n\t}\n\n\t/**\n\t * The database this worker keeps its schedules in, and the one everything\n\t * built from it — crons, queues, subscribers, functions — receives as `db`.\n\t * One of them that works against another database names it with its own\n\t * `.database(other)`, which replaces this one for that runnable alone.\n\t *\n\t * Only a server target uses it. On AWS a cron is an EventBridge rule\n\t * invoking a Lambda and nothing here is consulted — but a server has nothing\n\t * firing its crons except itself, and a process that schedules in memory\n\t * fires every job once per replica while reporting that all is well.\n\t *\n\t * So the store is declared rather than discovered. It could have been\n\t * inferred — from a database the app happens to declare, or from the events\n\t * backend when that backend is pg-boss — and both would work until an app\n\t * had two databases, or moved its events to SNS, at which point the\n\t * schedules would quietly move or stop. Naming it is one line and cannot\n\t * drift.\n\t *\n\t * @example\n\t * ```ts\n\t * export const jobs = new Worker('Jobs', { logger }).database(database);\n\t *\n\t * export const sweep = jobs\n\t * .cron('rate(1 hour)')\n\t * .handle(async ({ db }) => db.deleteFrom('sessions').execute());\n\t * ```\n\t */\n\tdatabase<T, TDbName extends string>(\n\t\tsource: Consumable<TDbName, T>,\n\t): Worker<TName, T, TDbName> {\n\t\treturn new Worker<TName, T, TDbName>(\n\t\t\tthis.id as ConstructName<TName>,\n\t\t\tthis.config,\n\t\t\t[...this.dependencies, edgeTo(source)],\n\t\t\tsource as unknown as Consumable<string, unknown>,\n\t\t);\n\t}\n\n\t/**\n\t * A scheduled runnable.\n\t *\n\t * @example `worker.cron('rate(1 day)').handle(async ({ logger }) => { … })`\n\t */\n\tcron(schedule: ScheduleExpression) {\n\t\treturn this.own(\n\t\t\tnew CronBuilder<\n\t\t\t\tComposableStandardSchema,\n\t\t\t\tService[],\n\t\t\t\tLogger,\n\t\t\t\tundefined,\n\t\t\t\tTDatabase,\n\t\t\t\tTDatabaseServiceName\n\t\t\t>().logger(this.logger),\n\t\t).schedule(schedule);\n\t}\n\n\t/**\n\t * A queue and its one consumer, run by this worker.\n\t *\n\t * One construct, because a queue has exactly one consumer: nothing else can\n\t * attach a second, or forget to attach the first. Producers send to it by\n\t * depending on it — `.dependsOn([emails])` makes `services.emails` the\n\t * publisher.\n\t *\n\t * @example\n\t * ```ts\n\t * export const emails = worker\n\t * .queue('Emails')\n\t * .message(z.object({ userId: z.uuid(), template: z.string() }))\n\t * .handle(async ({ messages, services }) => { … });\n\t * ```\n\t */\n\tqueue<TQueueName extends string>(name: TQueueName) {\n\t\treturn this.own(\n\t\t\tnew QueueBuilder<\n\t\t\t\tstring,\n\t\t\t\tundefined,\n\t\t\t\t[],\n\t\t\t\tLogger,\n\t\t\t\tTDatabase,\n\t\t\t\tTDatabaseServiceName\n\t\t\t>().logger(this.logger),\n\t\t).queue(name);\n\t}\n\n\t/**\n\t * A runnable that consumes a topic.\n\t *\n\t * Binding is not publishing: a consumer is handed the topic's event types\n\t * and no connection string it could publish with. A handler that emits\n\t * follow-up events depends on the topic it emits to —\n\t * `.dependsOn([orders])` — which is the only reason it would need one.\n\t *\n\t * @example `worker.topic(users).subscribe(['user.created']).handle(…)`\n\t */\n\ttopic<TTopicName extends string, TEvents extends TopicEvents>(\n\t\ttopic: Topic<TTopicName, TEvents>,\n\t) {\n\t\treturn this.own(\n\t\t\tnew SubscriberBuilder<\n\t\t\t\t[],\n\t\t\t\tLogger,\n\t\t\t\tundefined,\n\t\t\t\tundefined,\n\t\t\t\t[],\n\t\t\t\tTDatabase,\n\t\t\t\tTDatabaseServiceName\n\t\t\t>().logger(this.logger),\n\t\t).topic(topic);\n\t}\n\n\t/**\n\t * Everything below builds a function — the runnable with no schedule and no\n\t * topic, invoked by something else.\n\t *\n\t * These sit on the worker rather than behind a `functions` namespace because\n\t * the namespace was a hop that said nothing: `worker.functions.input(…)`\n\t * names a collection to reach one member of it. What kind of runnable is\n\t * being built is decided by which of these is called first — a schedule\n\t * makes a cron, a topic makes a subscriber, and anything else makes a\n\t * function.\n\t */\n\tinput<T extends ComposableStandardSchema>(schema: T) {\n\t\treturn this.functions.input(schema);\n\t}\n\n\toutput<T extends StandardSchemaV1>(schema: T) {\n\t\treturn this.functions.output(schema);\n\t}\n\n\ttimeout(ms: number) {\n\t\treturn this.functions.timeout(ms);\n\t}\n\n\tmemorySize(mb: number) {\n\t\treturn this.functions.memorySize(mb);\n\t}\n\n\tdependsOn<const T extends readonly Consumable[]>(constructs: T) {\n\t\treturn this.functions.dependsOn(constructs);\n\t}\n\n\tservices<T extends Service[]>(services: T) {\n\t\treturn this.functions.services(services);\n\t}\n\n\t/**\n\t * A function with no input schema — the shortest runnable there is.\n\t *\n\t * @example `worker.handle(async ({ logger }) => { … })`\n\t */\n\thandle(\n\t\t...args: Parameters<\n\t\t\tReturnType<\n\t\t\t\tWorker<TName, TDatabase, TDatabaseServiceName>['schemalessFunction']\n\t\t\t>['handle']\n\t\t>\n\t) {\n\t\treturn this.schemalessFunction().handle(...args);\n\t}\n\n\t/** The builder `handle` delegates to, named so its type can be referred to. */\n\tprivate schemalessFunction() {\n\t\treturn this.functions;\n\t}\n\n\t/** The function builder the delegating methods above are built on. */\n\tprivate get functions() {\n\t\treturn this.own(\n\t\t\tnew FunctionBuilder<\n\t\t\t\tany,\n\t\t\t\tundefined,\n\t\t\t\t[],\n\t\t\t\tLogger,\n\t\t\t\tundefined,\n\t\t\t\tstring,\n\t\t\t\tTDatabase,\n\t\t\t\tTDatabaseServiceName\n\t\t\t>().logger(this.logger),\n\t\t);\n\t}\n\n\t/**\n\t * Resources and surfaces this worker calls.\n\t *\n\t * Not `.dependsOn()`: this records the edge that derives the worker's\n\t * environment and its access, the same distinction `RestApi.calls()` draws.\n\t */\n\tcalls(\n\t\tconstructs: readonly Declarable[],\n\t): Worker<TName, TDatabase, TDatabaseServiceName> {\n\t\treturn new Worker<TName, TDatabase, TDatabaseServiceName>(\n\t\t\tthis.id as ConstructName<TName>,\n\t\t\tthis.config,\n\t\t\t[...this.dependencies, ...constructs.map(edgeTo)],\n\t\t\tthis.scheduleStore,\n\t\t);\n\t}\n\n\t/**\n\t * Stamps this worker's id onto a builder, so everything built from it says\n\t * which process runs it — and hands it the worker's database.\n\t *\n\t * The database goes through the builder's own `.database()` rather than\n\t * being written into its fields, so the default is recorded exactly as an\n\t * explicit one would be: the client the handler gets, and the edge the\n\t * manifest reads. That is also what lets a later `.database(other)` replace\n\t * it outright. The builder arrives already typed with this worker's\n\t * database; this is the runtime half of that.\n\t */\n\tprivate own<\n\t\tT extends {\n\t\t\t_owner?: string;\n\t\t\t_scheduleStore?: unknown;\n\t\t\tdatabase(source: Consumable<string, unknown>): unknown;\n\t\t},\n\t>(builder: T): T {\n\t\tconst owned = this.scheduleStore\n\t\t\t? (builder.database(this.scheduleStore) as T)\n\t\t\t: builder;\n\n\t\towned._owner = this.id;\n\t\towned._scheduleStore = this.scheduleStore;\n\n\t\treturn owned;\n\t}\n\n\tdeclare(): Declaration[] {\n\t\treturn [\n\t\t\t{\n\t\t\t\tkind: 'worker',\n\t\t\t\tid: this.id,\n\t\t\t\t...(this.dependencies.length\n\t\t\t\t\t? { dependencies: this.dependencies }\n\t\t\t\t\t: {}),\n\t\t\t\t...(this.config.telemetry\n\t\t\t\t\t? { telemetry: this.config.telemetry.id }\n\t\t\t\t\t: {}),\n\t\t\t\t// Nothing calls a worker, so it publishes no address.\n\t\t\t\tprovides: [],\n\t\t\t},\n\t\t];\n\t}\n}\n"],"mappings":";;;;;;;;;;AA6HA,IAAa,SAAb,MAAa,OAKb;CAkBmB;CAEA;CAnBlB;;CAGA;;CAGA;;;;;;CAOA;CAEA,YACC,IACA,SAAwC,CAAC,GAEzC,eAAuD,CAAC,GACxD,eACC;EAJgB,KAAA,SAAA;EAEA,KAAA,eAAA;EAGjB,MAAM,aAAA,GAAYA,oBAAAA,YAAAA,CAAY,EAAY;EAE1C,KAAK,KAAK;EACV,KAAK,SAAS,OAAO,UAAUC,0BAAAA;EAC/B,KAAK,YAAYC,mBAAAA,aAChB,OAAO,YACJ;GAAE,IAAI;GAAW,WAAW,OAAO;EAAU,IAC7C,KAAA,CACJ;EACA,KAAK,gBAAgB;CACtB;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA6BA,SACC,QAC4B;EAC5B,OAAO,IAAI,OACV,KAAK,IACL,KAAK,QACL,CAAC,GAAG,KAAK,cAAcC,4BAAAA,OAAO,MAAM,CAAC,GACrC,MACD;CACD;;;;;;CAOA,KAAK,UAA8B;EAClC,OAAO,KAAK,IACX,IAAIC,oBAAAA,YAOF,CAAC,CAAC,OAAO,KAAK,MAAM,CACvB,CAAC,CAAC,SAAS,QAAQ;CACpB;;;;;;;;;;;;;;;;;CAkBA,MAAiC,MAAkB;EAClD,OAAO,KAAK,IACX,IAAIC,qBAAAA,aAOF,CAAC,CAAC,OAAO,KAAK,MAAM,CACvB,CAAC,CAAC,MAAM,IAAI;CACb;;;;;;;;;;;CAYA,MACC,OACC;EACD,OAAO,KAAK,IACX,IAAIC,0BAAAA,kBAQF,CAAC,CAAC,OAAO,KAAK,MAAM,CACvB,CAAC,CAAC,MAAM,KAAK;CACd;;;;;;;;;;;;CAaA,MAA0C,QAAW;EACpD,OAAO,KAAK,UAAU,MAAM,MAAM;CACnC;CAEA,OAAmC,QAAW;EAC7C,OAAO,KAAK,UAAU,OAAO,MAAM;CACpC;CAEA,QAAQ,IAAY;EACnB,OAAO,KAAK,UAAU,QAAQ,EAAE;CACjC;CAEA,WAAW,IAAY;EACtB,OAAO,KAAK,UAAU,WAAW,EAAE;CACpC;CAEA,UAAiD,YAAe;EAC/D,OAAO,KAAK,UAAU,UAAU,UAAU;CAC3C;CAEA,SAA8B,UAAa;EAC1C,OAAO,KAAK,UAAU,SAAS,QAAQ;CACxC;;;;;;CAOA,OACC,GAAG,MAKF;EACD,OAAO,KAAK,mBAAmB,CAAC,CAAC,OAAO,GAAG,IAAI;CAChD;;CAGA,qBAA6B;EAC5B,OAAO,KAAK;CACb;;CAGA,IAAY,YAAY;EACvB,OAAO,KAAK,IACX,IAAIC,kBAAAA,gBASF,CAAC,CAAC,OAAO,KAAK,MAAM,CACvB;CACD;;;;;;;CAQA,MACC,YACiD;EACjD,OAAO,IAAI,OACV,KAAK,IACL,KAAK,QACL,CAAC,GAAG,KAAK,cAAc,GAAG,WAAW,IAAIJ,4BAAAA,MAAM,CAAC,GAChD,KAAK,aACN;CACD;;;;;;;;;;;;CAaA,IAME,SAAe;EAChB,MAAM,QAAQ,KAAK,gBACf,QAAQ,SAAS,KAAK,aAAa,IACpC;EAEH,MAAM,SAAS,KAAK;EACpB,MAAM,iBAAiB,KAAK;EAE5B,OAAO;CACR;CAEA,UAAyB;EACxB,OAAO,CACN;GACC,MAAM;GACN,IAAI,KAAK;GACT,GAAI,KAAK,aAAa,SACnB,EAAE,cAAc,KAAK,aAAa,IAClC,CAAC;GACJ,GAAI,KAAK,OAAO,YACb,EAAE,WAAW,KAAK,OAAO,UAAU,GAAG,IACtC,CAAC;GAEJ,UAAU,CAAC;EACZ,CACD;CACD;AACD"}
|
package/dist/worker.d.cts
CHANGED
|
@@ -1,24 +1,21 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import "./
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import "./
|
|
1
|
+
import { n as StandardSchemaV1 } from "./index-DdRjYhiJ.cjs";
|
|
2
|
+
import { c as Topic, l as TopicEvents, u as TopicMessage } from "./Construct-CFW0zjdD.cjs";
|
|
3
|
+
import { i as FunctionHandler, n as Function } from "./Function-B0uZhZnU.cjs";
|
|
4
|
+
import { c as ServicesOf, i as Declarable, r as Consumable } from "./construct-interface-B1AfqRl4.cjs";
|
|
5
|
+
import { t as FunctionBuilder } from "./index-Cd2w-DRL.cjs";
|
|
6
|
+
import { i as ScheduleExpression } from "./Cron-bdGRSROY.cjs";
|
|
7
|
+
import { n as Telemetry } from "./telemetry-B48RLjyk.cjs";
|
|
8
|
+
import { t as CronBuilder } from "./CronBuilder-B_24LZpn.cjs";
|
|
9
|
+
import { t as QueueBuilder } from "./QueueBuilder-MfpkJ3R9.cjs";
|
|
10
|
+
import { t as SubscriberBuilder } from "./SubscriberBuilder-BRa_nrmH.cjs";
|
|
11
|
+
import "./topic/index.cjs";
|
|
10
12
|
import { EnvironmentParser } from "@geekmidas/envkit";
|
|
11
|
-
import { EventPublisher } from "@geekmidas/events";
|
|
12
13
|
import { Logger } from "@geekmidas/logger";
|
|
13
14
|
import { ComposableStandardSchema } from "@geekmidas/schema";
|
|
14
15
|
import { Service } from "@geekmidas/services";
|
|
15
|
-
import { StandardSchemaV1 } from "@standard-schema/spec";
|
|
16
|
-
import * as _geekmidas_audit15 from "@geekmidas/audit";
|
|
17
16
|
import { ConstructName, Declaration, Dependency } from "@geekmidas/manifest";
|
|
18
|
-
|
|
19
17
|
//#region src/worker.d.ts
|
|
20
|
-
|
|
21
|
-
interface WorkerConfig {
|
|
18
|
+
export interface WorkerConfig {
|
|
22
19
|
/**
|
|
23
20
|
* The logger everything built from this worker runs with.
|
|
24
21
|
*
|
|
@@ -35,8 +32,14 @@ interface WorkerConfig {
|
|
|
35
32
|
* which is what an application's own `config/env.ts` always was.
|
|
36
33
|
*/
|
|
37
34
|
envParser?: EnvironmentParser<{}>;
|
|
35
|
+
/**
|
|
36
|
+
* What the worker's process emits — the `Telemetry` construct, passed like
|
|
37
|
+
* the logger. An edge to the node: the deploy hands the process the
|
|
38
|
+
* `OTEL_*` keys its stage resolves.
|
|
39
|
+
*/
|
|
40
|
+
telemetry?: Telemetry;
|
|
38
41
|
}
|
|
39
|
-
declare class Worker<TName extends string = string> implements Declarable<TName> {
|
|
42
|
+
export declare class Worker<TName extends string = string, TDatabase = undefined, TDatabaseServiceName extends string = string> implements Declarable<TName> {
|
|
40
43
|
private readonly config;
|
|
41
44
|
/** Internal: how `.calls()` carries edges into the copy it returns. */
|
|
42
45
|
private readonly dependencies;
|
|
@@ -47,13 +50,18 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
47
50
|
readonly envParser: EnvironmentParser<{}>;
|
|
48
51
|
/**
|
|
49
52
|
* Where this worker's schedules live, when it has crons and a server runs
|
|
50
|
-
* them
|
|
53
|
+
* them — and the database everything built from it receives as `db`.
|
|
54
|
+
* `undefined` until `.database(…)` says.
|
|
51
55
|
*/
|
|
52
56
|
readonly scheduleStore?: Consumable<string, unknown>;
|
|
53
|
-
constructor(id: ConstructName<TName>, config?: WorkerConfig,
|
|
57
|
+
constructor(id: ConstructName<TName>, config?: WorkerConfig,
|
|
58
|
+
/** Internal: how `.calls()` carries edges into the copy it returns. */
|
|
54
59
|
dependencies?: readonly Dependency[], scheduleStore?: Consumable<string, unknown>);
|
|
55
60
|
/**
|
|
56
|
-
* The database this worker keeps its schedules in
|
|
61
|
+
* The database this worker keeps its schedules in, and the one everything
|
|
62
|
+
* built from it — crons, queues, subscribers, functions — receives as `db`.
|
|
63
|
+
* One of them that works against another database names it with its own
|
|
64
|
+
* `.database(other)`, which replaces this one for that runnable alone.
|
|
57
65
|
*
|
|
58
66
|
* Only a server target uses it. On AWS a cron is an EventBridge rule
|
|
59
67
|
* invoking a Lambda and nothing here is consulted — but a server has nothing
|
|
@@ -70,35 +78,47 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
70
78
|
* @example
|
|
71
79
|
* ```ts
|
|
72
80
|
* export const jobs = new Worker('Jobs', { logger }).database(database);
|
|
81
|
+
*
|
|
82
|
+
* export const sweep = jobs
|
|
83
|
+
* .cron('rate(1 hour)')
|
|
84
|
+
* .handle(async ({ db }) => db.deleteFrom('sessions').execute());
|
|
73
85
|
* ```
|
|
74
86
|
*/
|
|
75
|
-
database<T, TDbName extends string>(source: Consumable<TDbName, T>): Worker<TName>;
|
|
87
|
+
database<T, TDbName extends string>(source: Consumable<TDbName, T>): Worker<TName, T, TDbName>;
|
|
76
88
|
/**
|
|
77
89
|
* A scheduled runnable.
|
|
78
90
|
*
|
|
79
91
|
* @example `worker.cron('rate(1 day)').handle(async ({ logger }) => { … })`
|
|
80
92
|
*/
|
|
81
|
-
cron(schedule: ScheduleExpression): CronBuilder<ComposableStandardSchema, Service
|
|
93
|
+
cron(schedule: ScheduleExpression): CronBuilder<ComposableStandardSchema, Service[], Logger, undefined, TDatabase, TDatabaseServiceName>;
|
|
82
94
|
/**
|
|
83
|
-
* A
|
|
95
|
+
* A queue and its one consumer, run by this worker.
|
|
84
96
|
*
|
|
85
|
-
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
88
|
-
*
|
|
97
|
+
* One construct, because a queue has exactly one consumer: nothing else can
|
|
98
|
+
* attach a second, or forget to attach the first. Producers send to it by
|
|
99
|
+
* depending on it — `.dependsOn([emails])` makes `services.emails` the
|
|
100
|
+
* publisher.
|
|
89
101
|
*
|
|
90
|
-
* @example
|
|
102
|
+
* @example
|
|
103
|
+
* ```ts
|
|
104
|
+
* export const emails = worker
|
|
105
|
+
* .queue('Emails')
|
|
106
|
+
* .message(z.object({ userId: z.uuid(), template: z.string() }))
|
|
107
|
+
* .handle(async ({ messages, services }) => { … });
|
|
108
|
+
* ```
|
|
91
109
|
*/
|
|
92
|
-
|
|
110
|
+
queue<TQueueName extends string>(name: TQueueName): QueueBuilder<TQueueName, undefined, [], Logger, TDatabase, TDatabaseServiceName>;
|
|
93
111
|
/**
|
|
94
|
-
* A runnable that consumes
|
|
112
|
+
* A runnable that consumes a topic.
|
|
95
113
|
*
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
99
|
-
*
|
|
114
|
+
* Binding is not publishing: a consumer is handed the topic's event types
|
|
115
|
+
* and no connection string it could publish with. A handler that emits
|
|
116
|
+
* follow-up events depends on the topic it emits to —
|
|
117
|
+
* `.dependsOn([orders])` — which is the only reason it would need one.
|
|
118
|
+
*
|
|
119
|
+
* @example `worker.topic(users).subscribe(['user.created']).handle(…)`
|
|
100
120
|
*/
|
|
101
|
-
|
|
121
|
+
topic<TTopicName extends string, TEvents extends TopicEvents>(topic: Topic<TTopicName, TEvents>): SubscriberBuilder<[], Logger, undefined, EventPublisher<TopicMessage<TEvents_1>>, [], TDatabase, TDatabaseServiceName>;
|
|
102
122
|
/**
|
|
103
123
|
* Everything below builds a function — the runnable with no schedule and no
|
|
104
124
|
* topic, invoked by something else.
|
|
@@ -110,18 +130,18 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
110
130
|
* makes a cron, a topic makes a subscriber, and anything else makes a
|
|
111
131
|
* function.
|
|
112
132
|
*/
|
|
113
|
-
input<T extends ComposableStandardSchema>(schema: T): FunctionBuilder<T, undefined, [], Logger, undefined, string,
|
|
114
|
-
output<T extends StandardSchemaV1>(schema: T): FunctionBuilder<
|
|
115
|
-
timeout(ms: number): FunctionBuilder<
|
|
116
|
-
memorySize(mb: number): FunctionBuilder<
|
|
117
|
-
dependsOn<const T extends readonly Consumable[]>(constructs: T): FunctionBuilder<
|
|
118
|
-
services<T extends Service[]>(services: T): FunctionBuilder<
|
|
133
|
+
input<T extends ComposableStandardSchema>(schema: T): FunctionBuilder<T, undefined, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
134
|
+
output<T extends StandardSchemaV1>(schema: T): FunctionBuilder<any, T, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
135
|
+
timeout(ms: number): FunctionBuilder<any, undefined, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
136
|
+
memorySize(mb: number): FunctionBuilder<any, undefined, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
137
|
+
dependsOn<const T extends readonly Consumable[]>(constructs: T): FunctionBuilder<any, undefined, [...ServicesOf<T>], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
138
|
+
services<T extends Service[]>(services: T): FunctionBuilder<any, undefined, [...T], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
119
139
|
/**
|
|
120
140
|
* A function with no input schema — the shortest runnable there is.
|
|
121
141
|
*
|
|
122
142
|
* @example `worker.handle(async ({ logger }) => { … })`
|
|
123
143
|
*/
|
|
124
|
-
handle(...args: Parameters<ReturnType<Worker<TName>['schemalessFunction']>['handle']>): Function<
|
|
144
|
+
handle(...args: Parameters<ReturnType<Worker<TName, TDatabase, TDatabaseServiceName>['schemalessFunction']>['handle']>): Function<any, [], Logger, undefined, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>, FunctionHandler<any, [], Logger, undefined, TDatabase, undefined, AuditableAction<string, unknown>>>;
|
|
125
145
|
/** The builder `handle` delegates to, named so its type can be referred to. */
|
|
126
146
|
private schemalessFunction;
|
|
127
147
|
/** The function builder the delegating methods above are built on. */
|
|
@@ -132,15 +152,20 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
132
152
|
* Not `.dependsOn()`: this records the edge that derives the worker's
|
|
133
153
|
* environment and its access, the same distinction `RestApi.calls()` draws.
|
|
134
154
|
*/
|
|
135
|
-
calls(constructs: readonly Declarable[]): Worker<TName>;
|
|
155
|
+
calls(constructs: readonly Declarable[]): Worker<TName, TDatabase, TDatabaseServiceName>;
|
|
136
156
|
/**
|
|
137
157
|
* Stamps this worker's id onto a builder, so everything built from it says
|
|
138
|
-
* which process runs it.
|
|
158
|
+
* which process runs it — and hands it the worker's database.
|
|
159
|
+
*
|
|
160
|
+
* The database goes through the builder's own `.database()` rather than
|
|
161
|
+
* being written into its fields, so the default is recorded exactly as an
|
|
162
|
+
* explicit one would be: the client the handler gets, and the edge the
|
|
163
|
+
* manifest reads. That is also what lets a later `.database(other)` replace
|
|
164
|
+
* it outright. The builder arrives already typed with this worker's
|
|
165
|
+
* database; this is the runtime half of that.
|
|
139
166
|
*/
|
|
140
167
|
private own;
|
|
141
168
|
declare(): Declaration[];
|
|
142
169
|
}
|
|
143
|
-
//# sourceMappingURL=worker.d.ts.map
|
|
144
170
|
//#endregion
|
|
145
|
-
export { Worker, WorkerConfig };
|
|
146
171
|
//# sourceMappingURL=worker.d.cts.map
|
package/dist/worker.d.cts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worker.d.cts","names":[],"sources":["../src/worker.ts"],"
|
|
1
|
+
{"version":3,"file":"worker.d.cts","names":["_$__topic0.TopicMessage","_$__construct_interface0.ServicesOf","_$__functions0.FunctionHandler","_$__functions0.Function"],"sources":["../src/worker.ts"],"mappings":";;;;;;;;;;;;;;;;;iBAoGiB;;;;;;;;;EAShB,SAAS;;;;;;;EAOT,YAAY;;;;;;EAMZ,YAAY;;qBAGA,OACZ,+BACA,uBACA,yDACY,WAAW;mBAmBL;;mBAEA;WAnBT,IAAI;;WAGJ,QAAQ;;WAGR,WAAW;;;;;;WAOX,gBAAgB;EAEzB,YACC,IAAI,cAAc,QACD,SAAQ,cAER;;EAAA,wBAAuB,cACxC,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyCjB,SAAS,GAAG,wBACX,QAAQ,WAAW,SAAS,KAC1B,OAAO,OAAO,GAAG;;;;;;EAcpB,KAAK,UAAU,qBAAkB,YAAA,0BAAA,WAAA,mBAAA,WAAA;;;;;;;;;;;;;;;;;EA6BjC,MAAM,2BAA2B,MAAM,aAAU,aAAA,2BAAA,QAAA,WAAA;;;;;;;;;;;EAuBjD,MAAM,2BAA2B,gBAAgB,aAChD,OAAO,MAAM,YAAY,WAAQ,sBAAA,mBAAA,eAAAA,aAAA,iBAAA,WAAA;;;;;;;;;;;;EA0BlC,MAAM,UAAU,0BAA0B,QAAQ,IAAC,gBAAA,kBAAA,2BAAA,WAAA,sBAAA;EAInD,OAAO,UAAU,kBAAkB,QAAQ,IAAC,qBAAA,OAAA,2BAAA,WAAA,sBAAA;EAI5C,QAAQ,aAAU,oCAAA,2BAAA,WAAA,sBAAA;EAIlB,WAAW,aAAU,oCAAA,2BAAA,WAAA,sBAAA;EAIrB,gBAAgB,mBAAmB,cAAc,YAAY,IAAC,oCAAAC,WAAA,KAAA,2BAAA,WAAA,sBAAA;EAI9D,SAAS,UAAU,WAAW,UAAU,IAAC,oCAAA,IAAA,2BAAA,WAAA,sBAAA;;;;;;EASzC,UACI,MAAM,WACR,WACC,OAAO,OAAO,WAAW,0DAE1BE,kBAAA,sCAAA,WAAA,sBAAA,kCAAAD,yBAAA,mBAAA,sBAAA;;UAMM;;cAKI;;;;;;;EAqBZ,MACC,qBAAqB,eACnB,OAAO,OAAO,WAAW;;;;;;;;;;;;UAoBpB;EAiBR,WAAW"}
|
package/dist/worker.d.mts
CHANGED
|
@@ -1,23 +1,21 @@
|
|
|
1
|
-
import "./
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import "./
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import "./
|
|
1
|
+
import { n as StandardSchemaV1 } from "./index-DdRjYhiJ.mjs";
|
|
2
|
+
import { c as Topic, l as TopicEvents, u as TopicMessage } from "./Construct-B7AXn0xH.mjs";
|
|
3
|
+
import { i as FunctionHandler, n as Function } from "./Function-B_9R7Zy1.mjs";
|
|
4
|
+
import { c as ServicesOf, i as Declarable, r as Consumable } from "./construct-interface-ZvYQbivO.mjs";
|
|
5
|
+
import { t as FunctionBuilder } from "./index-aBIcAiH5.mjs";
|
|
6
|
+
import { i as ScheduleExpression } from "./Cron-i4Uetezh.mjs";
|
|
7
|
+
import { n as Telemetry } from "./telemetry-BEoBn6GO.mjs";
|
|
8
|
+
import { t as CronBuilder } from "./CronBuilder-9H4BnD6W.mjs";
|
|
9
|
+
import { t as QueueBuilder } from "./QueueBuilder-48W-q8In.mjs";
|
|
10
|
+
import { t as SubscriberBuilder } from "./SubscriberBuilder-D9bkrYzH.mjs";
|
|
11
|
+
import "./topic/index.mjs";
|
|
10
12
|
import { ConstructName, Declaration, Dependency } from "@geekmidas/manifest";
|
|
11
|
-
import { EnvironmentParser } from "@geekmidas/envkit";
|
|
12
13
|
import { Service } from "@geekmidas/services";
|
|
13
|
-
import {
|
|
14
|
+
import { EnvironmentParser } from "@geekmidas/envkit";
|
|
14
15
|
import { Logger } from "@geekmidas/logger";
|
|
15
16
|
import { ComposableStandardSchema } from "@geekmidas/schema";
|
|
16
|
-
import { StandardSchemaV1 } from "@standard-schema/spec";
|
|
17
|
-
|
|
18
17
|
//#region src/worker.d.ts
|
|
19
|
-
|
|
20
|
-
interface WorkerConfig {
|
|
18
|
+
export interface WorkerConfig {
|
|
21
19
|
/**
|
|
22
20
|
* The logger everything built from this worker runs with.
|
|
23
21
|
*
|
|
@@ -34,8 +32,14 @@ interface WorkerConfig {
|
|
|
34
32
|
* which is what an application's own `config/env.ts` always was.
|
|
35
33
|
*/
|
|
36
34
|
envParser?: EnvironmentParser<{}>;
|
|
35
|
+
/**
|
|
36
|
+
* What the worker's process emits — the `Telemetry` construct, passed like
|
|
37
|
+
* the logger. An edge to the node: the deploy hands the process the
|
|
38
|
+
* `OTEL_*` keys its stage resolves.
|
|
39
|
+
*/
|
|
40
|
+
telemetry?: Telemetry;
|
|
37
41
|
}
|
|
38
|
-
declare class Worker<TName extends string = string> implements Declarable<TName> {
|
|
42
|
+
export declare class Worker<TName extends string = string, TDatabase = undefined, TDatabaseServiceName extends string = string> implements Declarable<TName> {
|
|
39
43
|
private readonly config;
|
|
40
44
|
/** Internal: how `.calls()` carries edges into the copy it returns. */
|
|
41
45
|
private readonly dependencies;
|
|
@@ -46,13 +50,18 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
46
50
|
readonly envParser: EnvironmentParser<{}>;
|
|
47
51
|
/**
|
|
48
52
|
* Where this worker's schedules live, when it has crons and a server runs
|
|
49
|
-
* them
|
|
53
|
+
* them — and the database everything built from it receives as `db`.
|
|
54
|
+
* `undefined` until `.database(…)` says.
|
|
50
55
|
*/
|
|
51
56
|
readonly scheduleStore?: Consumable<string, unknown>;
|
|
52
|
-
constructor(id: ConstructName<TName>, config?: WorkerConfig,
|
|
57
|
+
constructor(id: ConstructName<TName>, config?: WorkerConfig,
|
|
58
|
+
/** Internal: how `.calls()` carries edges into the copy it returns. */
|
|
53
59
|
dependencies?: readonly Dependency[], scheduleStore?: Consumable<string, unknown>);
|
|
54
60
|
/**
|
|
55
|
-
* The database this worker keeps its schedules in
|
|
61
|
+
* The database this worker keeps its schedules in, and the one everything
|
|
62
|
+
* built from it — crons, queues, subscribers, functions — receives as `db`.
|
|
63
|
+
* One of them that works against another database names it with its own
|
|
64
|
+
* `.database(other)`, which replaces this one for that runnable alone.
|
|
56
65
|
*
|
|
57
66
|
* Only a server target uses it. On AWS a cron is an EventBridge rule
|
|
58
67
|
* invoking a Lambda and nothing here is consulted — but a server has nothing
|
|
@@ -69,35 +78,47 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
69
78
|
* @example
|
|
70
79
|
* ```ts
|
|
71
80
|
* export const jobs = new Worker('Jobs', { logger }).database(database);
|
|
81
|
+
*
|
|
82
|
+
* export const sweep = jobs
|
|
83
|
+
* .cron('rate(1 hour)')
|
|
84
|
+
* .handle(async ({ db }) => db.deleteFrom('sessions').execute());
|
|
72
85
|
* ```
|
|
73
86
|
*/
|
|
74
|
-
database<T, TDbName extends string>(source: Consumable<TDbName, T>): Worker<TName>;
|
|
87
|
+
database<T, TDbName extends string>(source: Consumable<TDbName, T>): Worker<TName, T, TDbName>;
|
|
75
88
|
/**
|
|
76
89
|
* A scheduled runnable.
|
|
77
90
|
*
|
|
78
91
|
* @example `worker.cron('rate(1 day)').handle(async ({ logger }) => { … })`
|
|
79
92
|
*/
|
|
80
|
-
cron(schedule: ScheduleExpression): CronBuilder<ComposableStandardSchema, Service
|
|
93
|
+
cron(schedule: ScheduleExpression): CronBuilder<ComposableStandardSchema, Service[], Logger, undefined, TDatabase, TDatabaseServiceName>;
|
|
81
94
|
/**
|
|
82
|
-
* A
|
|
95
|
+
* A queue and its one consumer, run by this worker.
|
|
83
96
|
*
|
|
84
|
-
*
|
|
85
|
-
*
|
|
86
|
-
*
|
|
87
|
-
*
|
|
97
|
+
* One construct, because a queue has exactly one consumer: nothing else can
|
|
98
|
+
* attach a second, or forget to attach the first. Producers send to it by
|
|
99
|
+
* depending on it — `.dependsOn([emails])` makes `services.emails` the
|
|
100
|
+
* publisher.
|
|
88
101
|
*
|
|
89
|
-
* @example
|
|
102
|
+
* @example
|
|
103
|
+
* ```ts
|
|
104
|
+
* export const emails = worker
|
|
105
|
+
* .queue('Emails')
|
|
106
|
+
* .message(z.object({ userId: z.uuid(), template: z.string() }))
|
|
107
|
+
* .handle(async ({ messages, services }) => { … });
|
|
108
|
+
* ```
|
|
90
109
|
*/
|
|
91
|
-
|
|
110
|
+
queue<TQueueName extends string>(name: TQueueName): QueueBuilder<TQueueName, undefined, [], Logger, TDatabase, TDatabaseServiceName>;
|
|
92
111
|
/**
|
|
93
|
-
* A runnable that consumes
|
|
112
|
+
* A runnable that consumes a topic.
|
|
94
113
|
*
|
|
95
|
-
*
|
|
96
|
-
*
|
|
97
|
-
*
|
|
98
|
-
*
|
|
114
|
+
* Binding is not publishing: a consumer is handed the topic's event types
|
|
115
|
+
* and no connection string it could publish with. A handler that emits
|
|
116
|
+
* follow-up events depends on the topic it emits to —
|
|
117
|
+
* `.dependsOn([orders])` — which is the only reason it would need one.
|
|
118
|
+
*
|
|
119
|
+
* @example `worker.topic(users).subscribe(['user.created']).handle(…)`
|
|
99
120
|
*/
|
|
100
|
-
|
|
121
|
+
topic<TTopicName extends string, TEvents extends TopicEvents>(topic: Topic<TTopicName, TEvents>): SubscriberBuilder<[], Logger, undefined, EventPublisher<TopicMessage<TEvents_1>>, [], TDatabase, TDatabaseServiceName>;
|
|
101
122
|
/**
|
|
102
123
|
* Everything below builds a function — the runnable with no schedule and no
|
|
103
124
|
* topic, invoked by something else.
|
|
@@ -109,18 +130,18 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
109
130
|
* makes a cron, a topic makes a subscriber, and anything else makes a
|
|
110
131
|
* function.
|
|
111
132
|
*/
|
|
112
|
-
input<T extends ComposableStandardSchema>(schema: T): FunctionBuilder<T, undefined, [], Logger, undefined, string,
|
|
113
|
-
output<T extends StandardSchemaV1>(schema: T): FunctionBuilder<
|
|
114
|
-
timeout(ms: number): FunctionBuilder<
|
|
115
|
-
memorySize(mb: number): FunctionBuilder<
|
|
116
|
-
dependsOn<const T extends readonly Consumable[]>(constructs: T): FunctionBuilder<
|
|
117
|
-
services<T extends Service[]>(services: T): FunctionBuilder<
|
|
133
|
+
input<T extends ComposableStandardSchema>(schema: T): FunctionBuilder<T, undefined, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
134
|
+
output<T extends StandardSchemaV1>(schema: T): FunctionBuilder<any, T, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
135
|
+
timeout(ms: number): FunctionBuilder<any, undefined, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
136
|
+
memorySize(mb: number): FunctionBuilder<any, undefined, [], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
137
|
+
dependsOn<const T extends readonly Consumable[]>(constructs: T): FunctionBuilder<any, undefined, [...ServicesOf<T>], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
138
|
+
services<T extends Service[]>(services: T): FunctionBuilder<any, undefined, [...T], Logger, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>>;
|
|
118
139
|
/**
|
|
119
140
|
* A function with no input schema — the shortest runnable there is.
|
|
120
141
|
*
|
|
121
142
|
* @example `worker.handle(async ({ logger }) => { … })`
|
|
122
143
|
*/
|
|
123
|
-
handle(...args: Parameters<ReturnType<Worker<TName>['schemalessFunction']>['handle']>): Function<
|
|
144
|
+
handle(...args: Parameters<ReturnType<Worker<TName, TDatabase, TDatabaseServiceName>['schemalessFunction']>['handle']>): Function<any, [], Logger, undefined, undefined, string, TDatabase, TDatabaseServiceName, AuditableAction<string, unknown>, FunctionHandler<any, [], Logger, undefined, TDatabase, undefined, AuditableAction<string, unknown>>>;
|
|
124
145
|
/** The builder `handle` delegates to, named so its type can be referred to. */
|
|
125
146
|
private schemalessFunction;
|
|
126
147
|
/** The function builder the delegating methods above are built on. */
|
|
@@ -131,15 +152,20 @@ declare class Worker<TName extends string = string> implements Declarable<TName>
|
|
|
131
152
|
* Not `.dependsOn()`: this records the edge that derives the worker's
|
|
132
153
|
* environment and its access, the same distinction `RestApi.calls()` draws.
|
|
133
154
|
*/
|
|
134
|
-
calls(constructs: readonly Declarable[]): Worker<TName>;
|
|
155
|
+
calls(constructs: readonly Declarable[]): Worker<TName, TDatabase, TDatabaseServiceName>;
|
|
135
156
|
/**
|
|
136
157
|
* Stamps this worker's id onto a builder, so everything built from it says
|
|
137
|
-
* which process runs it.
|
|
158
|
+
* which process runs it — and hands it the worker's database.
|
|
159
|
+
*
|
|
160
|
+
* The database goes through the builder's own `.database()` rather than
|
|
161
|
+
* being written into its fields, so the default is recorded exactly as an
|
|
162
|
+
* explicit one would be: the client the handler gets, and the edge the
|
|
163
|
+
* manifest reads. That is also what lets a later `.database(other)` replace
|
|
164
|
+
* it outright. The builder arrives already typed with this worker's
|
|
165
|
+
* database; this is the runtime half of that.
|
|
138
166
|
*/
|
|
139
167
|
private own;
|
|
140
168
|
declare(): Declaration[];
|
|
141
169
|
}
|
|
142
|
-
//# sourceMappingURL=worker.d.ts.map
|
|
143
170
|
//#endregion
|
|
144
|
-
export { Worker, WorkerConfig };
|
|
145
171
|
//# sourceMappingURL=worker.d.mts.map
|
package/dist/worker.d.mts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"worker.d.mts","names":[],"sources":["../src/worker.ts"],"
|
|
1
|
+
{"version":3,"file":"worker.d.mts","names":["_$__topic0.TopicMessage","_$__construct_interface0.ServicesOf","_$__functions0.FunctionHandler","_$__functions0.Function"],"sources":["../src/worker.ts"],"mappings":";;;;;;;;;;;;;;;;;iBAoGiB;;;;;;;;;EAShB,SAAS;;;;;;;EAOT,YAAY;;;;;;EAMZ,YAAY;;qBAGA,OACZ,+BACA,uBACA,yDACY,WAAW;mBAmBL;;mBAEA;WAnBT,IAAI;;WAGJ,QAAQ;;WAGR,WAAW;;;;;;WAOX,gBAAgB;EAEzB,YACC,IAAI,cAAc,QACD,SAAQ,cAER;;EAAA,wBAAuB,cACxC,gBAAgB;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAyCjB,SAAS,GAAG,wBACX,QAAQ,WAAW,SAAS,KAC1B,OAAO,OAAO,GAAG;;;;;;EAcpB,KAAK,UAAU,qBAAkB,YAAA,0BAAA,WAAA,mBAAA,WAAA;;;;;;;;;;;;;;;;;EA6BjC,MAAM,2BAA2B,MAAM,aAAU,aAAA,2BAAA,QAAA,WAAA;;;;;;;;;;;EAuBjD,MAAM,2BAA2B,gBAAgB,aAChD,OAAO,MAAM,YAAY,WAAQ,sBAAA,mBAAA,eAAAA,aAAA,iBAAA,WAAA;;;;;;;;;;;;EA0BlC,MAAM,UAAU,0BAA0B,QAAQ,IAAC,gBAAA,kBAAA,2BAAA,WAAA,sBAAA;EAInD,OAAO,UAAU,kBAAkB,QAAQ,IAAC,qBAAA,OAAA,2BAAA,WAAA,sBAAA;EAI5C,QAAQ,aAAU,oCAAA,2BAAA,WAAA,sBAAA;EAIlB,WAAW,aAAU,oCAAA,2BAAA,WAAA,sBAAA;EAIrB,gBAAgB,mBAAmB,cAAc,YAAY,IAAC,oCAAAC,WAAA,KAAA,2BAAA,WAAA,sBAAA;EAI9D,SAAS,UAAU,WAAW,UAAU,IAAC,oCAAA,IAAA,2BAAA,WAAA,sBAAA;;;;;;EASzC,UACI,MAAM,WACR,WACC,OAAO,OAAO,WAAW,0DAE1BE,kBAAA,sCAAA,WAAA,sBAAA,kCAAAD,yBAAA,mBAAA,sBAAA;;UAMM;;cAKI;;;;;;;EAqBZ,MACC,qBAAqB,eACnB,OAAO,OAAO,WAAW;;;;;;;;;;;;UAoBpB;EAiBR,WAAW"}
|