@pattern-stack/codegen 0.19.0 → 0.20.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (125) hide show
  1. package/CHANGELOG.md +91 -0
  2. package/consumer-skills/events/authoring-events.md +31 -0
  3. package/dist/{chunk-Z7PQCAVK.js → chunk-4OC5MSHO.js} +50 -4
  4. package/dist/chunk-4OC5MSHO.js.map +1 -0
  5. package/dist/{chunk-7OVCARTQ.js → chunk-5RT7JGKT.js} +4 -4
  6. package/dist/{chunk-AZLUWG5S.js → chunk-AJILKWGO.js} +9 -9
  7. package/dist/{chunk-SNH35CNA.js → chunk-AODME4YK.js} +10 -10
  8. package/dist/{chunk-PKDS6QIJ.js → chunk-ATVGYF3D.js} +7 -7
  9. package/dist/{chunk-4MVGAMUA.js → chunk-BK5ICA2F.js} +4 -4
  10. package/dist/{chunk-2TVVBC53.js → chunk-BORNCTH3.js} +2 -2
  11. package/dist/{chunk-J7JMVS2B.js → chunk-CZQUOIDY.js} +4 -4
  12. package/dist/{chunk-V4AF6DI4.js → chunk-DUBZOXJC.js} +9 -2
  13. package/dist/{chunk-V4AF6DI4.js.map → chunk-DUBZOXJC.js.map} +1 -1
  14. package/dist/{chunk-VQOAATIG.js → chunk-DUMI2J5M.js} +4 -4
  15. package/dist/chunk-DUUCU77W.js +211 -0
  16. package/dist/chunk-DUUCU77W.js.map +1 -0
  17. package/dist/{chunk-OFRRBC7M.js → chunk-E2BRT5IB.js} +15 -1
  18. package/dist/chunk-E2BRT5IB.js.map +1 -0
  19. package/dist/{chunk-XKWOJZZ4.js → chunk-E45CSC33.js} +2 -2
  20. package/dist/{chunk-B34G6PHD.js → chunk-HCAKMT64.js} +77 -10
  21. package/dist/chunk-HCAKMT64.js.map +1 -0
  22. package/dist/{chunk-43SBT72G.js → chunk-I6UXRJ3Q.js} +4 -4
  23. package/dist/{chunk-GM3RMJIJ.js → chunk-INO47JXD.js} +3 -3
  24. package/dist/{chunk-BGULBWKJ.js → chunk-JOBQ6RUU.js} +1 -1
  25. package/dist/chunk-JOBQ6RUU.js.map +1 -0
  26. package/dist/{chunk-F7KN3U6U.js → chunk-KK5A7B2T.js} +27 -1
  27. package/dist/chunk-KK5A7B2T.js.map +1 -0
  28. package/dist/{chunk-65MO75WM.js → chunk-M3TIZGIB.js} +9 -9
  29. package/dist/{chunk-E6PLM6QG.js → chunk-MB5VVG4Z.js} +8 -8
  30. package/dist/{chunk-K2I6XIK5.js → chunk-MVKW2BCR.js} +2 -2
  31. package/dist/{chunk-VDL5CJ5C.js → chunk-P7EZCTIN.js} +8 -8
  32. package/dist/{chunk-R6F6KFIL.js → chunk-SGSWVNNB.js} +7 -7
  33. package/dist/chunk-SYVZ4MD2.js +1 -0
  34. package/dist/{chunk-235ZMMJR.js → chunk-SZYZ4SHF.js} +6 -6
  35. package/dist/{chunk-7LKAMLV4.js → chunk-T6SCOJF4.js} +4 -4
  36. package/dist/{chunk-OZEPJGMA.js → chunk-VOYFPR3S.js} +54 -6
  37. package/dist/chunk-VOYFPR3S.js.map +1 -0
  38. package/dist/{chunk-CLWBNXKF.js → chunk-W2UIDI3R.js} +4 -4
  39. package/dist/runtime/subsystems/analytics/analytics.module.js +2 -2
  40. package/dist/runtime/subsystems/analytics/index.js +4 -4
  41. package/dist/runtime/subsystems/auth/auth.module.js +2 -2
  42. package/dist/runtime/subsystems/auth/index.js +7 -7
  43. package/dist/runtime/subsystems/bridge/bridge-delivery-handler.js +3 -3
  44. package/dist/runtime/subsystems/bridge/bridge-delivery.drizzle-backend.js +4 -4
  45. package/dist/runtime/subsystems/bridge/bridge-delivery.schema.js +2 -2
  46. package/dist/runtime/subsystems/bridge/bridge-outbox-drain-hook.js +8 -8
  47. package/dist/runtime/subsystems/bridge/bridge.module.js +19 -19
  48. package/dist/runtime/subsystems/bridge/event-flow.service.js +2 -2
  49. package/dist/runtime/subsystems/bridge/index.js +27 -27
  50. package/dist/runtime/subsystems/events/domain-events.schema.js +1 -1
  51. package/dist/runtime/subsystems/events/event-bus.drizzle-backend.d.ts +19 -32
  52. package/dist/runtime/subsystems/events/event-bus.drizzle-backend.js +4 -4
  53. package/dist/runtime/subsystems/events/event-bus.memory-backend.d.ts +18 -1
  54. package/dist/runtime/subsystems/events/event-bus.memory-backend.js +2 -2
  55. package/dist/runtime/subsystems/events/event-bus.protocol.d.ts +45 -1
  56. package/dist/runtime/subsystems/events/event-scheduler.d.ts +96 -0
  57. package/dist/runtime/subsystems/events/event-scheduler.js +25 -0
  58. package/dist/runtime/subsystems/events/event-scheduler.js.map +1 -0
  59. package/dist/runtime/subsystems/events/events-errors.d.ts +12 -1
  60. package/dist/runtime/subsystems/events/events-errors.js +5 -3
  61. package/dist/runtime/subsystems/events/events.module.d.ts +41 -2
  62. package/dist/runtime/subsystems/events/events.module.js +12 -9
  63. package/dist/runtime/subsystems/events/generated/bus.js +3 -3
  64. package/dist/runtime/subsystems/events/generated/index.js +3 -3
  65. package/dist/runtime/subsystems/events/generated/registry.d.ts +6 -0
  66. package/dist/runtime/subsystems/events/generated/registry.js +1 -1
  67. package/dist/runtime/subsystems/events/index.d.ts +4 -3
  68. package/dist/runtime/subsystems/events/index.js +39 -15
  69. package/dist/runtime/subsystems/index.d.ts +1 -0
  70. package/dist/runtime/subsystems/index.js +99 -98
  71. package/dist/runtime/subsystems/integration/build-change-source.js +2 -2
  72. package/dist/runtime/subsystems/integration/index.js +36 -36
  73. package/dist/runtime/subsystems/integration/integration.module.js +4 -4
  74. package/dist/runtime/subsystems/jobs/index.js +23 -23
  75. package/dist/runtime/subsystems/jobs/job-orchestrator.bullmq-backend.js +3 -3
  76. package/dist/runtime/subsystems/jobs/job-orchestrator.drizzle-backend.js +3 -3
  77. package/dist/runtime/subsystems/jobs/job-orchestrator.memory-backend.js +2 -2
  78. package/dist/runtime/subsystems/jobs/job-worker.js +3 -3
  79. package/dist/runtime/subsystems/jobs/job-worker.module.js +9 -9
  80. package/dist/runtime/subsystems/jobs/jobs-domain.module.js +7 -7
  81. package/dist/runtime/subsystems/observability/index.js +3 -3
  82. package/dist/runtime/subsystems/observability/observability.module.js +3 -3
  83. package/dist/runtime/subsystems/observability/observability.service.js +2 -2
  84. package/dist/runtime/subsystems/storage/index.js +4 -4
  85. package/dist/runtime/subsystems/storage/storage.module.js +2 -2
  86. package/dist/src/cli/index.js +38 -15
  87. package/dist/src/cli/index.js.map +1 -1
  88. package/dist/src/index.js +12 -12
  89. package/package.json +1 -1
  90. package/runtime/subsystems/events/domain-events.schema.ts +16 -0
  91. package/runtime/subsystems/events/event-bus.drizzle-backend.ts +103 -1
  92. package/runtime/subsystems/events/event-bus.memory-backend.ts +57 -1
  93. package/runtime/subsystems/events/event-bus.protocol.ts +47 -0
  94. package/runtime/subsystems/events/event-scheduler.ts +351 -0
  95. package/runtime/subsystems/events/events-errors.ts +14 -0
  96. package/runtime/subsystems/events/events.module.ts +78 -1
  97. package/runtime/subsystems/events/generated/registry.ts +1 -0
  98. package/runtime/subsystems/events/index.ts +25 -3
  99. package/dist/chunk-B34G6PHD.js.map +0 -1
  100. package/dist/chunk-BGULBWKJ.js.map +0 -1
  101. package/dist/chunk-F7KN3U6U.js.map +0 -1
  102. package/dist/chunk-FN2PYDPP.js +0 -1
  103. package/dist/chunk-OFRRBC7M.js.map +0 -1
  104. package/dist/chunk-OZEPJGMA.js.map +0 -1
  105. package/dist/chunk-Z7PQCAVK.js.map +0 -1
  106. /package/dist/{chunk-7OVCARTQ.js.map → chunk-5RT7JGKT.js.map} +0 -0
  107. /package/dist/{chunk-AZLUWG5S.js.map → chunk-AJILKWGO.js.map} +0 -0
  108. /package/dist/{chunk-SNH35CNA.js.map → chunk-AODME4YK.js.map} +0 -0
  109. /package/dist/{chunk-PKDS6QIJ.js.map → chunk-ATVGYF3D.js.map} +0 -0
  110. /package/dist/{chunk-4MVGAMUA.js.map → chunk-BK5ICA2F.js.map} +0 -0
  111. /package/dist/{chunk-2TVVBC53.js.map → chunk-BORNCTH3.js.map} +0 -0
  112. /package/dist/{chunk-J7JMVS2B.js.map → chunk-CZQUOIDY.js.map} +0 -0
  113. /package/dist/{chunk-VQOAATIG.js.map → chunk-DUMI2J5M.js.map} +0 -0
  114. /package/dist/{chunk-XKWOJZZ4.js.map → chunk-E45CSC33.js.map} +0 -0
  115. /package/dist/{chunk-43SBT72G.js.map → chunk-I6UXRJ3Q.js.map} +0 -0
  116. /package/dist/{chunk-GM3RMJIJ.js.map → chunk-INO47JXD.js.map} +0 -0
  117. /package/dist/{chunk-65MO75WM.js.map → chunk-M3TIZGIB.js.map} +0 -0
  118. /package/dist/{chunk-E6PLM6QG.js.map → chunk-MB5VVG4Z.js.map} +0 -0
  119. /package/dist/{chunk-K2I6XIK5.js.map → chunk-MVKW2BCR.js.map} +0 -0
  120. /package/dist/{chunk-VDL5CJ5C.js.map → chunk-P7EZCTIN.js.map} +0 -0
  121. /package/dist/{chunk-R6F6KFIL.js.map → chunk-SGSWVNNB.js.map} +0 -0
  122. /package/dist/{chunk-FN2PYDPP.js.map → chunk-SYVZ4MD2.js.map} +0 -0
  123. /package/dist/{chunk-235ZMMJR.js.map → chunk-SZYZ4SHF.js.map} +0 -0
  124. /package/dist/{chunk-7LKAMLV4.js.map → chunk-T6SCOJF4.js.map} +0 -0
  125. /package/dist/{chunk-CLWBNXKF.js.map → chunk-W2UIDI3R.js.map} +0 -0
