rivetkit 2.3.24-rc.1 → 2.3.25

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 (115) hide show
  1. package/dist/browser/client.d.ts +3 -2
  2. package/dist/browser/client.js +36 -17
  3. package/dist/browser/client.js.map +1 -1
  4. package/dist/browser/inspector/client.js +1 -1
  5. package/dist/browser/inspector/client.js.map +1 -1
  6. package/dist/tsup/agent-os/index.cjs +1 -1
  7. package/dist/tsup/agent-os/index.cjs.map +1 -1
  8. package/dist/tsup/agent-os/index.d.cts +0 -2
  9. package/dist/tsup/agent-os/index.d.ts +0 -2
  10. package/dist/tsup/agent-os/index.js +1 -1
  11. package/dist/tsup/agent-os/index.js.map +1 -1
  12. package/dist/tsup/{chunk-OB5JLDBM.js → chunk-3KHT4UQA.js} +2 -2
  13. package/dist/tsup/{chunk-R3UI7MO3.cjs → chunk-4C2R5ZGV.cjs} +165 -146
  14. package/dist/tsup/chunk-4C2R5ZGV.cjs.map +1 -0
  15. package/dist/tsup/{chunk-JKDAOE4T.js → chunk-7YQ2BGJR.js} +4 -4
  16. package/dist/tsup/{chunk-QQ454DVR.js → chunk-BRYK7XVR.js} +2 -2
  17. package/dist/tsup/{chunk-JJCUSUWO.js → chunk-BSQWFYSP.js} +2 -2
  18. package/dist/tsup/chunk-BSQWFYSP.js.map +1 -0
  19. package/dist/tsup/{chunk-LTGBHN5Z.js → chunk-CSOHAAZK.js} +1 -1
  20. package/dist/tsup/chunk-CSOHAAZK.js.map +1 -0
  21. package/dist/tsup/{chunk-PFHGTLF2.cjs → chunk-EOEB2O7Z.cjs} +10 -10
  22. package/dist/tsup/{chunk-PFHGTLF2.cjs.map → chunk-EOEB2O7Z.cjs.map} +1 -1
  23. package/dist/tsup/{chunk-M5J3PXNU.js → chunk-FHRRLHJE.js} +2 -2
  24. package/dist/tsup/{chunk-CE6NBGOL.cjs → chunk-FTHC2AMB.cjs} +3 -3
  25. package/dist/tsup/{chunk-CE6NBGOL.cjs.map → chunk-FTHC2AMB.cjs.map} +1 -1
  26. package/dist/tsup/{chunk-B6WTPGOR.js → chunk-FV63WBQ5.js} +30 -11
  27. package/dist/tsup/chunk-FV63WBQ5.js.map +1 -0
  28. package/dist/tsup/{chunk-64CRWLOX.js → chunk-HAKSJXR4.js} +3 -3
  29. package/dist/tsup/{chunk-SWQCSORE.cjs → chunk-NP7HZL6X.cjs} +3 -3
  30. package/dist/tsup/{chunk-SWQCSORE.cjs.map → chunk-NP7HZL6X.cjs.map} +1 -1
  31. package/dist/tsup/{chunk-NGJWQMUU.cjs → chunk-NWCAIWHL.cjs} +1 -1
  32. package/dist/tsup/chunk-NWCAIWHL.cjs.map +1 -0
  33. package/dist/tsup/{chunk-JMO6AVUC.cjs → chunk-NWHEYTL2.cjs} +3 -3
  34. package/dist/tsup/{chunk-JMO6AVUC.cjs.map → chunk-NWHEYTL2.cjs.map} +1 -1
  35. package/dist/tsup/{chunk-ERBNWARB.cjs → chunk-RIZ57PM3.cjs} +4 -4
  36. package/dist/tsup/{chunk-ERBNWARB.cjs.map → chunk-RIZ57PM3.cjs.map} +1 -1
  37. package/dist/tsup/{chunk-6HW3TU7Q.js → chunk-WIRWF3Q2.js} +2 -2
  38. package/dist/tsup/{chunk-YVVFOKEP.cjs → chunk-WMRE434Q.cjs} +2 -2
  39. package/dist/tsup/chunk-WMRE434Q.cjs.map +1 -0
  40. package/dist/tsup/{chunk-DAC73W53.cjs → chunk-XVEADNHV.cjs} +7 -7
  41. package/dist/tsup/{chunk-DAC73W53.cjs.map → chunk-XVEADNHV.cjs.map} +1 -1
  42. package/dist/tsup/client/mod.cjs +5 -5
  43. package/dist/tsup/client/mod.d.cts +5 -2
  44. package/dist/tsup/client/mod.d.ts +5 -2
  45. package/dist/tsup/client/mod.js +4 -4
  46. package/dist/tsup/common/log.cjs +2 -2
  47. package/dist/tsup/common/log.js +1 -1
  48. package/dist/tsup/common/websocket.cjs +3 -3
  49. package/dist/tsup/common/websocket.js +2 -2
  50. package/dist/tsup/{config-RV6gIa2L.d.ts → config-Cv6pjCt-.d.ts} +0 -4
  51. package/dist/tsup/{config-CuKzfH58.d.cts → config-osdJqQwX.d.cts} +0 -4
  52. package/dist/tsup/{context-DoMKZBQA.d.ts → context-CoVbKBuk.d.ts} +1 -1
  53. package/dist/tsup/{context-DPCxyjax.d.cts → context-DpjrM7n7.d.cts} +1 -1
  54. package/dist/tsup/db/drizzle.cjs +2 -2
  55. package/dist/tsup/db/drizzle.js +1 -1
  56. package/dist/tsup/db/mod.cjs +3 -3
  57. package/dist/tsup/db/mod.js +2 -2
  58. package/dist/tsup/dynamic/mod.cjs +2 -2
  59. package/dist/tsup/dynamic/mod.d.cts +1 -1
  60. package/dist/tsup/dynamic/mod.d.ts +1 -1
  61. package/dist/tsup/dynamic/mod.js +1 -1
  62. package/dist/tsup/inspector/mod.cjs +5 -5
  63. package/dist/tsup/inspector/mod.js +4 -4
  64. package/dist/tsup/inspector/workflow.cjs +4 -4
  65. package/dist/tsup/inspector/workflow.js +3 -3
  66. package/dist/tsup/inspector-tab/mod.cjs +2 -2
  67. package/dist/tsup/inspector-tab/mod.d.cts +2 -2
  68. package/dist/tsup/inspector-tab/mod.d.ts +2 -2
  69. package/dist/tsup/inspector-tab/mod.js +1 -1
  70. package/dist/tsup/mod.cjs +189 -417
  71. package/dist/tsup/mod.cjs.map +1 -1
  72. package/dist/tsup/mod.d.cts +3 -3
  73. package/dist/tsup/mod.d.ts +3 -3
  74. package/dist/tsup/mod.js +94 -322
  75. package/dist/tsup/mod.js.map +1 -1
  76. package/dist/tsup/test/mod.cjs +6 -6
  77. package/dist/tsup/test/mod.d.cts +1 -1
  78. package/dist/tsup/test/mod.d.ts +1 -1
  79. package/dist/tsup/test/mod.js +4 -4
  80. package/dist/tsup/utils.cjs +2 -2
  81. package/dist/tsup/utils.js +1 -1
  82. package/dist/tsup/workflow/mod.cjs +21 -69
  83. package/dist/tsup/workflow/mod.cjs.map +1 -1
  84. package/dist/tsup/workflow/mod.d.cts +3 -3
  85. package/dist/tsup/workflow/mod.d.ts +3 -3
  86. package/dist/tsup/workflow/mod.js +16 -64
  87. package/dist/tsup/workflow/mod.js.map +1 -1
  88. package/package.json +9 -9
  89. package/src/actor/config.ts +0 -2
  90. package/src/client/config.ts +3 -0
  91. package/src/client/raw-utils.ts +7 -2
  92. package/src/common/fetch-like.ts +14 -0
  93. package/src/engine-client/actor-http-client.ts +16 -6
  94. package/src/registry/napi-runtime.ts +0 -8
  95. package/src/registry/native.ts +65 -332
  96. package/src/registry/run-handler-coordinator.test.ts +0 -102
  97. package/src/registry/run-handler-coordinator.ts +17 -84
  98. package/src/registry/runtime.ts +0 -2
  99. package/src/registry/wasm-runtime.ts +0 -8
  100. package/src/workflow/context.ts +0 -20
  101. package/src/workflow/driver.ts +1 -25
  102. package/src/workflow/mod.ts +12 -46
  103. package/dist/tsup/chunk-B6WTPGOR.js.map +0 -1
  104. package/dist/tsup/chunk-JJCUSUWO.js.map +0 -1
  105. package/dist/tsup/chunk-LTGBHN5Z.js.map +0 -1
  106. package/dist/tsup/chunk-NGJWQMUU.cjs.map +0 -1
  107. package/dist/tsup/chunk-R3UI7MO3.cjs.map +0 -1
  108. package/dist/tsup/chunk-YVVFOKEP.cjs.map +0 -1
  109. package/src/registry/lost-callbacks.test.ts +0 -64
  110. /package/dist/tsup/{chunk-OB5JLDBM.js.map → chunk-3KHT4UQA.js.map} +0 -0
  111. /package/dist/tsup/{chunk-JKDAOE4T.js.map → chunk-7YQ2BGJR.js.map} +0 -0
  112. /package/dist/tsup/{chunk-QQ454DVR.js.map → chunk-BRYK7XVR.js.map} +0 -0
  113. /package/dist/tsup/{chunk-M5J3PXNU.js.map → chunk-FHRRLHJE.js.map} +0 -0
  114. /package/dist/tsup/{chunk-64CRWLOX.js.map → chunk-HAKSJXR4.js.map} +0 -0
  115. /package/dist/tsup/{chunk-6HW3TU7Q.js.map → chunk-WIRWF3Q2.js.map} +0 -0
package/dist/tsup/mod.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } async function _asyncNullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return await rhsFn(); } } var _class; var _class2; var _class3;
2
2
 
3
- var _chunkERBNWARBcjs = require('./chunk-ERBNWARB.cjs');
3
+ var _chunkRIZ57PM3cjs = require('./chunk-RIZ57PM3.cjs');
4
4
 
5
5
 
6
6
 
@@ -17,11 +17,12 @@ var _chunkERBNWARBcjs = require('./chunk-ERBNWARB.cjs');
17
17
 
18
18
 
19
19
 
20
- var _chunkNGJWQMUUcjs = require('./chunk-NGJWQMUU.cjs');
20
+ var _chunkNWCAIWHLcjs = require('./chunk-NWCAIWHL.cjs');
21
21
 
22
22
 
23
23
 
24
24
 
25
+ var _chunkFTHC2AMBcjs = require('./chunk-FTHC2AMB.cjs');
25
26
 
26
27
 
27
28
 
@@ -35,18 +36,17 @@ var _chunkNGJWQMUUcjs = require('./chunk-NGJWQMUU.cjs');
35
36
 
36
37
 
37
38
 
38
- var _chunkR3UI7MO3cjs = require('./chunk-R3UI7MO3.cjs');
39
39
 
40
40
 
41
41
 
42
- var _chunkMYWZCDMLcjs = require('./chunk-MYWZCDML.cjs');
43
42
 
43
+ var _chunk4C2R5ZGVcjs = require('./chunk-4C2R5ZGV.cjs');
44
44
 
45
45
 
46
46
 
47
- var _chunkCE6NBGOLcjs = require('./chunk-CE6NBGOL.cjs');
47
+ var _chunkMYWZCDMLcjs = require('./chunk-MYWZCDML.cjs');
48
+ require('./chunk-NWHEYTL2.cjs');
48
49
  require('./chunk-KVFIONKQ.cjs');
49
- require('./chunk-JMO6AVUC.cjs');
50
50
 
51
51
 
52
52
 
@@ -80,7 +80,7 @@ require('./chunk-JMO6AVUC.cjs');
80
80
 
81
81
 
82
82
 
83
- var _chunkYVVFOKEPcjs = require('./chunk-YVVFOKEP.cjs');
83
+ var _chunkWMRE434Qcjs = require('./chunk-WMRE434Q.cjs');
84
84
 
85
85
 
86
86
 
@@ -97,7 +97,7 @@ var _chunkMGI2VVF6cjs = require('./chunk-MGI2VVF6.cjs');
97
97
 
98
98
  // src/actor/log.ts