@@ -1,22 +1,22 @@
1
1
  import {
2
2
  BRIDGE_DELIVERY_JOB_TYPE
3
- } from "./chunk-R6F6KFIL.js";
3
+ } from "./chunk-SGSWVNNB.js";
4
4
  import {
5
5
  bridgeDelivery
6
- } from "./chunk-2TVVBC53.js";
6
+ } from "./chunk-BORNCTH3.js";
7
+ import {
8
+ JOBS_LISTEN_NOTIFY
9
+ } from "./chunk-ZPL74UQN.js";
10
+ import {
11
+ jobRuns
12
+ } from "./chunk-OKXZ63IA.js";
7
13
  import {
8
14
  JOBS_WAKE_CHANNEL,
9
15
  pgNotify
10
16
  } from "./chunk-Q6LRJ4VI.js";
11
- import {
12
- JOBS_LISTEN_NOTIFY
13
- } from "./chunk-ZPL74UQN.js";
14
17
  import {
15
18
  BRIDGE_REGISTRY
16
19
  } from "./chunk-4LH67P4U.js";
17
- import {
18
- jobRuns
19
- } from "./chunk-OKXZ63IA.js";
20
20
  import {
21
21
  __decorateClass,
22
22
  __decorateParam
@@ -151,4 +151,4 @@ BridgeOutboxDrainHook = __decorateClass([
151
151
  export {
152
152
  BridgeOutboxDrainHook
153
153
  };
154
- //# sourceMappingURL=chunk-65MO75WM.js.map
154
+ //# sourceMappingURL=chunk-M3TIZGIB.js.map
@@ -6,22 +6,22 @@ import {
6
6
  MissingTenantIdError
7
7
  } from "./chunk-T4BIIU5E.js";
8
8
  import {
9
- JOBS_WAKE_CHANNEL,
10
- pgNotify
11
- } from "./chunk-Q6LRJ4VI.js";
9
+ JOBS_LISTEN_NOTIFY,
10
+ JOBS_MULTI_TENANT
11
+ } from "./chunk-ZPL74UQN.js";
12
12
  import {
13
13
  keySelectorToTemplate,
14
14
  resolveJobKey
15
15
  } from "./chunk-7P5ODGLA.js";
16
- import {
17
- JOBS_LISTEN_NOTIFY,
18
- JOBS_MULTI_TENANT
19
- } from "./chunk-ZPL74UQN.js";
20
16
  import {
21
17
  jobRuns,
22
18
  jobSteps,
23
19
  jobs
24
20
  } from "./chunk-OKXZ63IA.js";
21
+ import {
22
+ JOBS_WAKE_CHANNEL,
23
+ pgNotify
24
+ } from "./chunk-Q6LRJ4VI.js";
25
25
  import {
26
26
  DRIZZLE
27
27
  } from "./chunk-U64T4YZE.js";
@@ -393,4 +393,4 @@ export {
393
393
  evaluateKeyTemplate,
394
394
  DrizzleJobOrchestrator
395
395
  };
396
- //# sourceMappingURL=chunk-E6PLM6QG.js.map
396
+ //# sourceMappingURL=chunk-MB5VVG4Z.js.map
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-6DWFJNIK.js";
4
4
  import {
5
5
  bridgeDelivery
6
- } from "./chunk-2TVVBC53.js";
6
+ } from "./chunk-BORNCTH3.js";
7
7
  import {
8
8
  BRIDGE_MULTI_TENANT
9
9
  } from "./chunk-4LH67P4U.js";
@@ -119,4 +119,4 @@ DrizzleBridgeDeliveryRepo = __decorateClass([
119
119
  export {
120
120
  DrizzleBridgeDeliveryRepo
121
121
  };
122
- //# sourceMappingURL=chunk-K2I6XIK5.js.map
122
+ //# sourceMappingURL=chunk-MVKW2BCR.js.map
@@ -1,18 +1,18 @@
1
- import {
2
- JOBS_WAKE_CHANNEL,
3
- PgNotifyListener
4
- } from "./chunk-Q6LRJ4VI.js";
5
- import {
6
- JOB_HANDLER_REGISTRY
7
- } from "./chunk-7P5ODGLA.js";
8
1
  import {
9
2
  JOB_ORCHESTRATOR,
10
3
  JOB_RUN_SERVICE,
11
4
  JOB_STEP_SERVICE
12
5
  } from "./chunk-ZPL74UQN.js";
6
+ import {
7
+ JOB_HANDLER_REGISTRY
8
+ } from "./chunk-7P5ODGLA.js";
13
9
  import {
14
10
  jobRuns
15
11
  } from "./chunk-OKXZ63IA.js";
12
+ import {
13
+ JOBS_WAKE_CHANNEL,
14
+ PgNotifyListener
15
+ } from "./chunk-Q6LRJ4VI.js";
16
16
  import {
17
17
  tokenKey
18
18
  } from "./chunk-GYGNEQSC.js";
@@ -528,4 +528,4 @@ export {
528
528
  buildStaleSweepQuery,
529
529
  JobWorker
530
530
  };
531
- //# sourceMappingURL=chunk-VDL5CJ5C.js.map
531
+ //# sourceMappingURL=chunk-P7EZCTIN.js.map
@@ -1,21 +1,21 @@
1
1
  import {
2
2
  assertTenantId
3
3
  } from "./chunk-6DWFJNIK.js";
4
- import {
5
- JobHandler,
6
- JobHandlerBase
7
- } from "./chunk-7P5ODGLA.js";
8
4
  import {
9
5
  JOB_ORCHESTRATOR
10
6
  } from "./chunk-ZPL74UQN.js";
11
7
  import {
12
- EVENT_BUS
13
- } from "./chunk-H5NH7KPE.js";
8
+ JobHandler,
9
+ JobHandlerBase
10
+ } from "./chunk-7P5ODGLA.js";
14
11
  import {
15
12
  BRIDGE_DELIVERY_REPO,
16
13
  BRIDGE_MULTI_TENANT,
17
14
  BRIDGE_REGISTRY
18
15
  } from "./chunk-4LH67P4U.js";
16
+ import {
17
+ EVENT_BUS
18
+ } from "./chunk-H5NH7KPE.js";
19
19
  import {
20
20
  __decorateClass,
21
21
  __decorateParam
@@ -118,4 +118,4 @@ export {
118
118
  BRIDGE_DELIVERY_JOB_TYPE,
119
119
  BridgeDeliveryHandler
120
120
  };
121
- //# sourceMappingURL=chunk-R6F6KFIL.js.map
121
+ //# sourceMappingURL=chunk-SGSWVNNB.js.map
@@ -0,0 +1 @@
1
+ //# sourceMappingURL=chunk-SYVZ4MD2.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  JobWorker
3
- } from "./chunk-VDL5CJ5C.js";
3
+ } from "./chunk-P7EZCTIN.js";
4
4
  import {
5
5
  JobsDomainModule
6
- } from "./chunk-AZLUWG5S.js";
6
+ } from "./chunk-AJILKWGO.js";
7
7
  import {
8
8
  BootValidationError,
9
9
  ReservedPoolViolationError
@@ -18,14 +18,14 @@ import {
18
18
  allPoolNames,
19
19
  loadPoolConfig
20
20
  } from "./chunk-RHVN6NA7.js";
21
- import {
22
- HandlerRegistry
23
- } from "./chunk-7P5ODGLA.js";
24
21
  import {
25
22
  JOB_ORCHESTRATOR,
26
23
  JOB_RUN_SERVICE,
27
24
  JOB_STEP_SERVICE
28
25
  } from "./chunk-ZPL74UQN.js";
26
+ import {
27
+ HandlerRegistry
28
+ } from "./chunk-7P5ODGLA.js";
29
29
  import {
30
30
  tokenKey
31
31
  } from "./chunk-GYGNEQSC.js";
@@ -290,4 +290,4 @@ export {
290
290
  JobWorkerOrchestrator,
291
291
  JobWorkerModule
292
292
  };
293
- //# sourceMappingURL=chunk-235ZMMJR.js.map
293
+ //# sourceMappingURL=chunk-SZYZ4SHF.js.map
@@ -1,15 +1,15 @@
1
1
  import {
2
2
  EnvEncryptionKey
3
3
  } from "./chunk-IP4OO26U.js";
4
+ import {
5
+ AuthController
6
+ } from "./chunk-SZVPIHWE.js";
4
7
  import {
5
8
  DrizzleOAuthStateStore
6
9
  } from "./chunk-N5OTOWTP.js";
7
10
  import {
8
11
  MemoryOAuthStateStore
9
12
  } from "./chunk-QLTJSCE6.js";
10
- import {
11
- AuthController
12
- } from "./chunk-SZVPIHWE.js";
13
13
  import {
14
14
  AUTH_OPTIONS,
15
15
  ENCRYPTION_KEY,
@@ -89,4 +89,4 @@ AuthModule = __decorateClass([
89
89
  export {
90
90
  AuthModule
91
91
  };
92
- //# sourceMappingURL=chunk-7LKAMLV4.js.map
92
+ //# sourceMappingURL=chunk-T6SCOJF4.js.map
@@ -1,12 +1,16 @@
1
1
  import {
2
2
  TypedEventBus
3
- } from "./chunk-GM3RMJIJ.js";
3
+ } from "./chunk-INO47JXD.js";
4
+ import {
5
+ EventScheduler,
6
+ scheduledEventsFromRegistry
7
+ } from "./chunk-DUUCU77W.js";
4
8
  import {
5
9
  DrizzleEventBus
6
- } from "./chunk-B34G6PHD.js";
10
+ } from "./chunk-HCAKMT64.js";
7
11
  import {
8
12
  MemoryEventBus
9
- } from "./chunk-Z7PQCAVK.js";
13
+ } from "./chunk-4OC5MSHO.js";
10
14
  import {
11
15
  EVENTS_MODULE_OPTIONS,
12
16
  EVENTS_MULTI_TENANT,
@@ -19,16 +23,55 @@ import {
19
23
  DRIZZLE
20
24
  } from "./chunk-U64T4YZE.js";
21
25
  import {
22
- __decorateClass
26
+ __decorateClass,
27
+ __decorateParam
23
28
  } from "./chunk-2E224ZSN.js";
24
29
 
25
30
  // runtime/subsystems/events/events.module.ts
26
- import { Module } from "@nestjs/common";
31
+ import {
32
+ Inject,
33
+ Injectable,
34
+ Logger,
35
+ Module,
36
+ Optional
37
+ } from "@nestjs/common";
27
38
  async function loadRedisEventBus() {
28
39
  const specifier = "./event-bus.redis-backend";
29
40
  const mod = await import(specifier);
30
41
  return mod.RedisEventBus;
31
42
  }
43
+ var EventSchedulerLifecycle = class {
44
+ constructor(bus, opts = null) {
45
+ this.bus = bus;
46
+ this.opts = opts;
47
+ }
48
+ bus;
49
+ opts;
50
+ logger = new Logger(EventSchedulerLifecycle.name);
51
+ scheduler = null;
52
+ async onModuleInit() {
53
+ const registry = this.opts?.eventRegistry;
54
+ if (!registry) return;
55
+ if (typeof this.bus.materializeScheduledEvent !== "function") return;
56
+ const schedules = scheduledEventsFromRegistry(registry);
57
+ if (schedules.length === 0) return;
58
+ this.scheduler = new EventScheduler(this.bus, schedules);
59
+ await this.scheduler.start();
60
+ this.logger.log(`EventScheduler wired for ${schedules.length} scheduled event(s).`);
61
+ }
62
+ async onModuleDestroy() {
63
+ if (this.scheduler) {
64
+ this.scheduler.stop();
65
+ this.scheduler = null;
66
+ }
67
+ }
68
+ };
69
+ EventSchedulerLifecycle = __decorateClass([
70
+ Injectable(),
71
+ __decorateParam(0, Inject(EVENT_BUS)),
72
+ __decorateParam(1, Optional()),
73
+ __decorateParam(1, Inject(EVENTS_MODULE_OPTIONS))
74
+ ], EventSchedulerLifecycle);
32
75
  function buildTypedBusProviders(multiTenant, typedBus) {
33
76
  const BusClass = typedBus ?? TypedEventBus;
34
77
  return [
@@ -139,6 +182,10 @@ var EventsModule = class {
139
182
  // IEventReadPort on the same instance as EVENT_BUS. The redis
140
183
  // backend retains no history and does not provide this token.
141
184
  { provide: EVENT_READ_PORT, useExisting: EVENT_BUS },
185
+ // ADR-039 — the scheduler lifecycle. No-op unless `eventRegistry` was
186
+ // threaded AND some event declared `schedule:`. Drizzle/memory only
187
+ // (the redis branch above never reaches here).
188
+ EventSchedulerLifecycle,
142
189
  ...buildTypedBusProviders(multiTenant, options.typedBus)
143
190
  ],
144
191
  exports: [EVENT_BUS, EVENT_READ_PORT, TYPED_EVENT_BUS, EVENTS_MULTI_TENANT]
@@ -150,6 +197,7 @@ EventsModule = __decorateClass([
150
197
  ], EventsModule);
151
198
 
152
199
  export {
200
+ EventSchedulerLifecycle,
153
201
  EventsModule
154
202
  };
155
- //# sourceMappingURL=chunk-OZEPJGMA.js.map
203
+ //# sourceMappingURL=chunk-VOYFPR3S.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../runtime/subsystems/events/events.module.ts"],"sourcesContent":["/**\n * EventsModule — DynamicModule factory for the event bus subsystem.\n *\n * Register once in AppModule:\n * ```typescript\n * @Module({\n * imports: [\n * EventsModule.forRoot({ backend: 'drizzle' }),\n * ],\n * })\n * export class AppModule {}\n * ```\n *\n * Tests swap to the memory backend without touching application code:\n * ```typescript\n * Test.createTestingModule({\n * imports: [EventsModule.forRoot({ backend: 'memory' })],\n * });\n * ```\n *\n * Per-pool drain isolation (EVT-4):\n * ```typescript\n * EventsModule.forRoot({ backend: 'drizzle', pools: ['events_change'] });\n * ```\n * Each process restricts its drain loop to the pools listed here. `pools`\n * is undefined by default → drain all pending rows (backwards-compatible).\n *\n * Typed facade + multi-tenancy (EVT-6):\n * - `TYPED_EVENT_BUS` resolves to the generated `TypedEventBus` wrapping\n * whichever backend is selected.\n * - `multiTenant: true` makes `TypedEventBus.publish` throw\n * `MissingTenantIdError` when the caller forgets `metadata.tenantId`.\n *\n * `global: true` means entity modules do not need to import EventsModule\n * individually — the EVENT_BUS and TYPED_EVENT_BUS tokens are available\n * project-wide.\n *\n * Async configuration (`forRootAsync`):\n * The async factory returns `EventsModuleOptions`; the EVENT_BUS provider\n * then receives its backend dependencies — DRIZZLE for the drizzle\n * backend, REDIS_URL for the redis backend, the resolved options for the\n * memory backend — through a proper `useFactory` so Nest DI wires them\n * correctly. Earlier revisions hand-constructed backends with\n * `new Class()` which silently left `db` / `redisUrl` undefined\n * (issue #108).\n */\nimport {\n Inject,\n Injectable,\n Logger,\n Module,\n Optional,\n type DynamicModule,\n type OnModuleDestroy,\n type OnModuleInit,\n type Provider,\n type Type,\n} from '@nestjs/common';\nimport {\n EVENT_BUS,\n EVENT_READ_PORT,\n EVENTS_MODULE_OPTIONS,\n EVENTS_MULTI_TENANT,\n REDIS_URL,\n TYPED_EVENT_BUS,\n} from './events.tokens';\nimport { DRIZZLE } from '../../constants/tokens';\nimport type { DrizzleClient } from '../../types/drizzle';\nimport { DrizzleEventBus } from './event-bus.drizzle-backend';\nimport { MemoryEventBus } from './event-bus.memory-backend';\nimport type { IEventBus } from './event-bus.protocol';\nimport {\n EventScheduler,\n scheduledEventsFromRegistry,\n type RegistrySchedule,\n} from './event-scheduler';\n// #6 — `RedisEventBus` is lazy-loaded only when `backend: 'redis'` is selected.\n// The file is filtered out of the vendor set for non-redis installs (see\n// `backendFileFilter` in src/cli/commands/subsystem.ts); the dynamic-string\n// import below makes TS treat the specifier as `any` so the consumer's tsc\n// never tries to resolve the absent file.\nimport { TypedEventBus } from './generated/bus';\n\n/**\n * Lazy-load the Redis backend. Routed through a non-literal specifier so\n * the consumer's `tsc` doesn't resolve `./event-bus.redis-backend` at type\n * check time — important because that file is filtered out of drizzle/\n * memory installs (#6).\n */\nasync function loadRedisEventBus(): Promise<new (url: string) => object> {\n // Non-literal specifier — TS gives this an `any` module type, sidestepping\n // resolution of a file that may not be vendored.\n const specifier = './event-bus.redis-backend';\n const mod = (await import(specifier)) as { RedisEventBus: new (url: string) => object };\n return mod.RedisEventBus;\n}\n\nexport interface EventsModuleOptions {\n backend: 'drizzle' | 'memory' | 'redis';\n /**\n * Redis connection URL used when `backend` is `'redis'`.\n * Falls back to the REDIS_URL environment variable, then\n * `redis://localhost:6379` if neither is set.\n */\n redisUrl?: string;\n /**\n * Restrict the drain loop to these pools. Each pool name matches the\n * `domain_events.pool` column (populated from `event.metadata.pool` at\n * publish time). Leave undefined to drain all pending rows.\n *\n * Typical lane split: one process per `events_inbound` /\n * `events_change` / `events_outbound` so a slow outbound handler\n * cannot stall change-event propagation (see ADR-022).\n */\n pools?: string[];\n /**\n * LISTEN-NOTIFY-1 — when `true` (drizzle backend only), the drainer holds a\n * dedicated listener connection and LISTENs on `codegen_events_wake`. Each\n * `publish`/`publishMany` emits an in-tx `pg_notify(codegen_events_wake,\n * <pool>)` so the drainer wakes the moment the publishing transaction commits,\n * instead of waiting for the next poll tick. Polling continues unchanged as\n * the fallback heartbeat; a lost notify degrades to poll latency, never to\n * lost work. Defaults to `false`.\n *\n * Ignored by the memory + redis backends (memory dispatches inline; redis has\n * its own fan-out). Requires a direct (non-transaction-pooler) connection —\n * see the events/jobs config block re: PgBouncer.\n */\n listenNotify?: boolean;\n /**\n * Multi-tenancy opt-in (EVT-6).\n *\n * When `true`, every `TypedEventBus.publish()` call must supply\n * `opts.metadata.tenantId` — otherwise it throws `MissingTenantIdError`.\n * The tenantId is preserved on `event.metadata` and, for the Drizzle\n * backend, written to `domain_events.tenant_id` (EVT-4).\n *\n * Drain-side tenant filtering is deferred — the tenant-context model\n * (per-process vs. per-request vs. async-local-storage) is still\n * unsettled; see ADR-024 §Multi-tenancy. Only the publish-side\n * requirement ships here.\n *\n * Defaults to `false`.\n */\n multiTenant?: boolean;\n /**\n * The generated `TypedEventBus` class to bind to `TYPED_EVENT_BUS`.\n *\n * **Package mode (ADR-037).** When the runtime is imported from\n * `@pattern-stack/codegen` (not vendored), the bundled `./generated/bus`\n * `TypedEventBus` is typed to an EMPTY event union and reads the bundled\n * empty `eventRegistry` — a consumer's `events/*.yaml` are scanned into\n * `src/generated/events/bus.ts` (typed to THEIR union, reading THEIR\n * registry), which the package can't import. The generated subsystem barrel\n * therefore threads that class in here:\n * `EventsModule.forRoot({ ..., typedBus: TypedEventBus })`. Nest constructs\n * it with this module's `EVENT_BUS` + `EVENTS_MULTI_TENANT` providers (the\n * generated class injects the same string-valued tokens, which match across\n * the package boundary).\n *\n * Omitted (vendored mode / tests) ⇒ falls back to the bundled\n * `./generated/bus`, which in a vendored tree IS the consumer's generated\n * file. Without this, a package-mode consumer's typed `publish<'…'>()` calls\n * resolve against the empty union and their events never get the right\n * `pool` / `direction` stamped.\n *\n * Only consulted by `forRoot` (the path the barrel emits); `forRootAsync`\n * keeps the bundled bus.\n */\n typedBus?: Type<unknown>;\n /**\n * ADR-039 — the consumer's generated `eventRegistry`, threaded so the\n * `EventScheduler` can read the `schedule:` block + routing metadata of every\n * scheduled event. Package mode: the generated subsystem barrel passes the\n * consumer's `eventRegistry` (the bundled one is the package's empty/fixture\n * registry, which the package can't see the consumer's events through — same\n * reason `typedBus` is threaded). Omitted ⇒ no scheduler is spawned (vendored\n * tree reads its own bundled registry only if the barrel passes it; tests\n * pass a registry directly).\n *\n * Structural shape: each value needs `schedule?` + `direction` + `pool`. The\n * generated `EventMetadata` satisfies it; typing it loosely here avoids a\n * runtime dependency on the generated types from the module file.\n */\n eventRegistry?: Record<\n string,\n { schedule?: RegistrySchedule; direction: string | null; pool: string | null }\n >;\n}\n\n/**\n * Lifecycle holder for the `EventScheduler` (ADR-039). Registered as a provider\n * on the drizzle/memory `forRoot` branches; Nest drives `onModuleInit` (after\n * the bus is constructed) and `onModuleDestroy`. Reads the scheduled-event set\n * from the threaded `eventRegistry` and starts the materialiser. No-op when\n * nothing declared `schedule:`, or under the redis backend (no outbox history).\n */\n@Injectable()\nexport class EventSchedulerLifecycle implements OnModuleInit, OnModuleDestroy {\n private readonly logger = new Logger(EventSchedulerLifecycle.name);\n private scheduler: EventScheduler | null = null;\n\n constructor(\n @Inject(EVENT_BUS) private readonly bus: IEventBus,\n @Optional()\n @Inject(EVENTS_MODULE_OPTIONS)\n private readonly opts: EventsModuleOptions | null = null,\n ) {}\n\n async onModuleInit(): Promise<void> {\n const registry = this.opts?.eventRegistry;\n if (!registry) return;\n if (typeof this.bus.materializeScheduledEvent !== 'function') return; // redis\n const schedules = scheduledEventsFromRegistry(registry);\n if (schedules.length === 0) return;\n this.scheduler = new EventScheduler(this.bus, schedules);\n await this.scheduler.start();\n this.logger.log(`EventScheduler wired for ${schedules.length} scheduled event(s).`);\n }\n\n async onModuleDestroy(): Promise<void> {\n if (this.scheduler) {\n this.scheduler.stop();\n this.scheduler = null;\n }\n }\n}\n\nexport interface EventsModuleAsyncOptions {\n useFactory: (...args: unknown[]) => Promise<EventsModuleOptions> | EventsModuleOptions;\n inject?: unknown[];\n imports?: unknown[];\n}\n\n/**\n * Shared provider set: `TypedEventBus` itself, the `TYPED_EVENT_BUS` token\n * binding, and the resolved `EVENTS_MULTI_TENANT` flag. Returned from one\n * place so every `forRoot` branch and `forRootAsync` agree.\n */\nfunction buildTypedBusProviders(\n multiTenant: boolean,\n typedBus?: Type<unknown>,\n): Provider[] {\n // Package mode threads the consumer's generated `TypedEventBus` (typed to\n // their event union, reading their registry) via `typedBus`; vendored mode\n // omits it and we fall back to the bundled `./generated/bus` (which IS the\n // consumer's generated file in a vendored tree). See `EventsModuleOptions.typedBus`.\n const BusClass = typedBus ?? TypedEventBus;\n return [\n BusClass,\n { provide: TYPED_EVENT_BUS, useExisting: BusClass },\n { provide: EVENTS_MULTI_TENANT, useValue: multiTenant },\n ];\n}\n\n/**\n * Construct the backend instance for the async path, routing constructor\n * arguments through Nest-resolved dependencies.\n *\n * DRIZZLE is declared optional at inject time so that memory-backend\n * consumers aren't required to also import `DatabaseModule`. If the\n * drizzle backend is selected but no DRIZZLE provider is registered, we\n * throw a clear error instead of silently constructing a broken bus.\n */\nasync function buildEventBusAsync(\n options: EventsModuleOptions,\n db: DrizzleClient | null,\n redisUrl: string,\n): Promise<unknown> {\n if (options.backend === 'drizzle') {\n if (!db) {\n throw new Error(\n \"EventsModule.forRootAsync: backend: 'drizzle' selected but DRIZZLE provider is not available. \" +\n 'Ensure DatabaseModule (or another provider exposing DRIZZLE) is imported before EventsModule.forRootAsync.',\n );\n }\n return new DrizzleEventBus(db, options);\n }\n if (options.backend === 'redis') {\n // #6: lazy import — the redis backend ships only with `--backend redis`\n // installs; drizzle/memory consumers never touch the file.\n const RedisEventBus = await loadRedisEventBus();\n return new RedisEventBus(redisUrl);\n }\n return new MemoryEventBus(options);\n}\n\n@Module({})\nexport class EventsModule {\n static forRootAsync(asyncOptions: EventsModuleAsyncOptions): DynamicModule {\n return {\n module: EventsModule,\n global: true,\n imports: (asyncOptions.imports ?? []) as Parameters<typeof Module>[0]['imports'],\n providers: [\n {\n provide: EVENTS_MODULE_OPTIONS,\n useFactory: asyncOptions.useFactory,\n inject: (asyncOptions.inject ?? []) as (string | symbol | Function)[],\n },\n {\n provide: EVENTS_MULTI_TENANT,\n useFactory: (options: EventsModuleOptions) => options.multiTenant ?? false,\n inject: [EVENTS_MODULE_OPTIONS],\n },\n {\n provide: REDIS_URL,\n useFactory: (options: EventsModuleOptions) =>\n options.redisUrl ?? process.env['REDIS_URL'] ?? 'redis://localhost:6379',\n inject: [EVENTS_MODULE_OPTIONS],\n },\n {\n provide: EVENT_BUS,\n useFactory: (\n options: EventsModuleOptions,\n db: DrizzleClient | null,\n redisUrl: string,\n ) => buildEventBusAsync(options, db, redisUrl),\n inject: [\n EVENTS_MODULE_OPTIONS,\n { token: DRIZZLE, optional: true },\n REDIS_URL,\n ],\n },\n {\n // Read port (OBS-LIST-1). Drizzle + memory backends implement\n // IEventReadPort on the EVENT_BUS instance; the redis backend\n // retains no history, so EVENT_READ_PORT resolves to `null` and\n // optional consumers (the observability combiner) degrade to\n // empty results.\n provide: EVENT_READ_PORT,\n useFactory: (options: EventsModuleOptions, bus: unknown) =>\n options.backend === 'redis' ? null : bus,\n inject: [EVENTS_MODULE_OPTIONS, EVENT_BUS],\n },\n TypedEventBus,\n { provide: TYPED_EVENT_BUS, useExisting: TypedEventBus },\n ],\n exports: [EVENT_BUS, EVENT_READ_PORT, TYPED_EVENT_BUS, EVENTS_MULTI_TENANT],\n };\n }\n\n static forRoot(\n options: EventsModuleOptions = { backend: 'drizzle' },\n ): DynamicModule {\n const multiTenant = options.multiTenant ?? false;\n\n if (options.backend === 'redis') {\n const resolvedUrl =\n options.redisUrl ?? process.env['REDIS_URL'] ?? 'redis://localhost:6379';\n\n return {\n module: EventsModule,\n global: true,\n providers: [\n { provide: EVENTS_MODULE_OPTIONS, useValue: options },\n { provide: REDIS_URL, useValue: resolvedUrl },\n {\n // #6: useFactory + dynamic import so the consumer's tsc never\n // needs to resolve `event-bus.redis-backend.ts` for drizzle/\n // memory installs (the file is filtered out by\n // `backendFileFilter`). Nest awaits async factories + manages\n // lifecycle on the returned instance, so we drop the old bare\n // `RedisEventBus` provider entry.\n provide: EVENT_BUS,\n useFactory: async (url: string): Promise<object> => {\n const RedisEventBus = await loadRedisEventBus();\n return new RedisEventBus(url);\n },\n inject: [REDIS_URL],\n },\n ...buildTypedBusProviders(multiTenant, options.typedBus),\n ],\n exports: [EVENT_BUS, TYPED_EVENT_BUS, EVENTS_MULTI_TENANT],\n };\n }\n\n const provider =\n options.backend === 'drizzle'\n ? { provide: EVENT_BUS, useClass: DrizzleEventBus }\n : { provide: EVENT_BUS, useClass: MemoryEventBus };\n\n return {\n module: EventsModule,\n global: true,\n providers: [\n { provide: EVENTS_MODULE_OPTIONS, useValue: options },\n provider,\n // Read port (OBS-LIST-1): drizzle + memory backends implement\n // IEventReadPort on the same instance as EVENT_BUS. The redis\n // backend retains no history and does not provide this token.\n { provide: EVENT_READ_PORT, useExisting: EVENT_BUS },\n // ADR-039 — the scheduler lifecycle. No-op unless `eventRegistry` was\n // threaded AND some event declared `schedule:`. Drizzle/memory only\n // (the redis branch above never reaches here).\n EventSchedulerLifecycle,\n ...buildTypedBusProviders(multiTenant, options.typedBus),\n ],\n exports: [EVENT_BUS, EVENT_READ_PORT, TYPED_EVENT_BUS, EVENTS_MULTI_TENANT],\n };\n }\n}\n"],"mappings":"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","names":[]}
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  JOB_RUN_SERVICE
3
3
  } from "./chunk-ZPL74UQN.js";
4
- import {
5
- EVENT_READ_PORT
6
- } from "./chunk-H5NH7KPE.js";
7
4
  import {
8
5
  BRIDGE_DELIVERY_REPO
9
6
  } from "./chunk-4LH67P4U.js";
7
+ import {
8
+ EVENT_READ_PORT
9
+ } from "./chunk-H5NH7KPE.js";
10
10
  import {
11
11
  INTEGRATION_CURSOR_STORE,
12
12
  INTEGRATION_RUN_RECORDER
@@ -181,4 +181,4 @@ ObservabilityService = __decorateClass([
181
181
  export {
182
182
  ObservabilityService
183
183
  };
184
- //# sourceMappingURL=chunk-CLWBNXKF.js.map
184
+ //# sourceMappingURL=chunk-W2UIDI3R.js.map
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  AnalyticsModule
3
- } from "../../../chunk-J7JMVS2B.js";
3
+ } from "../../../chunk-CZQUOIDY.js";
4
4
  import "../../../chunk-7B3RYX45.js";
5
- import "../../../chunk-J37YWU7Y.js";
6
5
  import "../../../chunk-6I7ULIN6.js";
6
+ import "../../../chunk-J37YWU7Y.js";
7
7
  import "../../../chunk-GYGNEQSC.js";
8
8
  import "../../../chunk-2E224ZSN.js";
9
9
  export {
@@ -1,17 +1,17 @@
1
1
  import {
2
2
  AnalyticsModule
3
- } from "../../../chunk-J7JMVS2B.js";
3
+ } from "../../../chunk-CZQUOIDY.js";
4
4
  import {
5
5
  CubeAnalyticsBackend
6
6
  } from "../../../chunk-7B3RYX45.js";
7
- import {
8
- NoopAnalyticsBackend
9
- } from "../../../chunk-J37YWU7Y.js";
10
7
  import {
11
8
  ANALYTICS_QUERY,
12
9
  CUBE_API_SECRET,
13
10
  CUBE_API_URL
14
11
  } from "../../../chunk-6I7ULIN6.js";
12
+ import {
13
+ NoopAnalyticsBackend
14
+ } from "../../../chunk-J37YWU7Y.js";
15
15
  import "../../../chunk-GYGNEQSC.js";
16
16
  import "../../../chunk-2E224ZSN.js";
17
17
  export {
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  AuthModule
3
- } from "../../../chunk-7LKAMLV4.js";
3
+ } from "../../../chunk-T6SCOJF4.js";
4
4
  import "../../../chunk-IP4OO26U.js";
5
+ import "../../../chunk-SZVPIHWE.js";
5
6
  import "../../../chunk-N5OTOWTP.js";
6
7
  import "../../../chunk-QLTJSCE6.js";
7
8
  import "../../../chunk-BPARRK6F.js";
8
- import "../../../chunk-SZVPIHWE.js";
9
9
  import "../../../chunk-6XY6ZMMD.js";
10
10
  import "../../../chunk-NPFPZ2HO.js";
11
11
  import "../../../chunk-GYGNEQSC.js";
@@ -2,6 +2,9 @@ import "../../../chunk-7C3FOSDI.js";
2
2
  import {
3
3
  OAuth2RefreshStrategy
4
4
  } from "../../../chunk-M6QLSLPO.js";
5
+ import {
6
+ ConnectionBrokenError
7
+ } from "../../../chunk-2N4UG4VD.js";
5
8
  import {
6
9
  withAuthRetry
7
10
  } from "../../../chunk-WL67FZGF.js";
@@ -14,15 +17,15 @@ import {
14
17
  makeRequesterContextMiddleware,
15
18
  resolveRequesterContext
16
19
  } from "../../../chunk-OSQRXVG2.js";
17
- import {
18
- ConnectionBrokenError
19
- } from "../../../chunk-2N4UG4VD.js";
20
20
  import {
21
21
  AuthModule
22
- } from "../../../chunk-7LKAMLV4.js";
22
+ } from "../../../chunk-T6SCOJF4.js";
23
23
  import {
24
24
  EnvEncryptionKey
25
25
  } from "../../../chunk-IP4OO26U.js";
26
+ import {
27
+ AuthController
28
+ } from "../../../chunk-SZVPIHWE.js";
26
29
  import {
27
30
  DrizzleOAuthStateStore
28
31
  } from "../../../chunk-N5OTOWTP.js";
@@ -32,9 +35,6 @@ import {
32
35
  import {
33
36
  OAuthStateError
34
37
  } from "../../../chunk-BPARRK6F.js";
35
- import {
36
- AuthController
37
- } from "../../../chunk-SZVPIHWE.js";
38
38
  import {
39
39
  AUTH_CONNECTION_GRANT_SINK,
40
40
  AUTH_CONNECTION_READER,
@@ -1,13 +1,13 @@
1
1
  import {
2
2
  BRIDGE_DELIVERY_JOB_TYPE,
3
3
  BridgeDeliveryHandler
4
- } from "../../../chunk-R6F6KFIL.js";
4
+ } from "../../../chunk-SGSWVNNB.js";
5
5
  import "../../../chunk-6DWFJNIK.js";
6
6
  import "../../../chunk-NXXDZ6ZF.js";
7
- import "../../../chunk-7P5ODGLA.js";
8
7
  import "../../../chunk-ZPL74UQN.js";
9
- import "../../../chunk-H5NH7KPE.js";
8
+ import "../../../chunk-7P5ODGLA.js";
10
9
  import "../../../chunk-4LH67P4U.js";
10
+ import "../../../chunk-H5NH7KPE.js";
11
11
  import "../../../chunk-GYGNEQSC.js";
12
12
  import "../../../chunk-2E224ZSN.js";
13
13
  export {
@@ -1,12 +1,12 @@
1
1
  import {
2
2
  DrizzleBridgeDeliveryRepo
3
- } from "../../../chunk-K2I6XIK5.js";
3
+ } from "../../../chunk-MVKW2BCR.js";
4
4
  import "../../../chunk-6DWFJNIK.js";
5
+ import "../../../chunk-BORNCTH3.js";
5
6
  import "../../../chunk-NXXDZ6ZF.js";
6
- import "../../../chunk-2TVVBC53.js";
7
- import "../../../chunk-4LH67P4U.js";
8
7
  import "../../../chunk-OKXZ63IA.js";
9
- import "../../../chunk-OFRRBC7M.js";
8
+ import "../../../chunk-4LH67P4U.js";
9
+ import "../../../chunk-E2BRT5IB.js";
10
10
  import "../../../chunk-U64T4YZE.js";
11
11
  import "../../../chunk-2E224ZSN.js";
12
12
  export {
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  bridgeDelivery,
3
3
  bridgeDeliveryStatusEnum
4
- } from "../../../chunk-2TVVBC53.js";
4
+ } from "../../../chunk-BORNCTH3.js";
5
5
  import "../../../chunk-OKXZ63IA.js";
6
- import "../../../chunk-OFRRBC7M.js";
6
+ import "../../../chunk-E2BRT5IB.js";
7
7
  import "../../../chunk-2E224ZSN.js";
8
8
  export {
9
9
  bridgeDelivery,
@@ -1,17 +1,17 @@
1
1
  import {
2
2
  BridgeOutboxDrainHook
3
- } from "../../../chunk-65MO75WM.js";
4
- import "../../../chunk-R6F6KFIL.js";
3
+ } from "../../../chunk-M3TIZGIB.js";
4
+ import "../../../chunk-SGSWVNNB.js";
5
5
  import "../../../chunk-6DWFJNIK.js";
6
+ import "../../../chunk-BORNCTH3.js";
6
7
  import "../../../chunk-NXXDZ6ZF.js";
7
- import "../../../chunk-2TVVBC53.js";
8
- import "../../../chunk-Q6LRJ4VI.js";
9
- import "../../../chunk-7P5ODGLA.js";
10
8
  import "../../../chunk-ZPL74UQN.js";
11
- import "../../../chunk-H5NH7KPE.js";
12
- import "../../../chunk-4LH67P4U.js";
9
+ import "../../../chunk-7P5ODGLA.js";
13
10
  import "../../../chunk-OKXZ63IA.js";
14
- import "../../../chunk-OFRRBC7M.js";
11
+ import "../../../chunk-Q6LRJ4VI.js";
12
+ import "../../../chunk-4LH67P4U.js";
13
+ import "../../../chunk-E2BRT5IB.js";
14
+ import "../../../chunk-H5NH7KPE.js";
15
15
  import "../../../chunk-GYGNEQSC.js";
16
16
  import "../../../chunk-2E224ZSN.js";
17
17
  export {
@@ -1,37 +1,37 @@
1
1
  import {
2
2
  BridgeModule
3
- } from "../../../chunk-SNH35CNA.js";
3
+ } from "../../../chunk-AODME4YK.js";
4
4
  import "../../../chunk-5A432NZJ.js";
5
- import "../../../chunk-65MO75WM.js";
6
- import "../../../chunk-7OVCARTQ.js";
5
+ import "../../../chunk-5RT7JGKT.js";
7
6
  import "../../../chunk-EDKJU5BO.js";
8
- import "../../../chunk-R6F6KFIL.js";
9
- import "../../../chunk-K2I6XIK5.js";
10
- import "../../../chunk-6DWFJNIK.js";
7
+ import "../../../chunk-MVKW2BCR.js";
11
8
  import "../../../chunk-4DOJBQTP.js";
9
+ import "../../../chunk-M3TIZGIB.js";
10
+ import "../../../chunk-SGSWVNNB.js";
11
+ import "../../../chunk-6DWFJNIK.js";
12
+ import "../../../chunk-BORNCTH3.js";
12
13
  import "../../../chunk-NXXDZ6ZF.js";
13
- import "../../../chunk-2TVVBC53.js";
14
- import "../../../chunk-235ZMMJR.js";
15
- import "../../../chunk-VDL5CJ5C.js";
16
- import "../../../chunk-AZLUWG5S.js";
17
- import "../../../chunk-VNBC3VXM.js";
18
- import "../../../chunk-BHZP6LOV.js";
14
+ import "../../../chunk-SZYZ4SHF.js";
15
+ import "../../../chunk-P7EZCTIN.js";
16
+ import "../../../chunk-AJILKWGO.js";
19
17
  import "../../../chunk-DV4RV2DC.js";
20
- import "../../../chunk-E6PLM6QG.js";
21
- import "../../../chunk-VQOAATIG.js";
18
+ import "../../../chunk-MB5VVG4Z.js";
19
+ import "../../../chunk-DUMI2J5M.js";
22
20
  import "../../../chunk-PNZSGAB2.js";
21
+ import "../../../chunk-VNBC3VXM.js";
22
+ import "../../../chunk-BHZP6LOV.js";
23
23
  import "../../../chunk-SNQ3TOWP.js";
24
24
  import "../../../chunk-T4BIIU5E.js";
25
25
  import "../../../chunk-L3LZWWSX.js";
26
26
  import "../../../chunk-I6MVCB5A.js";
27
27
  import "../../../chunk-RHVN6NA7.js";
28
- import "../../../chunk-Q6LRJ4VI.js";
29
- import "../../../chunk-7P5ODGLA.js";
30
28
  import "../../../chunk-ZPL74UQN.js";
31
- import "../../../chunk-H5NH7KPE.js";
32
- import "../../../chunk-4LH67P4U.js";
29
+ import "../../../chunk-7P5ODGLA.js";
33
30
  import "../../../chunk-OKXZ63IA.js";
34
- import "../../../chunk-OFRRBC7M.js";
31
+ import "../../../chunk-Q6LRJ4VI.js";
32
+ import "../../../chunk-4LH67P4U.js";
33
+ import "../../../chunk-E2BRT5IB.js";
34
+ import "../../../chunk-H5NH7KPE.js";
35
35
  import "../../../chunk-GYGNEQSC.js";
36
36
  import "../../../chunk-U64T4YZE.js";
37
37
  import "../../../chunk-2E224ZSN.js";
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  EventFlowService
3
- } from "../../../chunk-7OVCARTQ.js";
3
+ } from "../../../chunk-5RT7JGKT.js";
4
4
  import "../../../chunk-6DWFJNIK.js";
5
5
  import "../../../chunk-NXXDZ6ZF.js";
6
6
  import "../../../chunk-ZPL74UQN.js";
7
- import "../../../chunk-H5NH7KPE.js";
8
7
  import "../../../chunk-4LH67P4U.js";
8
+ import "../../../chunk-H5NH7KPE.js";
9
9
  import "../../../chunk-GYGNEQSC.js";
10
10
  import "../../../chunk-U64T4YZE.js";
11
11
  import "../../../chunk-2E224ZSN.js";