99
99
  function loggerWithoutContext() {
100
- return _chunkYVVFOKEPcjs.getLogger.call(void 0, "actor-runtime");
100
+ return _chunkWMRE434Qcjs.getLogger.call(void 0, "actor-runtime");
101
101
  }
102
102
 
103
103
  // src/actor/definition.ts
@@ -137,10 +137,10 @@ function actor(input) {
137
137
  warnDeprecatedOptionKeys(
138
138
  input == null ? void 0 : input.options
139
139
  );
140
- const config = _chunkNGJWQMUUcjs.ActorConfigSchema.parse(input);
141
- _chunkNGJWQMUUcjs.flattenActionHandlers.call(void 0, config.actions);
142
- _chunkNGJWQMUUcjs.flattenActionInputSchemas.call(void 0, config.actions, config.actionInputSchemas);
143
- _chunkNGJWQMUUcjs.flattenActionTraceSamplers.call(void 0, config.actions, (_a = config.tracing) == null ? void 0 : _a.actions);
140
+ const config = _chunkNWCAIWHLcjs.ActorConfigSchema.parse(input);
141
+ _chunkNWCAIWHLcjs.flattenActionHandlers.call(void 0, config.actions);
142
+ _chunkNWCAIWHLcjs.flattenActionInputSchemas.call(void 0, config.actions, config.actionInputSchemas);
143
+ _chunkNWCAIWHLcjs.flattenActionTraceSamplers.call(void 0, config.actions, (_a = config.tracing) == null ? void 0 : _a.actions);
144
144
  return new ActorDefinition(config);
145
145
  }
146
146
  function isStaticActorDefinition(definition) {
@@ -239,7 +239,7 @@ function validateSchemaSync(schemas, key, data) {
239
239
  var _virtualwebsocket = require('@rivetkit/virtual-websocket');
240
240
  var _ws = require('hono/ws');
241
241
  function logger() {
242
- return _chunkYVVFOKEPcjs.getLogger.call(void 0, "inline-websocket-adapter");
242
+ return _chunkWMRE434Qcjs.getLogger.call(void 0, "inline-websocket-adapter");
243
243
  }
244
244
  var InlineWebSocketAdapter = class {
245
245
  #handler;
@@ -391,7 +391,7 @@ var InlineWebSocketAdapter = class {
391
391
 
392
392
  // src/registry/log.ts
393
393
  function logger2() {
394
- return _chunkYVVFOKEPcjs.getLogger.call(void 0, "registry");
394
+ return _chunkWMRE434Qcjs.getLogger.call(void 0, "registry");
395
395
  }
396
396
 
397
397
  // src/serverless/configure.ts
@@ -437,8 +437,8 @@ async function configureServerlessPool(config) {
437
437
  );
438
438
  }
439
439
  const customConfig = config.configurePool;
440
- const clientConfig = _chunkR3UI7MO3cjs.convertRegistryConfigToClientConfig.call(void 0, config);
441
- const dcsRes = await _chunkR3UI7MO3cjs.getDatacenters.call(void 0, clientConfig);
440
+ const clientConfig = _chunk4C2R5ZGVcjs.convertRegistryConfigToClientConfig.call(void 0, config);
441
+ const dcsRes = await _chunk4C2R5ZGVcjs.getDatacenters.call(void 0, clientConfig);
442
442
  const poolName = _nullishCoalesce(customConfig.name, () => ( "default"));
443
443
  const serverlessToken = _nullishCoalesce(config.token, () => ( config.publicToken));
444
444
  const headers = {
@@ -460,7 +460,7 @@ async function configureServerlessPool(config) {
460
460
  metadata: _nullishCoalesce(customConfig.metadata, () => ( {})),
461
461
  drain_on_version_upgrade: _nullishCoalesce(customConfig.drainOnVersionUpgrade, () => ( true))
462
462
  };
463
- await _chunkR3UI7MO3cjs.updateRunnerConfig.call(void 0, clientConfig, poolName, {
463
+ await _chunk4C2R5ZGVcjs.updateRunnerConfig.call(void 0, clientConfig, poolName, {
464
464
  datacenters: Object.fromEntries(
465
465
  dcsRes.datacenters.map((dc) => [dc.name, serverlessConfig])
466
466
  )
@@ -477,7 +477,7 @@ async function configureServerlessPool(config) {
477
477
  logger2().warn({
478
478
  msg: "serverless pool configuration attempt failed",
479
479
  attempts,
480
- error: _chunkYVVFOKEPcjs.stringifyError.call(void 0, error)
480
+ error: _chunkWMRE434Qcjs.stringifyError.call(void 0, error)
481
481
  });
482
482
  await sleep(CONFIGURE_RETRY_DELAY_MS);
483
483
  }
@@ -485,7 +485,7 @@ async function configureServerlessPool(config) {
485
485
  logger2().error({
486
486
  msg: "failed to configure serverless pool, validate endpoint is configured correctly then restart this process",
487
487
  attempts,
488
- error: _chunkYVVFOKEPcjs.stringifyError.call(void 0, lastError)
488
+ error: _chunkWMRE434Qcjs.stringifyError.call(void 0, lastError)
489
489
  });
490
490
  throw lastError;
491
491
  }
@@ -496,10 +496,10 @@ var _zod = require('zod');
496
496
  // src/registry/config/envoy.ts
497
497
  var _v4 = require('zod/v4');
498
498
  var EnvoyConfigSchema = _v4.z.object({
499
- poolName: _v4.z.string().default(() => _nullishCoalesce(_chunkYVVFOKEPcjs.getRivetPool.call(void 0, ), () => ( "default"))),
500
- version: _v4.z.number().default(() => _nullishCoalesce(_chunkYVVFOKEPcjs.getRivetEnvoyVersion.call(void 0, ), () => ( 1))),
499
+ poolName: _v4.z.string().default(() => _nullishCoalesce(_chunkWMRE434Qcjs.getRivetPool.call(void 0, ), () => ( "default"))),
500
+ version: _v4.z.number().default(() => _nullishCoalesce(_chunkWMRE434Qcjs.getRivetEnvoyVersion.call(void 0, ), () => ( 1))),
501
501
  // Deprecated.
502
- totalSlots: _v4.z.number().default(() => _nullishCoalesce(_chunkYVVFOKEPcjs.getRivetTotalSlots.call(void 0, ), () => ( 1e5))),
502
+ totalSlots: _v4.z.number().default(() => _nullishCoalesce(_chunkWMRE434Qcjs.getRivetTotalSlots.call(void 0, ), () => ( 1e5))),
503
503
  envoyKey: _v4.z.string().optional()
504
504
  });
505
505
 
@@ -537,7 +537,7 @@ var ServerlessConfigSchema = _v4.z.object({
537
537
  *
538
538
  * Can also be set via RIVET_PUBLIC_ENDPOINT environment variable.
539
539
  */
540
- publicEndpoint: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkYVVFOKEPcjs.getRivetPublicEndpoint.call(void 0, )))),
540
+ publicEndpoint: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkWMRE434Qcjs.getRivetPublicEndpoint.call(void 0, )))),
541
541
  /**
542
542
  * Token that clients should use when connecting via the public endpoint.
543
543
  *
@@ -545,7 +545,7 @@ var ServerlessConfigSchema = _v4.z.object({
545
545
  *
546
546
  * Can also be specified in the publicEndpoint URL as `https://namespace:token@host`.
547
547
  */
548
- publicToken: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkYVVFOKEPcjs.getRivetPublicToken.call(void 0, ))))
548
+ publicToken: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkWMRE434Qcjs.getRivetPublicToken.call(void 0, ))))
549
549
  // There is no publicNamespace config option because the frontend and backend
550
550
  // cannot use different namespaces. The namespace is extracted from the
551
551
  // publicEndpoint URL auth syntax if provided.
@@ -599,7 +599,7 @@ var RegistryConfigSchema = _zod.z.object({
599
599
  * Runtime binding to use for RivetKit core.
600
600
  * */
601
601
  runtime: RuntimeKindSchema.optional().transform((val, ctx) => {
602
- const rawRuntime = _nullishCoalesce(val, () => ( _chunkYVVFOKEPcjs.getRivetkitRuntime.call(void 0, )));
602
+ const rawRuntime = _nullishCoalesce(val, () => ( _chunkWMRE434Qcjs.getRivetkitRuntime.call(void 0, )));
603
603
  if (rawRuntime === void 0) {
604
604
  return "auto";
605
605
  }
@@ -636,7 +636,7 @@ var RegistryConfigSchema = _zod.z.object({
636
636
  * */
637
637
  logging: _zod.z.object({
638
638
  baseLogger: _zod.z.custom().optional(),
639
- level: _chunkYVVFOKEPcjs.LogLevelSchema.optional()
639
+ level: _chunkWMRE434Qcjs.LogLevelSchema.optional()
640
640
  }).optional().default(() => ({})),
641
641
  // MARK: Routing
642
642
  // // This is a function to allow for lazy configuration of upgradeWebSocket on the
@@ -654,9 +654,9 @@ var RegistryConfigSchema = _zod.z.object({
654
654
  *
655
655
  * Can also be set via RIVET_ENDPOINT environment variables.
656
656
  */
657
- endpoint: _zod.z.string().optional().transform((val) => _nullishCoalesce(_nullishCoalesce(val, () => ( _chunkYVVFOKEPcjs.getRivetEngine.call(void 0, ))), () => ( _chunkYVVFOKEPcjs.getRivetEndpoint.call(void 0, )))),
658
- token: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkYVVFOKEPcjs.getRivetToken.call(void 0, )))),
659
- namespace: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkYVVFOKEPcjs.getRivetNamespace.call(void 0, )))),
657
+ endpoint: _zod.z.string().optional().transform((val) => _nullishCoalesce(_nullishCoalesce(val, () => ( _chunkWMRE434Qcjs.getRivetEngine.call(void 0, ))), () => ( _chunkWMRE434Qcjs.getRivetEndpoint.call(void 0, )))),
658
+ token: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkWMRE434Qcjs.getRivetToken.call(void 0, )))),
659
+ namespace: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkWMRE434Qcjs.getRivetNamespace.call(void 0, )))),
660
660
  headers: _zod.z.record(_zod.z.string(), _zod.z.string()).optional().default({}),
661
661
  // MARK: Client
662
662
  // TODO:
@@ -696,21 +696,21 @@ var RegistryConfigSchema = _zod.z.object({
696
696
  *
697
697
  * Starts the full Rust engine process locally.
698
698
  */
699
- startEngine: _zod.z.boolean().default(() => _chunkYVVFOKEPcjs.getRivetRunEngine.call(void 0, )),
699
+ startEngine: _zod.z.boolean().default(() => _chunkWMRE434Qcjs.getRivetRunEngine.call(void 0, )),
700
700
  /**
701
701
  * @experimental
702
702
  *
703
703
  * Host to bind the spawned local engine process to.
704
704
  */
705
- engineHost: _zod.z.string().optional().default(() => _nullishCoalesce(_chunkYVVFOKEPcjs.getRivetRunEngineHost.call(void 0, ), () => ( _chunkR3UI7MO3cjs.ENGINE_HOST))),
705
+ engineHost: _zod.z.string().optional().default(() => _nullishCoalesce(_chunkWMRE434Qcjs.getRivetRunEngineHost.call(void 0, ), () => ( _chunk4C2R5ZGVcjs.ENGINE_HOST))),
706
706
  /**
707
707
  * @experimental
708
708
  *
709
709
  * Port to bind the spawned local engine process to.
710
710
  */
711
- enginePort: _zod.z.number().int().min(1).max(65535).optional().default(() => _nullishCoalesce(_chunkYVVFOKEPcjs.getRivetRunEnginePort.call(void 0, ), () => ( _chunkR3UI7MO3cjs.ENGINE_PORT))),
711
+ enginePort: _zod.z.number().int().min(1).max(65535).optional().default(() => _nullishCoalesce(_chunkWMRE434Qcjs.getRivetRunEnginePort.call(void 0, ), () => ( _chunk4C2R5ZGVcjs.ENGINE_PORT))),
712
712
  /** @experimental */
713
- engineVersion: _zod.z.string().optional().default(() => _nullishCoalesce(_chunkYVVFOKEPcjs.getRivetRunEngineVersion.call(void 0, ), () => ( _chunkYVVFOKEPcjs.VERSION))),
713
+ engineVersion: _zod.z.string().optional().default(() => _nullishCoalesce(_chunkWMRE434Qcjs.getRivetRunEngineVersion.call(void 0, ), () => ( _chunkWMRE434Qcjs.VERSION))),
714
714
  /**
715
715
  * Starts the first-party Services actor host when RivetKit manages
716
716
  * a local engine. Defaults to the local-engine decision. Set
@@ -764,7 +764,7 @@ var RegistryConfigSchema = _zod.z.object({
764
764
  }))
765
765
  }).transform((config, ctx) => {
766
766
  var _a, _b, _c;
767
- const isDevEnv = _chunkYVVFOKEPcjs.isDev.call(void 0, );
767
+ const isDevEnv = _chunkWMRE434Qcjs.isDev.call(void 0, );
768
768
  const sqliteBackend = _nullishCoalesce(((_a = config.sqlite) == null ? void 0 : _a.backend), () => ( ((_b = config.test) == null ? void 0 : _b.sqliteBackend)));
769
769
  if (config.runtime === "wasm" && sqliteBackend === "local") {
770
770
  ctx.addIssue({
@@ -774,7 +774,7 @@ var RegistryConfigSchema = _zod.z.object({
774
774
  });
775
775
  }
776
776
  const sqlite = config.runtime === "wasm" && config.sqlite === void 0 ? { backend: "remote" } : config.sqlite;
777
- const parsedEndpoint = config.endpoint ? _chunkR3UI7MO3cjs.tryParseEndpoint.call(void 0, ctx, {
777
+ const parsedEndpoint = config.endpoint ? _chunk4C2R5ZGVcjs.tryParseEndpoint.call(void 0, ctx, {
778
778
  endpoint: config.endpoint,
779
779
  path: ["endpoint"],
780
780
  namespace: config.namespace,
@@ -792,18 +792,18 @@ var RegistryConfigSchema = _zod.z.object({
792
792
  message: "configurePool requires either endpoint or startEngine"
793
793
  });
794
794
  }
795
- const localEngineEndpoint = _chunkR3UI7MO3cjs.buildEngineEndpoint.call(void 0,
795
+ const localEngineEndpoint = _chunk4C2R5ZGVcjs.buildEngineEndpoint.call(void 0,
796
796
  config.engineHost,
797
797
  config.enginePort
798
798
  );
799
799
  const endpoint = config.startEngine ? localEngineEndpoint : _nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.endpoint), () => ( (isDevEnv ? localEngineEndpoint : void 0)));
800
- const startServices = _nullishCoalesce(_nullishCoalesce(config.startServices, () => ( _chunkYVVFOKEPcjs.getRivetRunServices.call(void 0, ))), () => ( Boolean(endpoint && _chunkR3UI7MO3cjs.isLocalEngineEndpoint.call(void 0, endpoint))));
800
+ const startServices = _nullishCoalesce(_nullishCoalesce(config.startServices, () => ( _chunkWMRE434Qcjs.getRivetRunServices.call(void 0, ))), () => ( Boolean(endpoint && _chunk4C2R5ZGVcjs.isLocalEngineEndpoint.call(void 0, endpoint))));
801
801
  const validateServerlessEndpoint = Boolean(
802
802
  config.startEngine || parsedEndpoint
803
803
  );
804
804
  const namespace = _nullishCoalesce(_nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.namespace), () => ( config.namespace)), () => ( "default"));
805
- const token = _nullishCoalesce(_nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.token), () => ( config.token)), () => ( (endpoint && _chunkR3UI7MO3cjs.isLocalEngineEndpoint.call(void 0, endpoint) ? "default" : void 0)));
806
- const parsedPublicEndpoint = config.serverless.publicEndpoint ? _chunkR3UI7MO3cjs.tryParseEndpoint.call(void 0, ctx, {
805
+ const token = _nullishCoalesce(_nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.token), () => ( config.token)), () => ( (endpoint && _chunk4C2R5ZGVcjs.isLocalEngineEndpoint.call(void 0, endpoint) ? "default" : void 0)));
806
+ const parsedPublicEndpoint = config.serverless.publicEndpoint ? _chunk4C2R5ZGVcjs.tryParseEndpoint.call(void 0, ctx, {
807
807
  endpoint: config.serverless.publicEndpoint,
808
808
  path: ["serverless", "publicEndpoint"]
809
809
  }) : void 0;
@@ -839,7 +839,7 @@ function buildActorNames(config) {
839
839
  Object.keys(config.use).map((actorName) => {
840
840
  const definition = config.use[actorName];
841
841
  const options = _nullishCoalesce(definition.config.options, () => ( {}));
842
- const runMeta = _chunkNGJWQMUUcjs.getRunMetadata.call(void 0, definition.config.run);
842
+ const runMeta = _chunkNWCAIWHLcjs.getRunMetadata.call(void 0, definition.config.run);
843
843
  const metadata = {};
844
844
  metadata.icon = _nullishCoalesce(options.icon, () => ( runMeta.icon));
845
845
  metadata.name = _nullishCoalesce(options.name, () => ( runMeta.name));
@@ -907,7 +907,7 @@ var DocRegistryConfigSchema = _zod.z.object({
907
907
  noWelcome: _zod.z.boolean().optional().describe("Disable the welcome message on startup. Default: false"),
908
908
  sqlite: DocSqliteConfigSchema,
909
909
  logging: _zod.z.object({
910
- level: _chunkYVVFOKEPcjs.LogLevelSchema.optional().describe(
910
+ level: _chunkWMRE434Qcjs.LogLevelSchema.optional().describe(
911
911
  "Log level for RivetKit. Default: 'warn'"
912
912
  )
913
913
  }).optional().describe("Logging configuration."),
@@ -1537,7 +1537,7 @@ var NapiCoreRuntime = (_class = class {
1537
1537
  if (!(active == null ? void 0 : active.sameActorInstance(ownerCtx))) {
1538
1538
  return ownerCtx;
1539
1539
  }
1540
- const applicationSpan = _chunkR3UI7MO3cjs.readActiveTraceHeaders.call(void 0, );
1540
+ const applicationSpan = _chunk4C2R5ZGVcjs.readActiveTraceHeaders.call(void 0, );
1541
1541
  if (!applicationSpan) {
1542
1542
  return active;
1543
1543
  }
@@ -1732,12 +1732,6 @@ var NapiCoreRuntime = (_class = class {
1732
1732
  actorId(ctx) {
1733
1733
  return asNativeActorContext(ctx).actorId();
1734
1734
  }
1735
- actorGeneration(ctx) {
1736
- return _nullishCoalesce(asNativeActorContext(ctx).generation(), () => ( void 0));
1737
- }
1738
- actorIsLost(ctx) {
1739
- return asNativeActorContext(ctx).isLost();
1740
- }
1741
1735
  runWithActorInvocationContext(ctx, run) {
1742
1736
  return this.#runAs(asNativeActorContext(ctx), run);
1743
1737
  }
@@ -1746,7 +1740,7 @@ var NapiCoreRuntime = (_class = class {
1746
1740
  const span = (_a = nativeCtx.invocationTraceContext()) == null ? void 0 : _a.span;
1747
1741
  return this.#invocationContext.run(
1748
1742
  nativeCtx,
1749
- () => _chunkR3UI7MO3cjs.runWithActorInvocationSpan.call(void 0, span, run)
1743
+ () => _chunk4C2R5ZGVcjs.runWithActorInvocationSpan.call(void 0, span, run)
1750
1744
  );
1751
1745
  }
1752
1746
  actorInvocationTraceContext(ctx) {
@@ -2121,8 +2115,8 @@ function runtimeBytesToArrayBuffer(value) {
2121
2115
  function buildNativeHttpRequest(init) {
2122
2116
  var _a;
2123
2117
  const headers = new Headers(init.headers);
2124
- const originalUrl = headers.get(_chunkR3UI7MO3cjs.HEADER_ORIGINAL_REQUEST_URL);
2125
- headers.delete(_chunkR3UI7MO3cjs.HEADER_ORIGINAL_REQUEST_URL);
2118
+ const originalUrl = headers.get(_chunk4C2R5ZGVcjs.HEADER_ORIGINAL_REQUEST_URL);
2119
+ headers.delete(_chunk4C2R5ZGVcjs.HEADER_ORIGINAL_REQUEST_URL);
2126
2120
  const url = _nullishCoalesce(originalUrl, () => ( (init.uri.startsWith("http") ? init.uri : new URL(init.uri, "http://127.0.0.1").toString())));
2127
2121
  const method2 = init.method.toUpperCase();
2128
2122
  const bodyForbidden = method2 === "GET" || method2 === "HEAD";
@@ -2201,7 +2195,7 @@ async function pumpResponseBody(reader, stream) {
2201
2195
  }
2202
2196
  } catch (error) {
2203
2197
  try {
2204
- await stream.error(_chunkYVVFOKEPcjs.stringifyError.call(void 0, error));
2198
+ await stream.error(_chunkWMRE434Qcjs.stringifyError.call(void 0, error));
2205
2199
  } catch (streamError) {
2206
2200
  logger2().debug({
2207
2201
  msg: "failed to report native http response stream error",
@@ -2357,27 +2351,6 @@ function notifyStateChanged(state) {
2357
2351
  waiter();
2358
2352
  }
2359
2353
  }
2360
- function createRunState(actorGeneration) {
2361
- return {
2362
- actorGeneration,
2363
- active: false,
2364
- closed: false,
2365
- exclusive: false,
2366
- exclusiveGeneration: 0,
2367
- inspectorInitialized: false,
2368
- queued: 0,
2369
- waiters: /* @__PURE__ */ new Set()
2370
- };
2371
- }
2372
- function closeRunState(state, disposeInspector = true) {
2373
- var _a, _b;
2374
- state.closed = true;
2375
- if (disposeInspector) {
2376
- (_b = (_a = state.inspector) == null ? void 0 : _a.dispose) == null ? void 0 : _b.call(_a);
2377
- }
2378
- state.inspector = void 0;
2379
- notifyStateChanged(state);
2380
- }
2381
2354
  function waitForStateChange(state) {
2382
2355
  return new Promise((resolve) => {
2383
2356
  state.waiters.add(resolve);
@@ -2390,13 +2363,10 @@ var RunHandlerCoordinator = class {
2390
2363
  this.#run = run;
2391
2364
  }
2392
2365
  get inspectorKind() {
2393
- return _chunkNGJWQMUUcjs.getRunInspectorKind.call(void 0, this.#run);
2366
+ return _chunkNWCAIWHLcjs.getRunInspectorKind.call(void 0, this.#run);
2394
2367
  }
2395
- async run(actorId, restart, callback, actorGeneration) {
2396
- const state = this.#getOrCreate(actorId, actorGeneration);
2397
- if (state.closed) {
2398
- return "closed";
2399
- }
2368
+ async run(actorId, restart, callback) {
2369
+ const state = this.#getOrCreate(actorId);
2400
2370
  state.restart = restart;
2401
2371
  this.#initializeInspector(actorId, state);
2402
2372
  state.queued += 1;
@@ -2423,27 +2393,21 @@ var RunHandlerCoordinator = class {
2423
2393
  notifyStateChanged(state);
2424
2394
  }
2425
2395
  }
2426
- getInspector(actorId, restart, actorGeneration) {
2396
+ getInspector(actorId, restart) {
2427
2397
  var _a;
2428
- const state = this.#getOrCreate(actorId, actorGeneration);
2429
- if (state.closed) {
2430
- return void 0;
2431
- }
2398
+ const state = this.#getOrCreate(actorId);
2432
2399
  state.restart = restart;
2433
2400
  this.#initializeInspector(actorId, state);
2434
2401
  return (_a = state.inspector) == null ? void 0 : _a.inspector;
2435
2402
  }
2436
- /**
2437
- * Closes the run state for `actorId`. With `actorGeneration`, only state owned by that
2438
- * generation is closed, so an older generation's late cleanup cannot close a newer one.
2439
- */
2440
- destroy(actorId, actorGeneration, options = {}) {
2403
+ destroy(actorId) {
2404
+ var _a, _b;
2441
2405
  const state = this.#states.get(actorId);
2442
2406
  if (!state) return;
2443
- if (actorGeneration !== void 0 && state.actorGeneration !== void 0 && state.actorGeneration !== actorGeneration) {
2444
- return;
2445
- }
2446
- closeRunState(state, _nullishCoalesce(options.disposeInspector, () => ( true)));
2407
+ state.closed = true;
2408
+ (_b = (_a = state.inspector) == null ? void 0 : _a.dispose) == null ? void 0 : _b.call(_a);
2409
+ state.inspector = void 0;
2410
+ notifyStateChanged(state);
2447
2411
  this.#states.delete(actorId);
2448
2412
  }
2449
2413
  #control(actorId, state) {
@@ -2489,29 +2453,26 @@ var RunHandlerCoordinator = class {
2489
2453
  }
2490
2454
  };
2491
2455
  }
2492
- #getOrCreate(actorId, actorGeneration) {
2456
+ #getOrCreate(actorId) {
2493
2457
  let state = this.#states.get(actorId);
2494
- if (state && actorGeneration !== void 0 && state.actorGeneration !== void 0 && state.actorGeneration !== actorGeneration) {
2495
- if (actorGeneration < state.actorGeneration) {
2496
- const detached = createRunState(actorGeneration);
2497
- detached.closed = true;
2498
- return detached;
2499
- }
2500
- closeRunState(state, false);
2501
- this.#states.delete(actorId);
2502
- state = void 0;
2503
- }
2504
2458
  if (!state) {
2505
- state = createRunState(actorGeneration);
2459
+ state = {
2460
+ active: false,
2461
+ closed: false,
2462
+ exclusive: false,
2463
+ exclusiveGeneration: 0,
2464
+ inspectorInitialized: false,
2465
+ queued: 0,
2466
+ waiters: /* @__PURE__ */ new Set()
2467
+ };
2506
2468
  this.#states.set(actorId, state);
2507
2469
  }
2508
2470
  return state;
2509
2471
  }
2510
2472
  #initializeInspector(actorId, state) {
2511
2473
  if (state.inspectorInitialized) return;
2512
- const inspector = _chunkNGJWQMUUcjs.createRunInspector.call(void 0, this.#run, {
2474
+ const inspector = _chunkNWCAIWHLcjs.createRunInspector.call(void 0, this.#run, {
2513
2475
  actorId,
2514
- actorGeneration: state.actorGeneration,
2515
2476
  control: this.#control(actorId, state)
2516
2477
  });
2517
2478
  if (this.inspectorKind === "workflow") {
@@ -2839,12 +2800,6 @@ var WasmCoreRuntime = (_class2 = class {
2839
2800
  actorId(ctx) {
2840
2801
  return callHandle(asWasmActorContext(ctx), "actorId");
2841
2802
  }
2842
- actorGeneration(ctx) {
2843
- return _nullishCoalesce(callHandle(asWasmActorContext(ctx), "generation"), () => ( void 0));
2844
- }
2845
- actorIsLost(ctx) {
2846
- return callHandle(asWasmActorContext(ctx), "isLost");
2847
- }
2848
2803
  runWithActorInvocationContext(_ctx, run) {
2849
2804
  return run();
2850
2805
  }
@@ -3478,7 +3433,7 @@ async function loadAutoRuntime(config, loaders = defaultRuntimeLoaders) {
3478
3433
  nativeError = error;
3479
3434
  logger2().warn({
3480
3435
  msg: "native runtime failed to load; falling back to wasm",
3481
- error: _chunkYVVFOKEPcjs.stringifyError.call(void 0, error)
3436
+ error: _chunkWMRE434Qcjs.stringifyError.call(void 0, error)
3482
3437
  });
3483
3438
  }
3484
3439
  try {
@@ -3487,7 +3442,7 @@ async function loadAutoRuntime(config, loaders = defaultRuntimeLoaders) {
3487
3442
  throw new (0, _chunkMGI2VVF6cjs.RivetError)(
3488
3443
  "config",
3489
3444
  "runtime_unavailable",
3490
- `RivetKit could not load a core runtime. Native runtime: ${_chunkYVVFOKEPcjs.stringifyError.call(void 0, nativeError)} Wasm runtime: ${_chunkYVVFOKEPcjs.stringifyError.call(void 0, wasmError)}`,
3445
+ `RivetKit could not load a core runtime. Native runtime: ${_chunkWMRE434Qcjs.stringifyError.call(void 0, nativeError)} Wasm runtime: ${_chunkWMRE434Qcjs.stringifyError.call(void 0, wasmError)}`,
3491
3446
  {
3492
3447
  public: true,
3493
3448
  statusCode: 500
@@ -3676,37 +3631,20 @@ async function cleanupNativeSleepRuntimeState(runtime, ctx, afterTrackedWorkDrai
3676
3631
  await closeNativeDatabaseClient(runtime, ctx);
3677
3632
  await closeNativeSqlDatabase(runtime, ctx);
3678
3633
  void runtime.actorWaitForTrackedShutdownWorkUnbounded(ctx).then(async () => {
3679
- try {
3680
- await (afterTrackedWorkDrained == null ? void 0 : afterTrackedWorkDrained());
3681
- } finally {
3682
- clearNativeRuntimeState(runtime, ctx);
3683
- }
3634
+ await (afterTrackedWorkDrained == null ? void 0 : afterTrackedWorkDrained());
3635
+ clearNativeRuntimeState(runtime, ctx);
3684
3636
  }).catch((error) => {
3685
3637
  logger2().warn({
3686
3638
  msg: "deferred native sleep cleanup failed",
3687
- error: _chunkYVVFOKEPcjs.stringifyError.call(void 0, error)
3639
+ error: _chunkWMRE434Qcjs.stringifyError.call(void 0, error)
3688
3640
  });
3689
3641
  });
3690
3642
  return;
3691
3643
  }
3692
- try {
3693
- await (afterTrackedWorkDrained == null ? void 0 : afterTrackedWorkDrained());
3694
- } finally {
3695
- try {
3696
- await closeNativeDatabaseClient(runtime, ctx);
3697
- await closeNativeSqlDatabase(runtime, ctx);
3698
- } finally {
3699
- clearNativeRuntimeState(runtime, ctx);
3700
- }
3701
- }
3702
- }
3703
- async function cleanupNativeLostRuntimeState(runtime, ctx) {
3644
+ await (afterTrackedWorkDrained == null ? void 0 : afterTrackedWorkDrained());
3704
3645
  await closeNativeDatabaseClient(runtime, ctx);
3705
- try {
3706
- await closeNativeSqlDatabase(runtime, ctx);
3707
- } finally {
3708
- clearNativeRuntimeState(runtime, ctx);
3709
- }
3646
+ await closeNativeSqlDatabase(runtime, ctx);
3647
+ clearNativeRuntimeState(runtime, ctx);
3710
3648
  }
3711
3649
  function closeNativeSqlDatabase(runtime, ctx) {
3712
3650
  const runtimeState = getNativeRuntimeState(runtime, ctx);
@@ -3724,9 +3662,6 @@ async function closeNativeDatabaseClient(runtime, ctx) {
3724
3662
  return;
3725
3663
  }
3726
3664
  runtimeState.databaseClient = void 0;
3727
- if (callNativeSync(() => runtime.actorIsLost(ctx))) {
3728
- return;
3729
- }
3730
3665
  if (entry.client && typeof entry.client === "object" && "close" in entry.client && typeof entry.client.close === "function") {
3731
3666
  await entry.client.close();
3732
3667
  }
@@ -3864,10 +3799,10 @@ function decodeValue(value) {
3864
3799
  if (!value || value.length === 0) {
3865
3800
  return void 0;
3866
3801
  }
3867
- return _chunkYVVFOKEPcjs.decodeCborCompat.call(void 0, value);
3802
+ return _chunkWMRE434Qcjs.decodeCborCompat.call(void 0, value);
3868
3803
  }
3869
3804
  function encodeValue(value) {
3870
- return _chunkYVVFOKEPcjs.encodeCborCompat.call(void 0, value);
3805
+ return _chunkWMRE434Qcjs.encodeCborCompat.call(void 0, value);
3871
3806
  }
3872
3807
  function normalizeArgs(value) {
3873
3808
  return Array.isArray(value) ? value : value === void 0 || value === null ? [] : [value];
@@ -3903,7 +3838,7 @@ function isStructuredBridgeError(error) {
3903
3838
  return _chunkMGI2VVF6cjs.isRivetErrorLike.call(void 0, error) && "__type" in error && (error.__type === "RivetError" || error.__type === "ActorError");
3904
3839
  }
3905
3840
  function encodeNativeCallbackError(error) {
3906
- const structuredError = isStructuredBridgeError(error) ? error : _chunkYVVFOKEPcjs.deconstructError.call(void 0, error, true);
3841
+ const structuredError = isStructuredBridgeError(error) ? error : _chunkWMRE434Qcjs.deconstructError.call(void 0, error, true);
3907
3842
  const { encoded, droppedMetadataCause } = _chunkMGI2VVF6cjs.encodeBridgeRivetError.call(void 0, structuredError);
3908
3843
  if (droppedMetadataCause !== void 0) {
3909
3844
  logger2().warn(
@@ -3965,7 +3900,7 @@ function decodeWorkflowCbor(data) {
3965
3900
  return null;
3966
3901
  }
3967
3902
  try {
3968
- return _chunkYVVFOKEPcjs.decodeCborCompat.call(void 0, new Uint8Array(data));
3903
+ return _chunkWMRE434Qcjs.decodeCborCompat.call(void 0, new Uint8Array(data));
3969
3904
  } catch (e3) {
3970
3905
  return null;
3971
3906
  }
@@ -4078,7 +4013,7 @@ function serializeWorkflowHistoryForJson(data) {
4078
4013
  if (data === null) {
4079
4014
  return null;
4080
4015
  }
4081
- const history = _chunkERBNWARBcjs.decodeWorkflowHistoryTransport.call(void 0, data);
4016
+ const history = _chunkRIZ57PM3cjs.decodeWorkflowHistoryTransport.call(void 0, data);
4082
4017
  return jsonSafe({
4083
4018
  nameRegistry: [...history.nameRegistry],
4084
4019
  entries: history.entries.map((entry) => ({
@@ -4152,49 +4087,6 @@ function wrapNativeCallback(callback) {
4152
4087
  }
4153
4088
  };
4154
4089
  }
4155
- var LOST_GENERATION_CLEANUP_CALLBACKS = /* @__PURE__ */ new Set(["onSleep", "onDestroy"]);
4156
- function throwIfActorLost(runtime, ctx) {
4157
- if (callNativeSync(() => runtime.actorIsLost(ctx))) {
4158
- throw actorGenerationLostError();
4159
- }
4160
- }
4161
- function actorGenerationLostError() {
4162
- return new (0, _chunkMGI2VVF6cjs.RivetError)(
4163
- "actor",
4164
- "stopping",
4165
- "Actor generation was declared lost; it starts no new user callbacks."
4166
- );
4167
- }
4168
- function refuseCallbacksAfterLost(runtime, callbacks) {
4169
- const guard = (callback) => {
4170
- return async (...args) => {
4171
- var _a;
4172
- const ctx = (_a = args[1]) == null ? void 0 : _a.ctx;
4173
- if (ctx !== void 0 && callNativeSync(() => runtime.actorIsLost(ctx))) {
4174
- throw encodeNativeCallbackError(actorGenerationLostError());
4175
- }
4176
- return await callback(...args);
4177
- };
4178
- };
4179
- const guarded = {};
4180
- for (const [name, value] of Object.entries(callbacks)) {
4181
- if (LOST_GENERATION_CLEANUP_CALLBACKS.has(name)) {
4182
- guarded[name] = value;
4183
- } else if (typeof value === "function") {
4184
- guarded[name] = guard(value);
4185
- } else if (name === "actions" && value !== null && typeof value === "object") {
4186
- guarded[name] = Object.fromEntries(
4187
- Object.entries(value).map(([actionName, handler]) => [
4188
- actionName,
4189
- guard(handler)
4190
- ])
4191
- );
4192
- } else {
4193
- guarded[name] = value;
4194
- }
4195
- }
4196
- return guarded;
4197
- }
4198
4090
  function decodeArgs(value) {
4199
4091
  const decoded = decodeValue(value);
4200
4092
  return normalizeArgs(decoded);
@@ -4220,7 +4112,7 @@ var NativeConnAdapter = class {
4220
4112
  this.#ctx = ctx;
4221
4113
  this.#queueHibernationRemoval = queueHibernationRemoval;
4222
4114
  this.#assertCanMutateState = assertCanMutateState;
4223
- this[_chunkNGJWQMUUcjs.CONN_STATE_MANAGER_SYMBOL] = {
4115
+ this[_chunkNWCAIWHLcjs.CONN_STATE_MANAGER_SYMBOL] = {
4224
4116
  stateEnabled: true,
4225
4117
  get state() {
4226
4118
  return thisConn.state;
@@ -4237,7 +4129,7 @@ var NativeConnAdapter = class {
4237
4129
  decodeValue(this.#runtime.connParams(this.#conn))
4238
4130
  );
4239
4131
  }
4240
- [_chunkNGJWQMUUcjs.RAW_STATE_SYMBOL]() {
4132
+ [_chunkNWCAIWHLcjs.RAW_STATE_SYMBOL]() {
4241
4133
  return this.#readState();
4242
4134
  }
4243
4135
  get state() {
@@ -4267,7 +4159,7 @@ var NativeConnAdapter = class {
4267
4159
  },
4268
4160
  (newValue) => {
4269
4161
  assertCurrentState();
4270
- _chunkYVVFOKEPcjs.assertJsonCompatValue.call(void 0, newValue);
4162
+ _chunkWMRE434Qcjs.assertJsonCompatValue.call(void 0, newValue);
4271
4163
  }
4272
4164
  );
4273
4165
  }
@@ -4275,7 +4167,7 @@ var NativeConnAdapter = class {
4275
4167
  var _a;
4276
4168
  (_a = this.#assertCanMutateState) == null ? void 0 : _a.call(this);
4277
4169
  const nextValue = unwrapWriteThroughProxy(value);
4278
- _chunkYVVFOKEPcjs.assertJsonCompatValue.call(void 0, nextValue);
4170
+ _chunkWMRE434Qcjs.assertJsonCompatValue.call(void 0, nextValue);
4279
4171
  this.#writeState(nextValue, { writeNative: true });
4280
4172
  }
4281
4173
  initializeState(value) {
@@ -4632,30 +4524,17 @@ var NativeQueueAdapter = class {
4632
4524
  this.#ctx = ctx;
4633
4525
  this.#schemas = schemas;
4634
4526
  }
4635
- // Queue results arrive after awaits, and their schema validation is user code, so each
4636
- // validation checks that the generation was not lost first.
4637
- #validateBody(name, body) {
4638
- throwIfActorLost(this.#runtime, this.#ctx);
4639
- return validateQueueBody(this.#schemas, name, body);
4640
- }
4641
- #validateComplete(name, response) {
4642
- throwIfActorLost(this.#runtime, this.#ctx);
4643
- return validateQueueComplete(this.#schemas, name, response);
4644
- }
4645
- #wrap(message) {
4646
- throwIfActorLost(this.#runtime, this.#ctx);
4647
- return wrapQueueMessage(message, this.#schemas);
4648
- }
4649
4527
  async send(name, body) {
4650
- const validatedBody = this.#validateBody(name, body);
4651
- return this.#wrap(
4528
+ const validatedBody = validateQueueBody(this.#schemas, name, body);
4529
+ return wrapQueueMessage(
4652
4530
  await callNative(
4653
4531
  () => this.#runtime.actorQueueSend(
4654
4532
  this.#ctx,
4655
4533
  name,
4656
4534
  encodeValue(validatedBody)
4657
4535
  )
4658
- )
4536
+ ),
4537
+ this.#schemas
4659
4538
  );
4660
4539
  }
4661
4540
  async next(options) {
@@ -4698,7 +4577,9 @@ var NativeQueueAdapter = class {
4698
4577
  token
4699
4578
  )
4700
4579
  );
4701
- const wrapped = messages.map((message) => this.#wrap(message));
4580
+ const wrapped = messages.map(
4581
+ (message) => wrapQueueMessage(message, this.#schemas)
4582
+ );
4702
4583
  return completable ? wrapped.map(
4703
4584
  (message) => this.#makeCompletableMessage(message)
4704
4585
  ) : wrapped;
@@ -4712,7 +4593,7 @@ var NativeQueueAdapter = class {
4712
4593
  options == null ? void 0 : options.signal
4713
4594
  );
4714
4595
  try {
4715
- return this.#wrap(
4596
+ return wrapQueueMessage(
4716
4597
  await callNative(
4717
4598
  () => this.#runtime.actorQueueWaitForNames(
4718
4599
  this.#ctx,
@@ -4723,7 +4604,8 @@ var NativeQueueAdapter = class {
4723
4604
  },
4724
4605
  token
4725
4606
  )
4726
- )
4607
+ ),
4608
+ this.#schemas
4727
4609
  );
4728
4610
  } finally {
4729
4611
  cleanup == null ? void 0 : cleanup();
@@ -4753,7 +4635,8 @@ var NativeQueueAdapter = class {
4753
4635
  await this.waitForNamesAvailable(_nullishCoalesce(names, () => ( [])), options);
4754
4636
  }
4755
4637
  async complete(message, response) {
4756
- const validatedResponse = this.#validateComplete(
4638
+ const validatedResponse = validateQueueComplete(
4639
+ this.#schemas,
4757
4640
  message.name,
4758
4641
  response
4759
4642
  );
@@ -4768,7 +4651,7 @@ var NativeQueueAdapter = class {
4768
4651
  this.#pendingCompletableMessageIds.delete(message.id.toString());
4769
4652
  }
4770
4653
  async enqueueAndWait(name, body, options) {
4771
- const validatedBody = this.#validateBody(name, body);
4654
+ const validatedBody = validateQueueBody(this.#schemas, name, body);
4772
4655
  const { token, cleanup } = await createCancellationTokenHandle(
4773
4656
  this.#runtime,
4774
4657
  options == null ? void 0 : options.signal
@@ -4785,7 +4668,11 @@ var NativeQueueAdapter = class {
4785
4668
  token
4786
4669
  )
4787
4670
  );
4788
- return response === void 0 || response === null ? void 0 : this.#validateComplete(name, decodeValue(response));
4671
+ return response === void 0 || response === null ? void 0 : validateQueueComplete(
4672
+ this.#schemas,
4673
+ name,
4674
+ decodeValue(response)
4675
+ );
4789
4676
  } finally {
4790
4677
  cleanup == null ? void 0 : cleanup();
4791
4678
  }
@@ -5166,9 +5053,6 @@ var TrackedWebSocketHandleAdapter = class {
5166
5053
  }
5167
5054
  }
5168
5055
  #callHandler(type, handler, event2) {
5169
- if ((type === "message" || type === "open") && this.#ctx.isLost) {
5170
- return;
5171
- }
5172
5056
  try {
5173
5057
  const result = handler(event2);
5174
5058
  if (!this.#isPromiseLike(result)) {
@@ -5302,7 +5186,7 @@ var ActorContextHandleAdapter = class {
5302
5186
  this.#databaseProvider = databaseProvider;
5303
5187
  }
5304
5188
  this.#request = request;
5305
- this[_chunkNGJWQMUUcjs.ACTOR_CONTEXT_INTERNAL_SYMBOL] = new NativeWorkflowRuntimeAdapter(
5189
+ this[_chunkNWCAIWHLcjs.ACTOR_CONTEXT_INTERNAL_SYMBOL] = new NativeWorkflowRuntimeAdapter(
5306
5190
  this,
5307
5191
  () => this.#logByInvocationScope.delete(
5308
5192
  _nullishCoalesce(this.#runtime.currentInvocationScope(), () => ( NO_INVOCATION_SCOPE))
@@ -5335,7 +5219,7 @@ var ActorContextHandleAdapter = class {
5335
5219
  }
5336
5220
  throw databaseClientNotReadyError();
5337
5221
  }
5338
- [_chunkNGJWQMUUcjs.RAW_STATE_SYMBOL]() {
5222
+ [_chunkNWCAIWHLcjs.RAW_STATE_SYMBOL]() {
5339
5223
  if (!this.#stateEnabled) {
5340
5224
  throw stateNotEnabledError();
5341
5225
  }
@@ -5362,7 +5246,7 @@ var ActorContextHandleAdapter = class {
5362
5246
  },
5363
5247
  (newValue) => {
5364
5248
  assertCurrentState();
5365
- _chunkYVVFOKEPcjs.assertJsonCompatValue.call(void 0, newValue);
5249
+ _chunkWMRE434Qcjs.assertJsonCompatValue.call(void 0, newValue);
5366
5250
  }
5367
5251
  );
5368
5252
  }
@@ -5374,7 +5258,7 @@ var ActorContextHandleAdapter = class {
5374
5258
  }
5375
5259
  this.#assertCanMutateState();
5376
5260
  const nextValue = unwrapWriteThroughProxy(value);
5377
- _chunkYVVFOKEPcjs.assertJsonCompatValue.call(void 0, nextValue);
5261
+ _chunkWMRE434Qcjs.assertJsonCompatValue.call(void 0, nextValue);
5378
5262
  this.#writeState(nextValue, { scheduleSave: true });
5379
5263
  }
5380
5264
  initializeState(value) {
@@ -5451,13 +5335,6 @@ var ActorContextHandleAdapter = class {
5451
5335
  get actorId() {
5452
5336
  return callNativeSync(() => this.#runtime.actorId(this.#ctx));
5453
5337
  }
5454
- get actorGeneration() {
5455
- return callNativeSync(() => this.#runtime.actorGeneration(this.#ctx));
5456
- }
5457
- /** Whether this generation was declared lost. A lost generation starts no new user code. */
5458
- get isLost() {
5459
- return callNativeSync(() => this.#runtime.actorIsLost(this.#ctx));
5460
- }
5461
5338
  get name() {
5462
5339
  return callNativeSync(() => this.#runtime.actorName(this.#ctx));
5463
5340
  }
@@ -5572,9 +5449,6 @@ var ActorContextHandleAdapter = class {
5572
5449
  return this.#db;
5573
5450
  }
5574
5451
  const actorId = this.actorId;
5575
- if (this.isLost) {
5576
- throw actorGenerationLostError();
5577
- }
5578
5452
  const createdClient = await this.#databaseProvider.createClient({
5579
5453
  actorId,
5580
5454
  kv: {
@@ -5596,7 +5470,7 @@ var ActorContextHandleAdapter = class {
5596
5470
  log: {
5597
5471
  debug: (obj) => logger2().debug(obj)
5598
5472
  },
5599
- nativeDatabaseProvider: _chunkCE6NBGOLcjs.registerNativeStateTransactionOpener.call(void 0,
5473
+ nativeDatabaseProvider: _chunkFTHC2AMBcjs.registerNativeStateTransactionOpener.call(void 0,
5600
5474
  {
5601
5475
  open: async (requestedActorId) => {
5602
5476
  void requestedActorId;
@@ -5619,7 +5493,7 @@ var ActorContextHandleAdapter = class {
5619
5493
  return this.#db;
5620
5494
  }
5621
5495
  #bindDatabaseClient(client) {
5622
- return _chunkCE6NBGOLcjs.bindNativeStateTransactionContext.call(void 0, client, {
5496
+ return _chunkFTHC2AMBcjs.bindNativeStateTransactionContext.call(void 0, client, {
5623
5497
  enter: async () => await this.#enterStateTransaction(),
5624
5498
  exit: (scope) => this.#exitStateTransaction(
5625
5499
  scope
@@ -5727,11 +5601,9 @@ var ActorContextHandleAdapter = class {
5727
5601
  if (!this.#databaseProvider) {
5728
5602
  return;
5729
5603
  }
5730
- const client = await this.ensureDatabaseClient();
5731
- if (this.isLost) {
5732
- throw actorGenerationLostError();
5733
- }
5734
- await this.#databaseProvider.onMigrate(client);
5604
+ await this.#databaseProvider.onMigrate(
5605
+ await this.ensureDatabaseClient()
5606
+ );
5735
5607
  }
5736
5608
  async closeDatabase() {
5737
5609
  this.#db = void 0;
@@ -5825,7 +5697,7 @@ var ActorContextHandleAdapter = class {
5825
5697
  const trackedPromise = Promise.resolve(promise).catch((error) => {
5826
5698
  logger2().warn({
5827
5699
  msg: "keepAwake promise rejected",
5828
- error: _chunkYVVFOKEPcjs.stringifyError.call(void 0, error)
5700
+ error: _chunkWMRE434Qcjs.stringifyError.call(void 0, error)
5829
5701
  });
5830
5702
  }).then(() => null);
5831
5703
  try {
@@ -6003,7 +5875,7 @@ var ActorContextHandleAdapter = class {
6003
5875
  callNativeSync(
6004
5876
  () => this.#runtime.actorRequestSave(this.#ctx, { immediate: false })
6005
5877
  );
6006
- if (!this.#onStateChange || this.isLost) {
5878
+ if (!this.#onStateChange) {
6007
5879
  return;
6008
5880
  }
6009
5881
  actorState.isInOnStateChange = true;
@@ -6043,12 +5915,6 @@ var NativeWorkflowRuntimeAdapter = class {
6043
5915
  #onMessagesReceived;
6044
5916
  #completions = /* @__PURE__ */ new Map();
6045
5917
 
6046
- /** Actor generation, used to keep workflow registrations of different generations apart. */
6047
-
6048
- /** Whether this generation was declared lost. Workflow code checks it before each user callback. */
6049
- get isLost() {
6050
- return this.#ctx.isLost;
6051
- }
6052
5918
 
6053
5919
 
6054
5920
 
@@ -6056,7 +5922,6 @@ var NativeWorkflowRuntimeAdapter = class {
6056
5922
  this.#ctx = ctx;
6057
5923
  this.#onMessagesReceived = onMessagesReceived;
6058
5924
  this.id = ctx.actorId;
6059
- this.generation = ctx.actorGeneration;
6060
5925
  this.driver = {
6061
5926
  kvBatchGet: async (actorId, keys) => {
6062
5927
  this.#assertActorId(actorId);
@@ -6192,7 +6057,7 @@ function buildActorTracingConfig(actions, tracing) {
6192
6057
  if (tracing === void 0) return void 0;
6193
6058
  return {
6194
6059
  sampler: tracing.sampler,
6195
- actions: _chunkNGJWQMUUcjs.flattenActionTraceSamplers.call(void 0, actions, tracing.actions)
6060
+ actions: _chunkNWCAIWHLcjs.flattenActionTraceSamplers.call(void 0, actions, tracing.actions)
6196
6061
  };
6197
6062
  }
6198
6063
  function buildActorConfig(definition, registryConfig, runtimeKind) {
@@ -6234,7 +6099,7 @@ function buildActorConfig(definition, registryConfig, runtimeKind) {
6234
6099
  maxOutgoingMessageSize: registryConfig.maxOutgoingMessageSize,
6235
6100
  preloadMaxWorkflowBytes: options.preloadMaxWorkflowBytes,
6236
6101
  preloadMaxConnectionsBytes: options.preloadMaxConnectionsBytes,
6237
- actions: Object.keys(_chunkNGJWQMUUcjs.flattenActionHandlers.call(void 0, config.actions)).sort().map((name) => ({ name })),
6102
+ actions: Object.keys(_chunkNWCAIWHLcjs.flattenActionHandlers.call(void 0, config.actions)).sort().map((name) => ({ name })),
6238
6103
  inspectorTabs: buildInspectorTabs(config.inspector, runtimeKind)
6239
6104
  };
6240
6105
  }
@@ -6310,10 +6175,10 @@ function validateInspectorTabSource(tabId, resolved) {
6310
6175
  function buildNativeFactory(runtime, registryConfig, definition) {
6311
6176
  var _a;
6312
6177
  const config = definition.config;
6313
- const databaseProvider = _nullishCoalesce(config.db, () => ( _chunkCE6NBGOLcjs.db.call(void 0, )));
6314
- const actionHandlers = _chunkNGJWQMUUcjs.flattenActionHandlers.call(void 0, config.actions);
6178
+ const databaseProvider = _nullishCoalesce(config.db, () => ( _chunkFTHC2AMBcjs.db.call(void 0, )));
6179
+ const actionHandlers = _chunkNWCAIWHLcjs.flattenActionHandlers.call(void 0, config.actions);
6315
6180
  const schemaConfig = {
6316
- actionInputSchemas: _chunkNGJWQMUUcjs.flattenActionInputSchemas.call(void 0,
6181
+ actionInputSchemas: _chunkNWCAIWHLcjs.flattenActionInputSchemas.call(void 0,
6317
6182
  config.actions,
6318
6183
  config.actionInputSchemas
6319
6184
  ),
@@ -6321,9 +6186,9 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6321
6186
  events: config.events,
6322
6187
  queues: config.queues
6323
6188
  };
6324
- const createClient = (ctx) => _chunkR3UI7MO3cjs.createClientWithDriver.call(void 0,
6325
- new (0, _chunkR3UI7MO3cjs.RemoteEngineControlClient)(
6326
- _chunkR3UI7MO3cjs.convertRegistryConfigToClientConfig.call(void 0, registryConfig)
6189
+ const createClient = (ctx) => _chunk4C2R5ZGVcjs.createClientWithDriver.call(void 0,
6190
+ new (0, _chunk4C2R5ZGVcjs.RemoteEngineControlClient)(
6191
+ _chunk4C2R5ZGVcjs.convertRegistryConfigToClientConfig.call(void 0, registryConfig)
6327
6192
  ),
6328
6193
  {
6329
6194
  encoding: "bare",
@@ -6335,27 +6200,13 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6335
6200
  )
6336
6201
  }
6337
6202
  );
6338
- const run = _chunkNGJWQMUUcjs.getRunFunction.call(void 0, config.run);
6339
- const runHandlerCoordinator = _chunkNGJWQMUUcjs.getRunInspectorKind.call(void 0, config.run) === "workflow" ? new RunHandlerCoordinator(config.run) : void 0;
6203
+ const run = _chunkNWCAIWHLcjs.getRunFunction.call(void 0, config.run);
6204
+ const runHandlerCoordinator = _chunkNWCAIWHLcjs.getRunInspectorKind.call(void 0, config.run) === "workflow" ? new RunHandlerCoordinator(config.run) : void 0;
6340
6205
  const getNativeWorkflowInspector = (ctx) => {
6341
6206
  var _a2, _b;
6342
- if (callNativeSync(() => runtime.actorIsLost(ctx))) {
6343
- return void 0;
6344
- }
6345
6207
  const actorId = callNativeSync(() => runtime.actorId(ctx));
6346
6208
  const restart = () => callNativeSync(() => runtime.actorRestartRunHandler(ctx));
6347
- const actorGeneration = callNativeSync(
6348
- () => runtime.actorGeneration(ctx)
6349
- );
6350
- const inspector = _nullishCoalesce(((_a2 = runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.getInspector(
6351
- actorId,
6352
- restart,
6353
- actorGeneration
6354
- )) == null ? void 0 : _a2.workflow), () => ( ((_b = _chunkNGJWQMUUcjs.getRunInspectorConfig.call(void 0, config.run, actorId)) == null ? void 0 : _b.workflow)));
6355
- if (callNativeSync(() => runtime.actorIsLost(ctx))) {
6356
- return void 0;
6357
- }
6358
- return inspector;
6209
+ return _nullishCoalesce(((_a2 = runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.getInspector(actorId, restart)) == null ? void 0 : _a2.workflow), () => ( ((_b = _chunkNWCAIWHLcjs.getRunInspectorConfig.call(void 0, config.run, actorId)) == null ? void 0 : _b.workflow)));
6359
6210
  };
6360
6211
  const onStateChange = typeof config.onStateChange === "function" ? (actorCtx, nextState) => {
6361
6212
  config.onStateChange(actorCtx, nextState);
@@ -6432,10 +6283,6 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6432
6283
  return errorResponse(error, 401);
6433
6284
  }
6434
6285
  }
6435
- const inspectorConnParams = (conn) => {
6436
- throwIfActorLost(runtime, ctx);
6437
- return conn.params;
6438
- };
6439
6286
  const workflowHistory = () => {
6440
6287
  var _a3;
6441
6288
  return serializeWorkflowHistoryForJson(
@@ -6469,7 +6316,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6469
6316
  id: conn.id,
6470
6317
  details: {
6471
6318
  type: null,
6472
- params: inspectorConnParams(conn),
6319
+ params: conn.params,
6473
6320
  stateEnabled: true,
6474
6321
  state: conn.state,
6475
6322
  subscriptions: 0,
@@ -6533,7 +6380,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6533
6380
  400
6534
6381
  );
6535
6382
  }
6536
- const cbor = _chunkYVVFOKEPcjs.encodeCborCompat.call(void 0,
6383
+ const cbor = _chunkWMRE434Qcjs.encodeCborCompat.call(void 0,
6537
6384
  _nullishCoalesce(body.body, () => ( null))
6538
6385
  );
6539
6386
  const message = await runtime.actorQueueSend(ctx, name, cbor);
@@ -6673,7 +6520,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6673
6520
  id: conn.id,
6674
6521
  details: {
6675
6522
  type: null,
6676
- params: inspectorConnParams(conn),
6523
+ params: conn.params,
6677
6524
  stateEnabled: true,
6678
6525
  state: conn.state,
6679
6526
  subscriptions: 0,
@@ -6720,20 +6567,15 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6720
6567
  );
6721
6568
  }
6722
6569
  const args = body.properties !== void 0 ? [body.properties] : normalizeArgs(body.args);
6723
- if (callNativeSync(() => runtime.actorIsLost(ctx))) {
6724
- return jsonResponse(
6725
- { error: "actor generation was declared lost" },
6726
- { status: 503 }
6727
- );
6728
- }
6729
6570
  try {
6730
- const validatedArgs = validateActionArgs(
6731
- schemaConfig.actionInputSchemas,
6732
- actionName,
6733
- args
6571
+ const output = await action(
6572
+ actorCtx,
6573
+ ...validateActionArgs(
6574
+ schemaConfig.actionInputSchemas,
6575
+ actionName,
6576
+ args
6577
+ )
6734
6578
  );
6735
- throwIfActorLost(runtime, ctx);
6736
- const output = await action(actorCtx, ...validatedArgs);
6737
6579
  return jsonResponse({ output });
6738
6580
  } catch (error) {
6739
6581
  logger2().error({
@@ -6837,9 +6679,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6837
6679
  await actorCtx.closeDatabase();
6838
6680
  }
6839
6681
  await actorCtx.runDatabaseMigrations();
6840
- if (typeof config.onMigrate === "function" && !callNativeSync(
6841
- () => runtime.actorIsLost(ctx)
6842
- )) {
6682
+ if (typeof config.onMigrate === "function") {
6843
6683
  await config.onMigrate(actorCtx, isNew);
6844
6684
  }
6845
6685
  } catch (error2) {
@@ -6882,29 +6722,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6882
6722
  const { ctx } = unwrapTsfnPayload(error, payload);
6883
6723
  const actorCtx = makeActorCtx(ctx);
6884
6724
  const actorId = callNativeSync(() => runtime.actorId(ctx));
6885
- const actorGeneration = callNativeSync(
6886
- () => runtime.actorGeneration(ctx)
6887
- );
6888
- const isLost = () => callNativeSync(() => runtime.actorIsLost(ctx));
6889
- if (isLost()) {
6890
- try {
6891
- await cleanupNativeLostRuntimeState(runtime, ctx);
6892
- } finally {
6893
- runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.destroy(
6894
- actorId,
6895
- actorGeneration,
6896
- {
6897
- disposeInspector: false
6898
- }
6899
- );
6900
- await actorCtx.dispose();
6901
- }
6902
- return;
6903
- }
6904
6725
  const saveActorState = async () => {
6905
- if (isLost()) {
6906
- return;
6907
- }
6908
6726
  if (runtime.kind === "wasm") {
6909
6727
  await runtime.actorSaveState(
6910
6728
  ctx,
@@ -6923,26 +6741,14 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6923
6741
  await saveActorState();
6924
6742
  } finally {
6925
6743
  try {
6926
- if (isLost()) {
6927
- await cleanupNativeLostRuntimeState(runtime, ctx);
6928
- } else {
6929
- await cleanupNativeSleepRuntimeState(
6930
- runtime,
6931
- ctx,
6932
- saveActorState
6933
- );
6934
- }
6935
- } finally {
6936
- runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.destroy(
6937
- actorId,
6938
- actorGeneration,
6939
- {
6940
- disposeInspector: !isLost()
6941
- }
6744
+ await cleanupNativeSleepRuntimeState(
6745
+ runtime,
6746
+ ctx,
6747
+ saveActorState
6942
6748
  );
6943
- if (!isLost()) {
6944
- _chunkNGJWQMUUcjs.disposeRunInspector.call(void 0, config.run, actorId);
6945
- }
6749
+ } finally {
6750
+ runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.destroy(actorId);
6751
+ _chunkNWCAIWHLcjs.disposeRunInspector.call(void 0, config.run, actorId);
6946
6752
  await actorCtx.dispose();
6947
6753
  }
6948
6754
  }
@@ -6953,17 +6759,10 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6953
6759
  const { ctx } = unwrapTsfnPayload(error, payload);
6954
6760
  const actorCtx = makeActorCtx(ctx);
6955
6761
  const actorId = callNativeSync(() => runtime.actorId(ctx));
6956
- const isLost = () => callNativeSync(() => runtime.actorIsLost(ctx));
6957
- runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.destroy(
6958
- actorId,
6959
- callNativeSync(() => runtime.actorGeneration(ctx)),
6960
- { disposeInspector: !isLost() }
6961
- );
6962
- if (!isLost()) {
6963
- _chunkNGJWQMUUcjs.disposeRunInspector.call(void 0, config.run, actorId);
6964
- }
6762
+ runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.destroy(actorId);
6763
+ _chunkNWCAIWHLcjs.disposeRunInspector.call(void 0, config.run, actorId);
6965
6764
  try {
6966
- if (typeof config.onDestroy === "function" && !isLost()) {
6765
+ if (typeof config.onDestroy === "function") {
6967
6766
  await config.onDestroy(actorCtx);
6968
6767
  }
6969
6768
  } finally {
@@ -6985,14 +6784,12 @@ function buildNativeFactory(runtime, registryConfig, definition) {
6985
6784
  request ? buildNativeHttpRequest(request) : void 0
6986
6785
  );
6987
6786
  try {
6988
- const validatedParams = validateConnParams(
6989
- schemaConfig.connParamsSchema,
6990
- decodeValue(params)
6991
- );
6992
- throwIfActorLost(runtime, ctx);
6993
6787
  await config.onBeforeConnect(
6994
6788
  actorCtx,
6995
- validatedParams
6789
+ validateConnParams(
6790
+ schemaConfig.connParamsSchema,
6791
+ decodeValue(params)
6792
+ )
6996
6793
  );
6997
6794
  } finally {
6998
6795
  await actorCtx.dispose();
@@ -7020,22 +6817,13 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7020
6817
  () => actorCtx.assertCanMutateState()
7021
6818
  );
7022
6819
  try {
7023
- let nextConnState;
7024
- if (hasStaticConnState) {
7025
- nextConnState = structuredClone(
7026
- config.connState
7027
- );
7028
- } else {
7029
- const validatedParams = validateConnParams(
6820
+ const nextConnState = hasStaticConnState ? structuredClone(config.connState) : await config.createConnState(
6821
+ actorCtx,
6822
+ validateConnParams(
7030
6823
  schemaConfig.connParamsSchema,
7031
6824
  decodeValue(params)
7032
- );
7033
- throwIfActorLost(runtime, ctx);
7034
- nextConnState = await config.createConnState(
7035
- actorCtx,
7036
- validatedParams
7037
- );
7038
- }
6825
+ )
6826
+ );
7039
6827
  connAdapter.initializeState(nextConnState);
7040
6828
  return encodeValue(nextConnState);
7041
6829
  } finally {
@@ -7140,9 +6928,6 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7140
6928
  onBeforeActionResponse: typeof config.onBeforeActionResponse === "function" ? wrapNativeCallback(
7141
6929
  async (error, payload) => {
7142
6930
  const { ctx, name, args, output } = unwrapTsfnPayload(error, payload);
7143
- if (callNativeSync(() => runtime.actorIsLost(ctx))) {
7144
- return output;
7145
- }
7146
6931
  const actorCtx = makeActorCtx(ctx);
7147
6932
  try {
7148
6933
  return encodeValue(
@@ -7192,7 +6977,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7192
6977
  ...request,
7193
6978
  abortController: requestAbortController
7194
6979
  });
7195
- const rawConnParams = handlerRequest.headers.get(_chunkR3UI7MO3cjs.HEADER_CONN_PARAMS);
6980
+ const rawConnParams = handlerRequest.headers.get(_chunk4C2R5ZGVcjs.HEADER_CONN_PARAMS);
7196
6981
  let requestCtx;
7197
6982
  let conn;
7198
6983
  let removeRequestAbortListener;
@@ -7211,7 +6996,6 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7211
6996
  }
7212
6997
  };
7213
6998
  try {
7214
- throwIfActorLost(runtime, ctx);
7215
6999
  const connParams = validateConnParams(
7216
7000
  schemaConfig.connParamsSchema,
7217
7001
  rawConnParams ? JSON.parse(rawConnParams) : void 0
@@ -7246,16 +7030,11 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7246
7030
  abortRequest
7247
7031
  );
7248
7032
  }
7249
- if (callNativeSync(
7250
- () => runtime.actorIsLost(ctx)
7251
- )) {
7252
- throw actorGenerationLostError();
7253
- }
7254
7033
  const response = await config.onRequest(
7255
7034
  requestCtx,
7256
7035
  handlerRequest
7257
7036
  );
7258
- if (!_chunkR3UI7MO3cjs.isResponseLike.call(void 0, response)) {
7037
+ if (!_chunk4C2R5ZGVcjs.isResponseLike.call(void 0, response)) {
7259
7038
  throw new Error(
7260
7039
  "onRequest handler must return a Response"
7261
7040
  );
@@ -7323,9 +7102,6 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7323
7102
  const { ctx } = unwrapTsfnPayload(error, payload);
7324
7103
  const actorId = callNativeSync(() => runtime.actorId(ctx));
7325
7104
  const executeRun = async () => {
7326
- if (callNativeSync(() => runtime.actorIsLost(ctx))) {
7327
- return;
7328
- }
7329
7105
  const actorCtx = makeActorCtx(ctx);
7330
7106
  try {
7331
7107
  await run(actorCtx);
@@ -7339,8 +7115,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7339
7115
  () => callNativeSync(
7340
7116
  () => runtime.actorRestartRunHandler(ctx)
7341
7117
  ),
7342
- executeRun,
7343
- callNativeSync(() => runtime.actorGeneration(ctx))
7118
+ executeRun
7344
7119
  );
7345
7120
  return outcome !== "suppressed";
7346
7121
  }
@@ -7349,15 +7124,15 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7349
7124
  }
7350
7125
  );
7351
7126
  })(),
7352
- getWorkflowHistory: _chunkNGJWQMUUcjs.hasRunInspectorConfig.call(void 0, config.run) ? wrapNativeCallback(
7127
+ getWorkflowHistory: _chunkNWCAIWHLcjs.hasRunInspectorConfig.call(void 0, config.run) ? wrapNativeCallback(
7353
7128
  async (error, payload) => {
7354
7129
  var _a2;
7355
7130
  const { ctx } = unwrapTsfnPayload(error, payload);
7356
7131
  const history = (_a2 = getNativeWorkflowInspector(ctx)) == null ? void 0 : _a2.getHistory();
7357
- return history == null ? void 0 : _chunkYVVFOKEPcjs.toUint8Array.call(void 0, history);
7132
+ return history == null ? void 0 : _chunkWMRE434Qcjs.toUint8Array.call(void 0, history);
7358
7133
  }
7359
7134
  ) : void 0,
7360
- replayWorkflow: _chunkNGJWQMUUcjs.hasRunInspectorConfig.call(void 0, config.run) ? wrapNativeCallback(
7135
+ replayWorkflow: _chunkNWCAIWHLcjs.hasRunInspectorConfig.call(void 0, config.run) ? wrapNativeCallback(
7361
7136
  async (error, payload) => {
7362
7137
  const { ctx, entryId } = unwrapTsfnPayload(
7363
7138
  error,
@@ -7368,7 +7143,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7368
7143
  return void 0;
7369
7144
  }
7370
7145
  const history = await _asyncNullishCoalesce(await workflowInspector.replayFromStep(entryId), async () => ( null));
7371
- return history == null ? void 0 : _chunkYVVFOKEPcjs.toUint8Array.call(void 0, history);
7146
+ return history == null ? void 0 : _chunkWMRE434Qcjs.toUint8Array.call(void 0, history);
7372
7147
  }
7373
7148
  ) : void 0,
7374
7149
  actions: Object.fromEntries(
@@ -7380,16 +7155,14 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7380
7155
  const actorCtx = conn != null ? makeConnCtx(ctx, conn, void 0, cancelToken) : makeActorCtx(ctx, void 0, cancelToken);
7381
7156
  const runAction = async () => {
7382
7157
  try {
7383
- const validatedArgs = validateActionArgs(
7384
- schemaConfig.actionInputSchemas,
7385
- name,
7386
- decodeArgs(args)
7387
- );
7388
- throwIfActorLost(runtime, ctx);
7389
7158
  return encodeValue(
7390
7159
  await handler(
7391
7160
  actorCtx,
7392
- ...validatedArgs,
7161
+ ...validateActionArgs(
7162
+ schemaConfig.actionInputSchemas,
7163
+ name,
7164
+ decodeArgs(args)
7165
+ ),
7393
7166
  ...scheduledFire ? [scheduledFire] : []
7394
7167
  )
7395
7168
  );
@@ -7445,7 +7218,6 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7445
7218
  if (canPublish && !await canPublish(actorCtx)) {
7446
7219
  throw _chunkMGI2VVF6cjs.forbiddenError.call(void 0, );
7447
7220
  }
7448
- throwIfActorLost(runtime, ctx);
7449
7221
  const decodedBody = decodeValue(body);
7450
7222
  if (wait) {
7451
7223
  try {
@@ -7489,7 +7261,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
7489
7261
  )
7490
7262
  };
7491
7263
  return runtime.createActorFactory(
7492
- refuseCallbacksAfterLost(runtime, callbacks),
7264
+ callbacks,
7493
7265
  buildActorConfig(definition, registryConfig, runtime.kind)
7494
7266
  );
7495
7267
  }
@@ -7507,7 +7279,7 @@ async function buildServeConfig(config, resolveServicesBinary = true) {
7507
7279
  startServices: resolveServicesBinary && config.startServices,
7508
7280
  handleInspectorHttpInRuntime: true,
7509
7281
  serverlessBasePath: config.serverless.basePath,
7510
- serverlessPackageVersion: _chunkYVVFOKEPcjs.VERSION,
7282
+ serverlessPackageVersion: _chunkWMRE434Qcjs.VERSION,
7511
7283
  serverlessClientEndpoint: config.publicEndpoint,
7512
7284
  serverlessClientNamespace: config.publicNamespace,
7513
7285
  serverlessClientToken: config.publicToken,
@@ -7520,7 +7292,7 @@ async function buildServeConfig(config, resolveServicesBinary = true) {
7520
7292
  } catch (error) {
7521
7293
  logger2().warn({
7522
7294
  msg: "could not resolve a local engine binary; if a local engine must be spawned it will fail with engine.binary_unavailable \u2014 set RIVET_ENGINE_BINARY_PATH or install the @rivetkit/engine-cli platform package",
7523
- error: _chunkYVVFOKEPcjs.stringifyError.call(void 0, error)
7295
+ error: _chunkWMRE434Qcjs.stringifyError.call(void 0, error)
7524
7296
  });
7525
7297
  }
7526
7298
  if (resolveServicesBinary && config.startServices) {
@@ -7530,20 +7302,20 @@ async function buildServeConfig(config, resolveServicesBinary = true) {
7530
7302
  } catch (error) {
7531
7303
  logger2().warn({
7532
7304
  msg: "could not resolve the Services binary; a local engine will fail with services.binary_unavailable \u2014 set RIVET_RUN_SERVICES=0 to disable Services or RIVET_SERVICES_BINARY to a local rivet-services binary",
7533
- error: _chunkYVVFOKEPcjs.stringifyError.call(void 0, error)
7305
+ error: _chunkWMRE434Qcjs.stringifyError.call(void 0, error)
7534
7306
  });
7535
7307
  }
7536
7308
  }
7537
7309
  serveConfig.engineHost = config.engineHost;
7538
7310
  serveConfig.enginePort = config.enginePort;
7539
7311
  if ((_a = config.test) == null ? void 0 : _a.enabled) {
7540
- serveConfig.inspectorTestToken = _nullishCoalesce(_chunkYVVFOKEPcjs.getEnvUniversal.call(void 0, "_RIVET_TEST_INSPECTOR_TOKEN"), () => ( "token"));
7312
+ serveConfig.inspectorTestToken = _nullishCoalesce(_chunkWMRE434Qcjs.getEnvUniversal.call(void 0, "_RIVET_TEST_INSPECTOR_TOKEN"), () => ( "token"));
7541
7313
  }
7542
7314
  return serveConfig;
7543
7315
  }
7544
7316
  async function buildRegistryWithRuntime(config, runtime) {
7545
7317
  var _a;
7546
- if (((_a = config.test) == null ? void 0 : _a.enabled) && _chunkYVVFOKEPcjs.getEnvUniversal.call(void 0, "_RIVET_TEST_INSPECTOR_TOKEN") === void 0) {
7318
+ if (((_a = config.test) == null ? void 0 : _a.enabled) && _chunkWMRE434Qcjs.getEnvUniversal.call(void 0, "_RIVET_TEST_INSPECTOR_TOKEN") === void 0) {
7547
7319
  trySetProcessEnv("_RIVET_TEST_INSPECTOR_TOKEN", "token");
7548
7320
  }
7549
7321
  if (runtime.kind === "napi") {
@@ -7610,7 +7382,7 @@ function createApplicationFetch(application, runtime) {
7610
7382
  signal: abortController.signal
7611
7383
  })
7612
7384
  );
7613
- if (!_chunkR3UI7MO3cjs.isResponseLike.call(void 0, response)) {
7385
+ if (!_chunk4C2R5ZGVcjs.isResponseLike.call(void 0, response)) {
7614
7386
  throw new TypeError(
7615
7387
  "registry.listen() application fetch must return a Response"
7616
7388
  );
@@ -7660,7 +7432,7 @@ var Registry = class {
7660
7432
  var _a;
7661
7433
  this.#config = config;
7662
7434
  if ((_a = config.logging) == null ? void 0 : _a.baseLogger) {
7663
- _chunkYVVFOKEPcjs.configureBaseLogger.call(void 0, config.logging.baseLogger);
7435
+ _chunkWMRE434Qcjs.configureBaseLogger.call(void 0, config.logging.baseLogger);
7664
7436
  }
7665
7437
  this.#buildConfiguredRegistry = _nullishCoalesce((deps == null ? void 0 : deps.buildConfiguredRegistry), () => ( buildConfiguredRegistry));
7666
7438
  this.routes = {
@@ -7886,10 +7658,10 @@ var Registry = class {
7886
7658
  * ```
7887
7659
  */
7888
7660
  async listen(opts = {}) {
7889
- const port = _nullishCoalesce(_nullishCoalesce(opts.port, () => ( _chunkYVVFOKEPcjs.parsePortEnv.call(void 0, process.env.RIVET_PORT))), () => ( 3e3));
7890
- const publicDir = _nullishCoalesce(opts.publicDir, () => ( _chunkYVVFOKEPcjs.getRivetkitPublicDir.call(void 0, )));
7661
+ const port = _nullishCoalesce(_nullishCoalesce(opts.port, () => ( _chunkWMRE434Qcjs.parsePortEnv.call(void 0, process.env.RIVET_PORT))), () => ( 3e3));
7662
+ const publicDir = _nullishCoalesce(opts.publicDir, () => ( _chunkWMRE434Qcjs.getRivetkitPublicDir.call(void 0, )));
7891
7663
  const config = this.parseConfig();
7892
- if (opts.application && _chunkYVVFOKEPcjs.getRivetkitRuntimeMode.call(void 0, ) !== "serverless") {
7664
+ if (opts.application && _chunkWMRE434Qcjs.getRivetkitRuntimeMode.call(void 0, ) !== "serverless") {
7893
7665
  if (config.runtime === "wasm") {
7894
7666
  throw new Error(
7895
7667
  "registry.listen() requires the native runtime; use an application-owned HTTP server with WebAssembly"
@@ -7965,7 +7737,7 @@ var Registry = class {
7965
7737
  return jsonRouteResponse(503, {
7966
7738
  status: "not_started",
7967
7739
  runtime: "rivetkit",
7968
- version: _chunkYVVFOKEPcjs.VERSION
7740
+ version: _chunkWMRE434Qcjs.VERSION
7969
7741
  });
7970
7742
  }
7971
7743
  const { runtime, registry } = configured;
@@ -7973,7 +7745,7 @@ var Registry = class {
7973
7745
  return jsonRouteResponse(501, {
7974
7746
  status: "unsupported",
7975
7747
  runtime: "rivetkit",
7976
- version: _chunkYVVFOKEPcjs.VERSION
7748
+ version: _chunkWMRE434Qcjs.VERSION
7977
7749
  });
7978
7750
  }
7979
7751
  const response = await runtime.registryHealth(registry);
@@ -8047,14 +7819,14 @@ var Registry = class {
8047
7819
  var _a;
8048
7820
  if (!this.#runtimeServePromise) {
8049
7821
  const configuredEnvoyVersion = (_a = this.#config.envoy) == null ? void 0 : _a.version;
8050
- const envoyVersionSource = configuredEnvoyVersion !== void 0 ? "config" : _chunkYVVFOKEPcjs.getRivetEnvoyVersion.call(void 0, ) !== void 0 ? "environment" : "default";
7822
+ const envoyVersionSource = configuredEnvoyVersion !== void 0 ? "config" : _chunkWMRE434Qcjs.getRivetEnvoyVersion.call(void 0, ) !== void 0 ? "environment" : "default";
8051
7823
  logger2().info({
8052
7824
  msg: "starting rivetkit envoy",
8053
- rivetkitVersion: _chunkYVVFOKEPcjs.VERSION,
7825
+ rivetkitVersion: _chunkWMRE434Qcjs.VERSION,
8054
7826
  envoyVersion: config.envoy.version,
8055
7827
  envoyVersionSource
8056
7828
  });
8057
- if (envoyVersionSource === "default" && _chunkYVVFOKEPcjs.getNodeEnv.call(void 0, ) === "production") {
7829
+ if (envoyVersionSource === "default" && _chunkWMRE434Qcjs.getNodeEnv.call(void 0, ) === "production") {
8058
7830
  logger2().error({
8059
7831
  msg: "envoy version defaulted because neither config.envoy.version nor RIVET_ENVOY_VERSION is set; actors will not drain automatically across deploys. See https://rivet.dev/docs/actors/versions",
8060
7832
  envoyVersion: config.envoy.version,
@@ -8245,7 +8017,7 @@ var Registry = class {
8245
8017
  );
8246
8018
  }
8247
8019
  if (this.#runtimeReadyPromise) return this.#runtimeReadyPromise;
8248
- if (_chunkYVVFOKEPcjs.getRivetkitRuntimeMode.call(void 0, ) === "serverless") {
8020
+ if (_chunkWMRE434Qcjs.getRivetkitRuntimeMode.call(void 0, ) === "serverless") {
8249
8021
  return Promise.reject(
8250
8022
  new Error(
8251
8023
  "registry.startAndWait() requires envoy runtime mode; serverless registries become ready per request"
@@ -8315,8 +8087,8 @@ var Registry = class {
8315
8087
  * ```
8316
8088
  */
8317
8089
  start() {
8318
- if (_chunkYVVFOKEPcjs.getRivetkitRuntimeMode.call(void 0, ) === "serverless") {
8319
- const publicDir = _nullishCoalesce(_chunkYVVFOKEPcjs.getRivetkitPublicDir.call(void 0, ), () => ( "/public"));
8090
+ if (_chunkWMRE434Qcjs.getRivetkitRuntimeMode.call(void 0, ) === "serverless") {
8091
+ const publicDir = _nullishCoalesce(_chunkWMRE434Qcjs.getRivetkitPublicDir.call(void 0, ), () => ( "/public"));
8320
8092
  this.listen({ publicDir }).catch((error) => {
8321
8093
  logger2().error({ error }, "auto-listen failed; exiting");
8322
8094
  if (typeof process !== "undefined" && typeof process.exit === "function") {
@@ -8337,13 +8109,13 @@ var Registry = class {
8337
8109
  };
8338
8110
  console.log();
8339
8111
  console.log(
8340
- ` RivetKit ${_chunkYVVFOKEPcjs.VERSION} (Engine - ${kind === "serverless" ? "Serverless" : "Serverful"})`
8112
+ ` RivetKit ${_chunkWMRE434Qcjs.VERSION} (Engine - ${kind === "serverless" ? "Serverless" : "Serverful"})`
8341
8113
  );
8342
8114
  if (config.namespace !== "default") {
8343
8115
  logLine("Namespace", config.namespace);
8344
8116
  }
8345
8117
  if (config.endpoint) {
8346
- const endpointType = config.startEngine || _chunkR3UI7MO3cjs.isLocalEngineEndpoint.call(void 0, config.endpoint) ? "local native" : "remote";
8118
+ const endpointType = config.startEngine || _chunk4C2R5ZGVcjs.isLocalEngineEndpoint.call(void 0, config.endpoint) ? "local native" : "remote";
8347
8119
  logLine("Endpoint", `${config.endpoint} (${endpointType})`);
8348
8120
  }
8349
8121
  if (kind === "serverless" && config.publicEndpoint) {
@@ -8413,5 +8185,5 @@ function setup(input) {
8413
8185
 
8414
8186
 
8415
8187
 
8416
- exports.ALLOWED_PUBLIC_HEADERS = _chunkR3UI7MO3cjs.ALLOWED_PUBLIC_HEADERS; exports.ActorDefinition = ActorDefinition; exports.ActorError = _chunkMGI2VVF6cjs.RivetError; exports.ActorsSchema = ActorsSchema; exports.DocConfigurePoolSchema = DocConfigurePoolSchema; exports.DocEnvoyConfigSchema = DocEnvoyConfigSchema; exports.DocRegistryConfigSchema = DocRegistryConfigSchema; exports.DocServerlessConfigSchema = DocServerlessConfigSchema; exports.DocSqliteConfigSchema = DocSqliteConfigSchema; exports.InlineWebSocketAdapter = InlineWebSocketAdapter; exports.Registry = Registry; exports.RegistryConfigSchema = RegistryConfigSchema; exports.RivetError = _chunkMGI2VVF6cjs.RivetError; exports.RuntimeKindSchema = RuntimeKindSchema; exports.SqliteBackendSchema = SqliteBackendSchema; exports.SqliteConfigSchema = SqliteConfigSchema; exports.TestConfigSchema = TestConfigSchema; exports.UserError = _chunkMGI2VVF6cjs.UserError; exports.WasmRuntimeConfigSchema = WasmRuntimeConfigSchema; exports.actor = actor; exports.buildActorNames = buildActorNames; exports.createClientWithDriver = _chunkR3UI7MO3cjs.createClientWithDriver; exports.defineRunHandler = _chunkNGJWQMUUcjs.defineRunHandler; exports.event = event; exports.isStaticActorDefinition = isStaticActorDefinition; exports.isStaticActorInstance = isStaticActorInstance; exports.lookupInRegistry = lookupInRegistry; exports.noopNext = _chunkYVVFOKEPcjs.noopNext; exports.queue = queue; exports.setup = setup; exports.toUint8Array = _chunkYVVFOKEPcjs.toUint8Array;
8188
+ exports.ALLOWED_PUBLIC_HEADERS = _chunk4C2R5ZGVcjs.ALLOWED_PUBLIC_HEADERS; exports.ActorDefinition = ActorDefinition; exports.ActorError = _chunkMGI2VVF6cjs.RivetError; exports.ActorsSchema = ActorsSchema; exports.DocConfigurePoolSchema = DocConfigurePoolSchema; exports.DocEnvoyConfigSchema = DocEnvoyConfigSchema; exports.DocRegistryConfigSchema = DocRegistryConfigSchema; exports.DocServerlessConfigSchema = DocServerlessConfigSchema; exports.DocSqliteConfigSchema = DocSqliteConfigSchema; exports.InlineWebSocketAdapter = InlineWebSocketAdapter; exports.Registry = Registry; exports.RegistryConfigSchema = RegistryConfigSchema; exports.RivetError = _chunkMGI2VVF6cjs.RivetError; exports.RuntimeKindSchema = RuntimeKindSchema; exports.SqliteBackendSchema = SqliteBackendSchema; exports.SqliteConfigSchema = SqliteConfigSchema; exports.TestConfigSchema = TestConfigSchema; exports.UserError = _chunkMGI2VVF6cjs.UserError; exports.WasmRuntimeConfigSchema = WasmRuntimeConfigSchema; exports.actor = actor; exports.buildActorNames = buildActorNames; exports.createClientWithDriver = _chunk4C2R5ZGVcjs.createClientWithDriver; exports.defineRunHandler = _chunkNWCAIWHLcjs.defineRunHandler; exports.event = event; exports.isStaticActorDefinition = isStaticActorDefinition; exports.isStaticActorInstance = isStaticActorInstance; exports.lookupInRegistry = lookupInRegistry; exports.noopNext = _chunkWMRE434Qcjs.noopNext; exports.queue = queue; exports.setup = setup; exports.toUint8Array = _chunkWMRE434Qcjs.toUint8Array;
8417
8189
  //# sourceMappingURL=mod.cjs.map