rivetkit 3.0.6 → 3.1.0-rc.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.
- package/dist/browser/client.d.ts +112 -2
- package/dist/browser/client.js +145 -7
- package/dist/browser/client.js.map +1 -1
- package/dist/browser/inspector/client.js +1 -1
- package/dist/browser/inspector/client.js.map +1 -1
- package/dist/tsup/{chunk-FERZDKVR.js → chunk-5NNDJCH7.js} +3 -3
- package/dist/tsup/{chunk-FERZDKVR.js.map → chunk-5NNDJCH7.js.map} +1 -1
- package/dist/tsup/{chunk-ZPTATOYB.cjs → chunk-6LQ23TJA.cjs} +3 -3
- package/dist/tsup/{chunk-ZPTATOYB.cjs.map → chunk-6LQ23TJA.cjs.map} +1 -1
- package/dist/tsup/{chunk-ZJ2UXLEE.js → chunk-76FFOINJ.js} +146 -9
- package/dist/tsup/chunk-76FFOINJ.js.map +1 -0
- package/dist/tsup/{chunk-VNMBEXJH.js → chunk-CRC7NMU3.js} +2 -2
- package/dist/tsup/{chunk-5FQNTE3U.js → chunk-ECLJJGV6.js} +2 -2
- package/dist/tsup/{chunk-NUCUZGIV.cjs → chunk-I3YW5B3I.cjs} +7 -7
- package/dist/tsup/{chunk-NUCUZGIV.cjs.map → chunk-I3YW5B3I.cjs.map} +1 -1
- package/dist/tsup/{chunk-6HXQONU5.cjs → chunk-K6O7IE7P.cjs} +4 -4
- package/dist/tsup/{chunk-6HXQONU5.cjs.map → chunk-K6O7IE7P.cjs.map} +1 -1
- package/dist/tsup/{chunk-YNVGOPSK.cjs → chunk-MT3ZLU7U.cjs} +2 -2
- package/dist/tsup/chunk-MT3ZLU7U.cjs.map +1 -0
- package/dist/tsup/{chunk-6EH5WPVT.cjs → chunk-MUCEIMJW.cjs} +286 -149
- package/dist/tsup/chunk-MUCEIMJW.cjs.map +1 -0
- package/dist/tsup/{chunk-YWWDUC6D.cjs → chunk-OKLZYDQB.cjs} +5 -1
- package/dist/tsup/chunk-OKLZYDQB.cjs.map +1 -0
- package/dist/tsup/{chunk-CJSADDKT.js → chunk-R4VUGJNR.js} +4 -4
- package/dist/tsup/{chunk-SAR7BMVU.js → chunk-SVWVXVV7.js} +2 -2
- package/dist/tsup/{chunk-NPA2A53S.cjs → chunk-SXEIT5DF.cjs} +3 -3
- package/dist/tsup/{chunk-NPA2A53S.cjs.map → chunk-SXEIT5DF.cjs.map} +1 -1
- package/dist/tsup/{chunk-AETY7X4G.js → chunk-TDHEMJHH.js} +2 -2
- package/dist/tsup/{chunk-PBIQPYE5.js → chunk-UFHGMXXV.js} +5 -1
- package/dist/tsup/chunk-UFHGMXXV.js.map +1 -0
- package/dist/tsup/{chunk-ZWNTOFM3.js → chunk-UYCRHJY2.js} +2 -2
- package/dist/tsup/chunk-UYCRHJY2.js.map +1 -0
- package/dist/tsup/{chunk-WMAHPIFS.cjs → chunk-VOGVBK5O.cjs} +10 -10
- package/dist/tsup/{chunk-WMAHPIFS.cjs.map → chunk-VOGVBK5O.cjs.map} +1 -1
- package/dist/tsup/{chunk-JU6RP3LW.cjs → chunk-YTSSP6NX.cjs} +3 -3
- package/dist/tsup/{chunk-JU6RP3LW.cjs.map → chunk-YTSSP6NX.cjs.map} +1 -1
- package/dist/tsup/client/mod.cjs +5 -5
- package/dist/tsup/client/mod.d.cts +2 -2
- package/dist/tsup/client/mod.d.ts +2 -2
- package/dist/tsup/client/mod.js +4 -4
- package/dist/tsup/common/log.cjs +2 -2
- package/dist/tsup/common/log.js +1 -1
- package/dist/tsup/common/websocket.cjs +3 -3
- package/dist/tsup/common/websocket.js +2 -2
- package/dist/tsup/{config-BDJltifk.d.cts → config-DFAysGOK.d.cts} +114 -3
- package/dist/tsup/{config-DXC7qzme.d.ts → config-Dn8SZJF8.d.ts} +114 -3
- package/dist/tsup/{context-DgPsVbw6.d.ts → context-D_c2ERjO.d.ts} +5 -1
- package/dist/tsup/{context-osC4Q1ax.d.cts → context-fSkMTO5w.d.cts} +5 -1
- package/dist/tsup/db/drizzle.cjs +2 -2
- package/dist/tsup/db/drizzle.js +1 -1
- package/dist/tsup/db/mod.cjs +3 -3
- package/dist/tsup/db/mod.js +2 -2
- package/dist/tsup/dynamic/mod.cjs +2 -2
- package/dist/tsup/dynamic/mod.d.cts +1 -1
- package/dist/tsup/dynamic/mod.d.ts +1 -1
- package/dist/tsup/dynamic/mod.js +1 -1
- package/dist/tsup/inspector/mod.cjs +5 -5
- package/dist/tsup/inspector/mod.js +4 -4
- package/dist/tsup/inspector/workflow.cjs +4 -4
- package/dist/tsup/inspector/workflow.js +3 -3
- package/dist/tsup/inspector-tab/mod.cjs +2 -2
- package/dist/tsup/inspector-tab/mod.d.cts +2 -2
- package/dist/tsup/inspector-tab/mod.d.ts +2 -2
- package/dist/tsup/inspector-tab/mod.js +1 -1
- package/dist/tsup/mod.cjs +153 -110
- package/dist/tsup/mod.cjs.map +1 -1
- package/dist/tsup/mod.d.cts +3 -3
- package/dist/tsup/mod.d.ts +3 -3
- package/dist/tsup/mod.js +49 -6
- package/dist/tsup/mod.js.map +1 -1
- package/dist/tsup/test/mod.cjs +6 -6
- package/dist/tsup/test/mod.d.cts +1 -1
- package/dist/tsup/test/mod.d.ts +1 -1
- package/dist/tsup/test/mod.js +4 -4
- package/dist/tsup/utils.cjs +2 -2
- package/dist/tsup/utils.js +1 -1
- package/dist/tsup/workflow/mod.cjs +22 -10
- package/dist/tsup/workflow/mod.cjs.map +1 -1
- package/dist/tsup/workflow/mod.d.cts +3 -3
- package/dist/tsup/workflow/mod.d.ts +3 -3
- package/dist/tsup/workflow/mod.js +17 -5
- package/dist/tsup/workflow/mod.js.map +1 -1
- package/package.json +9 -9
- package/src/actor/config.ts +79 -0
- package/src/client/actor-conn.ts +43 -7
- package/src/client/client.ts +93 -0
- package/src/client/errors.ts +12 -0
- package/src/client/lifecycle-errors.ts +28 -1
- package/src/client/mod.ts +1 -0
- package/src/client/retry-budget.ts +4 -1
- package/src/common/actor-router-consts.ts +1 -0
- package/src/engine-api/actors.ts +12 -0
- package/src/engine-client/actor-http-client.ts +6 -0
- package/src/engine-client/actor-websocket-client.ts +25 -1
- package/src/engine-client/api-endpoints.ts +16 -0
- package/src/engine-client/driver.ts +12 -0
- package/src/engine-client/mod.ts +30 -0
- package/src/registry/napi-runtime.ts +8 -0
- package/src/registry/native.ts +49 -0
- package/src/registry/runtime.ts +11 -0
- package/src/registry/wasm-runtime.ts +9 -0
- package/src/workflow/context.ts +17 -0
- package/dist/tsup/chunk-6EH5WPVT.cjs.map +0 -1
- package/dist/tsup/chunk-PBIQPYE5.js.map +0 -1
- package/dist/tsup/chunk-YNVGOPSK.cjs.map +0 -1
- package/dist/tsup/chunk-YWWDUC6D.cjs.map +0 -1
- package/dist/tsup/chunk-ZJ2UXLEE.js.map +0 -1
- package/dist/tsup/chunk-ZWNTOFM3.js.map +0 -1
- /package/dist/tsup/{chunk-VNMBEXJH.js.map → chunk-CRC7NMU3.js.map} +0 -0
- /package/dist/tsup/{chunk-5FQNTE3U.js.map → chunk-ECLJJGV6.js.map} +0 -0
- /package/dist/tsup/{chunk-CJSADDKT.js.map → chunk-R4VUGJNR.js.map} +0 -0
- /package/dist/tsup/{chunk-SAR7BMVU.js.map → chunk-SVWVXVV7.js.map} +0 -0
- /package/dist/tsup/{chunk-AETY7X4G.js.map → chunk-TDHEMJHH.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
|
|
3
|
+
var _chunkK6O7IE7Pcjs = require('./chunk-K6O7IE7P.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
6
|
|
|
@@ -17,7 +17,7 @@ var _chunk6HXQONU5cjs = require('./chunk-6HXQONU5.cjs');
|
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
var
|
|
20
|
+
var _chunkOKLZYDQBcjs = require('./chunk-OKLZYDQB.cjs');
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
|
|
@@ -35,17 +35,17 @@ var _chunkYWWDUC6Dcjs = require('./chunk-YWWDUC6D.cjs');
|
|
|
35
35
|
|
|
36
36
|
|
|
37
37
|
|
|
38
|
-
var
|
|
38
|
+
var _chunkMUCEIMJWcjs = require('./chunk-MUCEIMJW.cjs');
|
|
39
39
|
|
|
40
40
|
|
|
41
41
|
|
|
42
42
|
var _chunkRTWH3AX3cjs = require('./chunk-RTWH3AX3.cjs');
|
|
43
|
-
require('./chunk-
|
|
43
|
+
require('./chunk-SXEIT5DF.cjs');
|
|
44
44
|
|
|
45
45
|
|
|
46
46
|
|
|
47
47
|
|
|
48
|
-
var
|
|
48
|
+
var _chunkYTSSP6NXcjs = require('./chunk-YTSSP6NX.cjs');
|
|
49
49
|
require('./chunk-KVFIONKQ.cjs');
|
|
50
50
|
|
|
51
51
|
|
|
@@ -80,7 +80,7 @@ require('./chunk-KVFIONKQ.cjs');
|
|
|
80
80
|
|
|
81
81
|
|
|
82
82
|
|
|
83
|
-
var
|
|
83
|
+
var _chunkMT3ZLU7Ucjs = require('./chunk-MT3ZLU7U.cjs');
|
|
84
84
|
|
|
85
85
|
|
|
86
86
|
|
|
@@ -98,7 +98,7 @@ var _chunkMGI2VVF6cjs = require('./chunk-MGI2VVF6.cjs');
|
|
|
98
98
|
|
|
99
99
|
// src/actor/log.ts
|
|
100
100
|
function loggerWithoutContext() {
|
|
101
|
-
return
|
|
101
|
+
return _chunkMT3ZLU7Ucjs.getLogger.call(void 0, "actor-runtime");
|
|
102
102
|
}
|
|
103
103
|
|
|
104
104
|
// src/actor/definition.ts
|
|
@@ -127,7 +127,7 @@ function warnDeprecatedRun(input) {
|
|
|
127
127
|
const run = input.run;
|
|
128
128
|
if (run === void 0) return;
|
|
129
129
|
const runFunction = typeof run === "object" && run !== null ? run.run : run;
|
|
130
|
-
if (typeof runFunction === "function" &&
|
|
130
|
+
if (typeof runFunction === "function" && _chunkOKLZYDQBcjs.getRunInspectorKind.call(void 0, runFunction) === "workflow") {
|
|
131
131
|
return;
|
|
132
132
|
}
|
|
133
133
|
warnedDeprecatedRun = true;
|
|
@@ -153,10 +153,10 @@ function actor(input) {
|
|
|
153
153
|
input == null ? void 0 : input.options
|
|
154
154
|
);
|
|
155
155
|
warnDeprecatedRun(input);
|
|
156
|
-
const config =
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
156
|
+
const config = _chunkOKLZYDQBcjs.ActorConfigSchema.parse(input);
|
|
157
|
+
_chunkOKLZYDQBcjs.flattenActionHandlers.call(void 0, config.actions);
|
|
158
|
+
_chunkOKLZYDQBcjs.flattenActionInputSchemas.call(void 0, config.actions, config.actionInputSchemas);
|
|
159
|
+
_chunkOKLZYDQBcjs.flattenActionTraceSamplers.call(void 0, config.actions, (_a = config.tracing) == null ? void 0 : _a.actions);
|
|
160
160
|
return new ActorDefinition(config);
|
|
161
161
|
}
|
|
162
162
|
function isStaticActorDefinition(definition) {
|
|
@@ -255,7 +255,7 @@ function validateSchemaSync(schemas, key, data) {
|
|
|
255
255
|
var _virtualwebsocket = require('@rivetkit/virtual-websocket');
|
|
256
256
|
var _ws = require('hono/ws');
|
|
257
257
|
function logger() {
|
|
258
|
-
return
|
|
258
|
+
return _chunkMT3ZLU7Ucjs.getLogger.call(void 0, "inline-websocket-adapter");
|
|
259
259
|
}
|
|
260
260
|
var InlineWebSocketAdapter = class {
|
|
261
261
|
#handler;
|
|
@@ -407,7 +407,7 @@ var InlineWebSocketAdapter = class {
|
|
|
407
407
|
|
|
408
408
|
// src/registry/log.ts
|
|
409
409
|
function logger2() {
|
|
410
|
-
return
|
|
410
|
+
return _chunkMT3ZLU7Ucjs.getLogger.call(void 0, "registry");
|
|
411
411
|
}
|
|
412
412
|
|
|
413
413
|
// src/serverless/configure.ts
|
|
@@ -453,8 +453,8 @@ async function configureServerlessPool(config) {
|
|
|
453
453
|
);
|
|
454
454
|
}
|
|
455
455
|
const customConfig = config.configurePool;
|
|
456
|
-
const clientConfig =
|
|
457
|
-
const dcsRes = await
|
|
456
|
+
const clientConfig = _chunkMUCEIMJWcjs.convertRegistryConfigToClientConfig.call(void 0, config);
|
|
457
|
+
const dcsRes = await _chunkMUCEIMJWcjs.getDatacenters.call(void 0, clientConfig);
|
|
458
458
|
const poolName = _nullishCoalesce(customConfig.name, () => ( "default"));
|
|
459
459
|
const serverlessToken = _nullishCoalesce(config.token, () => ( config.publicToken));
|
|
460
460
|
const headers = {
|
|
@@ -476,7 +476,7 @@ async function configureServerlessPool(config) {
|
|
|
476
476
|
metadata: _nullishCoalesce(customConfig.metadata, () => ( {})),
|
|
477
477
|
drain_on_version_upgrade: _nullishCoalesce(customConfig.drainOnVersionUpgrade, () => ( true))
|
|
478
478
|
};
|
|
479
|
-
await
|
|
479
|
+
await _chunkMUCEIMJWcjs.updateRunnerConfig.call(void 0, clientConfig, poolName, {
|
|
480
480
|
datacenters: Object.fromEntries(
|
|
481
481
|
dcsRes.datacenters.map((dc) => [dc.name, serverlessConfig])
|
|
482
482
|
)
|
|
@@ -493,7 +493,7 @@ async function configureServerlessPool(config) {
|
|
|
493
493
|
logger2().warn({
|
|
494
494
|
msg: "serverless pool configuration attempt failed",
|
|
495
495
|
attempts,
|
|
496
|
-
error:
|
|
496
|
+
error: _chunkMT3ZLU7Ucjs.stringifyError.call(void 0, error)
|
|
497
497
|
});
|
|
498
498
|
await sleep(CONFIGURE_RETRY_DELAY_MS);
|
|
499
499
|
}
|
|
@@ -501,7 +501,7 @@ async function configureServerlessPool(config) {
|
|
|
501
501
|
logger2().error({
|
|
502
502
|
msg: "failed to configure serverless pool, validate endpoint is configured correctly then restart this process",
|
|
503
503
|
attempts,
|
|
504
|
-
error:
|
|
504
|
+
error: _chunkMT3ZLU7Ucjs.stringifyError.call(void 0, lastError)
|
|
505
505
|
});
|
|
506
506
|
throw lastError;
|
|
507
507
|
}
|
|
@@ -512,10 +512,10 @@ var _zod = require('zod');
|
|
|
512
512
|
// src/registry/config/envoy.ts
|
|
513
513
|
var _v4 = require('zod/v4');
|
|
514
514
|
var EnvoyConfigSchema = _v4.z.object({
|
|
515
|
-
poolName: _v4.z.string().default(() => _nullishCoalesce(
|
|
516
|
-
version: _v4.z.number().default(() => _nullishCoalesce(
|
|
515
|
+
poolName: _v4.z.string().default(() => _nullishCoalesce(_chunkMT3ZLU7Ucjs.getRivetPool.call(void 0, ), () => ( "default"))),
|
|
516
|
+
version: _v4.z.number().default(() => _nullishCoalesce(_chunkMT3ZLU7Ucjs.getRivetEnvoyVersion.call(void 0, ), () => ( 1))),
|
|
517
517
|
// Deprecated.
|
|
518
|
-
totalSlots: _v4.z.number().default(() => _nullishCoalesce(
|
|
518
|
+
totalSlots: _v4.z.number().default(() => _nullishCoalesce(_chunkMT3ZLU7Ucjs.getRivetTotalSlots.call(void 0, ), () => ( 1e5))),
|
|
519
519
|
nodeKey: _v4.z.string().optional()
|
|
520
520
|
});
|
|
521
521
|
|
|
@@ -553,7 +553,7 @@ var ServerlessConfigSchema = _v4.z.object({
|
|
|
553
553
|
*
|
|
554
554
|
* Can also be set via RIVET_PUBLIC_ENDPOINT environment variable.
|
|
555
555
|
*/
|
|
556
|
-
publicEndpoint: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => (
|
|
556
|
+
publicEndpoint: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkMT3ZLU7Ucjs.getRivetPublicEndpoint.call(void 0, )))),
|
|
557
557
|
/**
|
|
558
558
|
* Token that clients should use when connecting via the public endpoint.
|
|
559
559
|
*
|
|
@@ -561,7 +561,7 @@ var ServerlessConfigSchema = _v4.z.object({
|
|
|
561
561
|
*
|
|
562
562
|
* Can also be specified in the publicEndpoint URL as `https://namespace:token@host`.
|
|
563
563
|
*/
|
|
564
|
-
publicToken: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => (
|
|
564
|
+
publicToken: _v4.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkMT3ZLU7Ucjs.getRivetPublicToken.call(void 0, ))))
|
|
565
565
|
// There is no publicNamespace config option because the frontend and backend
|
|
566
566
|
// cannot use different namespaces. The namespace is extracted from the
|
|
567
567
|
// publicEndpoint URL auth syntax if provided.
|
|
@@ -615,7 +615,7 @@ var RegistryConfigSchema = _zod.z.object({
|
|
|
615
615
|
* Runtime binding to use for RivetKit core.
|
|
616
616
|
* */
|
|
617
617
|
runtime: RuntimeKindSchema.optional().transform((val, ctx) => {
|
|
618
|
-
const rawRuntime = _nullishCoalesce(val, () => (
|
|
618
|
+
const rawRuntime = _nullishCoalesce(val, () => ( _chunkMT3ZLU7Ucjs.getRivetkitRuntime.call(void 0, )));
|
|
619
619
|
if (rawRuntime === void 0) {
|
|
620
620
|
return "auto";
|
|
621
621
|
}
|
|
@@ -652,7 +652,7 @@ var RegistryConfigSchema = _zod.z.object({
|
|
|
652
652
|
* */
|
|
653
653
|
logging: _zod.z.object({
|
|
654
654
|
baseLogger: _zod.z.custom().optional(),
|
|
655
|
-
level:
|
|
655
|
+
level: _chunkMT3ZLU7Ucjs.LogLevelSchema.optional()
|
|
656
656
|
}).optional().default(() => ({})),
|
|
657
657
|
// MARK: Routing
|
|
658
658
|
// // This is a function to allow for lazy configuration of upgradeWebSocket on the
|
|
@@ -670,9 +670,9 @@ var RegistryConfigSchema = _zod.z.object({
|
|
|
670
670
|
*
|
|
671
671
|
* Can also be set via RIVET_ENDPOINT environment variables.
|
|
672
672
|
*/
|
|
673
|
-
endpoint: _zod.z.string().optional().transform((val) => _nullishCoalesce(_nullishCoalesce(val, () => (
|
|
674
|
-
token: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => (
|
|
675
|
-
namespace: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => (
|
|
673
|
+
endpoint: _zod.z.string().optional().transform((val) => _nullishCoalesce(_nullishCoalesce(val, () => ( _chunkMT3ZLU7Ucjs.getRivetEngine.call(void 0, ))), () => ( _chunkMT3ZLU7Ucjs.getRivetEndpoint.call(void 0, )))),
|
|
674
|
+
token: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkMT3ZLU7Ucjs.getRivetToken.call(void 0, )))),
|
|
675
|
+
namespace: _zod.z.string().optional().transform((val) => _nullishCoalesce(val, () => ( _chunkMT3ZLU7Ucjs.getRivetNamespace.call(void 0, )))),
|
|
676
676
|
headers: _zod.z.record(_zod.z.string(), _zod.z.string()).optional().default({}),
|
|
677
677
|
// MARK: Client
|
|
678
678
|
// TODO:
|
|
@@ -712,21 +712,21 @@ var RegistryConfigSchema = _zod.z.object({
|
|
|
712
712
|
*
|
|
713
713
|
* Starts the full Rust engine process locally.
|
|
714
714
|
*/
|
|
715
|
-
startEngine: _zod.z.boolean().default(() =>
|
|
715
|
+
startEngine: _zod.z.boolean().default(() => _chunkMT3ZLU7Ucjs.getRivetRunEngine.call(void 0, )),
|
|
716
716
|
/**
|
|
717
717
|
* @experimental
|
|
718
718
|
*
|
|
719
719
|
* Host to bind the spawned local engine process to.
|
|
720
720
|
*/
|
|
721
|
-
engineHost: _zod.z.string().optional().default(() => _nullishCoalesce(
|
|
721
|
+
engineHost: _zod.z.string().optional().default(() => _nullishCoalesce(_chunkMT3ZLU7Ucjs.getRivetRunEngineHost.call(void 0, ), () => ( _chunkMUCEIMJWcjs.ENGINE_HOST))),
|
|
722
722
|
/**
|
|
723
723
|
* @experimental
|
|
724
724
|
*
|
|
725
725
|
* Port to bind the spawned local engine process to.
|
|
726
726
|
*/
|
|
727
|
-
enginePort: _zod.z.number().int().min(1).max(65535).optional().default(() => _nullishCoalesce(
|
|
727
|
+
enginePort: _zod.z.number().int().min(1).max(65535).optional().default(() => _nullishCoalesce(_chunkMT3ZLU7Ucjs.getRivetRunEnginePort.call(void 0, ), () => ( _chunkMUCEIMJWcjs.ENGINE_PORT))),
|
|
728
728
|
/** @experimental */
|
|
729
|
-
engineVersion: _zod.z.string().optional().default(() => _nullishCoalesce(
|
|
729
|
+
engineVersion: _zod.z.string().optional().default(() => _nullishCoalesce(_chunkMT3ZLU7Ucjs.getRivetRunEngineVersion.call(void 0, ), () => ( _chunkMT3ZLU7Ucjs.VERSION))),
|
|
730
730
|
/**
|
|
731
731
|
* Starts the first-party Services actor host when RivetKit manages
|
|
732
732
|
* a local engine. Enabled by default for a managed local Engine. Set
|
|
@@ -783,7 +783,7 @@ var RegistryConfigSchema = _zod.z.object({
|
|
|
783
783
|
}))
|
|
784
784
|
}).transform((config, ctx) => {
|
|
785
785
|
var _a, _b, _c;
|
|
786
|
-
const isDevEnv =
|
|
786
|
+
const isDevEnv = _chunkMT3ZLU7Ucjs.isDev.call(void 0, );
|
|
787
787
|
const sqliteBackend = _nullishCoalesce(((_a = config.sqlite) == null ? void 0 : _a.backend), () => ( ((_b = config.test) == null ? void 0 : _b.sqliteBackend)));
|
|
788
788
|
if (config.runtime === "wasm" && sqliteBackend === "local") {
|
|
789
789
|
ctx.addIssue({
|
|
@@ -793,7 +793,7 @@ var RegistryConfigSchema = _zod.z.object({
|
|
|
793
793
|
});
|
|
794
794
|
}
|
|
795
795
|
const sqlite = config.runtime === "wasm" && config.sqlite === void 0 ? { backend: "remote" } : config.sqlite;
|
|
796
|
-
const parsedEndpoint = config.endpoint ?
|
|
796
|
+
const parsedEndpoint = config.endpoint ? _chunkMUCEIMJWcjs.tryParseEndpoint.call(void 0, ctx, {
|
|
797
797
|
endpoint: config.endpoint,
|
|
798
798
|
path: ["endpoint"],
|
|
799
799
|
namespace: config.namespace,
|
|
@@ -812,19 +812,19 @@ var RegistryConfigSchema = _zod.z.object({
|
|
|
812
812
|
path: ["configurePool"]
|
|
813
813
|
});
|
|
814
814
|
}
|
|
815
|
-
const localEngineEndpoint =
|
|
815
|
+
const localEngineEndpoint = _chunkMUCEIMJWcjs.buildEngineEndpoint.call(void 0,
|
|
816
816
|
config.engineHost,
|
|
817
817
|
config.enginePort
|
|
818
818
|
);
|
|
819
819
|
const endpoint = config.startEngine ? localEngineEndpoint : _nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.endpoint), () => ( (isDevEnv ? localEngineEndpoint : void 0)));
|
|
820
820
|
const engineSpawn = !parsedEndpoint && Boolean(endpoint);
|
|
821
|
-
const startServices = _nullishCoalesce(_nullishCoalesce(config.startServices, () => (
|
|
821
|
+
const startServices = _nullishCoalesce(_nullishCoalesce(config.startServices, () => ( _chunkMT3ZLU7Ucjs.getRivetRunServices.call(void 0, ))), () => ( engineSpawn));
|
|
822
822
|
const validateServerlessEndpoint = Boolean(
|
|
823
823
|
config.startEngine || parsedEndpoint
|
|
824
824
|
);
|
|
825
825
|
const namespace = _nullishCoalesce(_nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.namespace), () => ( config.namespace)), () => ( "default"));
|
|
826
|
-
const token = _nullishCoalesce(_nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.token), () => ( config.token)), () => ( (endpoint &&
|
|
827
|
-
const parsedPublicEndpoint = config.serverless.publicEndpoint ?
|
|
826
|
+
const token = _nullishCoalesce(_nullishCoalesce((parsedEndpoint == null ? void 0 : parsedEndpoint.token), () => ( config.token)), () => ( (endpoint && _chunkMUCEIMJWcjs.isLocalEngineEndpoint.call(void 0, endpoint) ? "default" : void 0)));
|
|
827
|
+
const parsedPublicEndpoint = config.serverless.publicEndpoint ? _chunkMUCEIMJWcjs.tryParseEndpoint.call(void 0, ctx, {
|
|
828
828
|
endpoint: config.serverless.publicEndpoint,
|
|
829
829
|
path: ["serverless", "publicEndpoint"]
|
|
830
830
|
}) : void 0;
|
|
@@ -861,7 +861,7 @@ function buildActorNames(config) {
|
|
|
861
861
|
Object.keys(config.use).map((actorName) => {
|
|
862
862
|
const definition = config.use[actorName];
|
|
863
863
|
const options = _nullishCoalesce(definition.config.options, () => ( {}));
|
|
864
|
-
const runMeta =
|
|
864
|
+
const runMeta = _chunkOKLZYDQBcjs.getRunMetadata.call(void 0, definition.config.run);
|
|
865
865
|
const metadata = {};
|
|
866
866
|
metadata.icon = _nullishCoalesce(options.icon, () => ( runMeta.icon));
|
|
867
867
|
metadata.name = _nullishCoalesce(options.name, () => ( runMeta.name));
|
|
@@ -929,7 +929,7 @@ var DocRegistryConfigSchema = _zod.z.object({
|
|
|
929
929
|
noWelcome: _zod.z.boolean().optional().describe("Disable the welcome message on startup. Default: false"),
|
|
930
930
|
sqlite: DocSqliteConfigSchema,
|
|
931
931
|
logging: _zod.z.object({
|
|
932
|
-
level:
|
|
932
|
+
level: _chunkMT3ZLU7Ucjs.LogLevelSchema.optional().describe(
|
|
933
933
|
"Log level for RivetKit. Default: 'warn'"
|
|
934
934
|
)
|
|
935
935
|
}).optional().describe("Logging configuration."),
|
|
@@ -1569,7 +1569,7 @@ var NapiCoreRuntime = (_class = class {
|
|
|
1569
1569
|
if (!(active == null ? void 0 : active.sameActorInstance(ownerCtx))) {
|
|
1570
1570
|
return ownerCtx;
|
|
1571
1571
|
}
|
|
1572
|
-
const applicationSpan =
|
|
1572
|
+
const applicationSpan = _chunkMUCEIMJWcjs.readActiveTraceHeaders.call(void 0, );
|
|
1573
1573
|
if (!applicationSpan) {
|
|
1574
1574
|
return active;
|
|
1575
1575
|
}
|
|
@@ -1782,7 +1782,7 @@ var NapiCoreRuntime = (_class = class {
|
|
|
1782
1782
|
const span = (_a = nativeCtx.invocationTraceContext()) == null ? void 0 : _a.span;
|
|
1783
1783
|
return this.#invocationContext.run(
|
|
1784
1784
|
nativeCtx,
|
|
1785
|
-
() =>
|
|
1785
|
+
() => _chunkMUCEIMJWcjs.runWithActorInvocationSpan.call(void 0, span, run)
|
|
1786
1786
|
);
|
|
1787
1787
|
}
|
|
1788
1788
|
actorInvocationTraceContext(ctx) {
|
|
@@ -1831,9 +1831,15 @@ var NapiCoreRuntime = (_class = class {
|
|
|
1831
1831
|
actorKey(ctx) {
|
|
1832
1832
|
return asNativeActorContext(ctx).key();
|
|
1833
1833
|
}
|
|
1834
|
+
actorForkChain(ctx) {
|
|
1835
|
+
return asNativeActorContext(ctx).forkChain();
|
|
1836
|
+
}
|
|
1834
1837
|
actorRegion(ctx) {
|
|
1835
1838
|
return asNativeActorContext(ctx).region();
|
|
1836
1839
|
}
|
|
1840
|
+
actorNamespace(ctx) {
|
|
1841
|
+
return asNativeActorContext(ctx).namespace();
|
|
1842
|
+
}
|
|
1837
1843
|
actorSleep(ctx) {
|
|
1838
1844
|
asNativeActorContext(ctx).sleep();
|
|
1839
1845
|
}
|
|
@@ -2154,8 +2160,8 @@ function runtimeBytesToArrayBuffer(value) {
|
|
|
2154
2160
|
function buildNativeHttpRequest(init) {
|
|
2155
2161
|
var _a;
|
|
2156
2162
|
const headers = new Headers(init.headers);
|
|
2157
|
-
const originalUrl = headers.get(
|
|
2158
|
-
headers.delete(
|
|
2163
|
+
const originalUrl = headers.get(_chunkMUCEIMJWcjs.HEADER_ORIGINAL_REQUEST_URL);
|
|
2164
|
+
headers.delete(_chunkMUCEIMJWcjs.HEADER_ORIGINAL_REQUEST_URL);
|
|
2159
2165
|
const url = _nullishCoalesce(originalUrl, () => ( (init.uri.startsWith("http") ? init.uri : new URL(init.uri, "http://127.0.0.1").toString())));
|
|
2160
2166
|
const method2 = init.method.toUpperCase();
|
|
2161
2167
|
const bodyForbidden = method2 === "GET" || method2 === "HEAD";
|
|
@@ -2234,7 +2240,7 @@ async function pumpResponseBody(reader, stream) {
|
|
|
2234
2240
|
}
|
|
2235
2241
|
} catch (error) {
|
|
2236
2242
|
try {
|
|
2237
|
-
await stream.error(
|
|
2243
|
+
await stream.error(_chunkMT3ZLU7Ucjs.stringifyError.call(void 0, error));
|
|
2238
2244
|
} catch (streamError) {
|
|
2239
2245
|
logger2().debug({
|
|
2240
2246
|
msg: "failed to report native http response stream error",
|
|
@@ -2402,7 +2408,7 @@ var RunHandlerCoordinator = class {
|
|
|
2402
2408
|
this.#run = run;
|
|
2403
2409
|
}
|
|
2404
2410
|
get inspectorKind() {
|
|
2405
|
-
return
|
|
2411
|
+
return _chunkOKLZYDQBcjs.getRunInspectorKind.call(void 0, this.#run);
|
|
2406
2412
|
}
|
|
2407
2413
|
async run(actorId, restart, callback) {
|
|
2408
2414
|
const state = this.#getOrCreate(actorId);
|
|
@@ -2510,7 +2516,7 @@ var RunHandlerCoordinator = class {
|
|
|
2510
2516
|
}
|
|
2511
2517
|
#initializeInspector(actorId, state) {
|
|
2512
2518
|
if (state.inspectorInitialized) return;
|
|
2513
|
-
const inspector =
|
|
2519
|
+
const inspector = _chunkOKLZYDQBcjs.createRunInspector.call(void 0, this.#run, {
|
|
2514
2520
|
actorId,
|
|
2515
2521
|
control: this.#control(actorId, state)
|
|
2516
2522
|
});
|
|
@@ -2869,9 +2875,15 @@ var WasmCoreRuntime = (_class2 = class {
|
|
|
2869
2875
|
actorKey(ctx) {
|
|
2870
2876
|
return callHandle(asWasmActorContext(ctx), "key");
|
|
2871
2877
|
}
|
|
2878
|
+
actorForkChain(ctx) {
|
|
2879
|
+
return callHandle(asWasmActorContext(ctx), "forkChain");
|
|
2880
|
+
}
|
|
2872
2881
|
actorRegion(ctx) {
|
|
2873
2882
|
return callHandle(asWasmActorContext(ctx), "region");
|
|
2874
2883
|
}
|
|
2884
|
+
actorNamespace(ctx) {
|
|
2885
|
+
return callHandle(asWasmActorContext(ctx), "namespace");
|
|
2886
|
+
}
|
|
2875
2887
|
actorSleep(ctx) {
|
|
2876
2888
|
callHandle(asWasmActorContext(ctx), "sleep");
|
|
2877
2889
|
}
|
|
@@ -3462,7 +3474,7 @@ async function loadAutoRuntime(config, loaders = defaultRuntimeLoaders) {
|
|
|
3462
3474
|
nativeError = error;
|
|
3463
3475
|
logger2().warn({
|
|
3464
3476
|
msg: "native runtime failed to load; falling back to wasm",
|
|
3465
|
-
error:
|
|
3477
|
+
error: _chunkMT3ZLU7Ucjs.stringifyError.call(void 0, error)
|
|
3466
3478
|
});
|
|
3467
3479
|
}
|
|
3468
3480
|
try {
|
|
@@ -3471,7 +3483,7 @@ async function loadAutoRuntime(config, loaders = defaultRuntimeLoaders) {
|
|
|
3471
3483
|
throw new (0, _chunkMGI2VVF6cjs.RivetError)(
|
|
3472
3484
|
"config",
|
|
3473
3485
|
"runtime_unavailable",
|
|
3474
|
-
`RivetKit could not load a core runtime. Native runtime: ${
|
|
3486
|
+
`RivetKit could not load a core runtime. Native runtime: ${_chunkMT3ZLU7Ucjs.stringifyError.call(void 0, nativeError)} Wasm runtime: ${_chunkMT3ZLU7Ucjs.stringifyError.call(void 0, wasmError)}`,
|
|
3475
3487
|
{
|
|
3476
3488
|
public: true,
|
|
3477
3489
|
statusCode: 500
|
|
@@ -3679,7 +3691,7 @@ async function cleanupNativeSleepRuntimeState(runtime, ctx, afterTrackedWorkDrai
|
|
|
3679
3691
|
}).catch((error) => {
|
|
3680
3692
|
logger2().warn({
|
|
3681
3693
|
msg: "deferred native sleep cleanup failed",
|
|
3682
|
-
error:
|
|
3694
|
+
error: _chunkMT3ZLU7Ucjs.stringifyError.call(void 0, error)
|
|
3683
3695
|
});
|
|
3684
3696
|
});
|
|
3685
3697
|
return;
|
|
@@ -3851,10 +3863,10 @@ function decodeValue(value) {
|
|
|
3851
3863
|
if (!value || value.length === 0) {
|
|
3852
3864
|
return void 0;
|
|
3853
3865
|
}
|
|
3854
|
-
return
|
|
3866
|
+
return _chunkMT3ZLU7Ucjs.decodeCborCompat.call(void 0, value);
|
|
3855
3867
|
}
|
|
3856
3868
|
function encodeValue(value) {
|
|
3857
|
-
return
|
|
3869
|
+
return _chunkMT3ZLU7Ucjs.encodeCborCompat.call(void 0, value);
|
|
3858
3870
|
}
|
|
3859
3871
|
function normalizeArgs(value) {
|
|
3860
3872
|
return Array.isArray(value) ? value : value === void 0 || value === null ? [] : [value];
|
|
@@ -3890,7 +3902,7 @@ function isStructuredBridgeError(error) {
|
|
|
3890
3902
|
return _chunkMGI2VVF6cjs.isRivetErrorLike.call(void 0, error) && "__type" in error && (error.__type === "RivetError" || error.__type === "ActorError");
|
|
3891
3903
|
}
|
|
3892
3904
|
function encodeNativeCallbackError(error) {
|
|
3893
|
-
const structuredError = isStructuredBridgeError(error) ? error :
|
|
3905
|
+
const structuredError = isStructuredBridgeError(error) ? error : _chunkMT3ZLU7Ucjs.deconstructError.call(void 0, error, true);
|
|
3894
3906
|
const { encoded, droppedMetadataCause } = _chunkMGI2VVF6cjs.encodeBridgeRivetError.call(void 0, structuredError);
|
|
3895
3907
|
if (droppedMetadataCause !== void 0) {
|
|
3896
3908
|
logger2().warn(
|
|
@@ -3952,7 +3964,7 @@ function decodeWorkflowCbor(data) {
|
|
|
3952
3964
|
return null;
|
|
3953
3965
|
}
|
|
3954
3966
|
try {
|
|
3955
|
-
return
|
|
3967
|
+
return _chunkMT3ZLU7Ucjs.decodeCborCompat.call(void 0, new Uint8Array(data));
|
|
3956
3968
|
} catch (e3) {
|
|
3957
3969
|
return null;
|
|
3958
3970
|
}
|
|
@@ -4065,7 +4077,7 @@ function serializeWorkflowHistoryForJson(data) {
|
|
|
4065
4077
|
if (data === null) {
|
|
4066
4078
|
return null;
|
|
4067
4079
|
}
|
|
4068
|
-
const history =
|
|
4080
|
+
const history = _chunkK6O7IE7Pcjs.decodeWorkflowHistoryTransport.call(void 0, data);
|
|
4069
4081
|
return jsonSafe({
|
|
4070
4082
|
nameRegistry: [...history.nameRegistry],
|
|
4071
4083
|
entries: history.entries.map((entry) => ({
|
|
@@ -4164,7 +4176,7 @@ var NativeConnAdapter = class {
|
|
|
4164
4176
|
this.#ctx = ctx;
|
|
4165
4177
|
this.#queueHibernationRemoval = queueHibernationRemoval;
|
|
4166
4178
|
this.#assertCanMutateState = assertCanMutateState;
|
|
4167
|
-
this[
|
|
4179
|
+
this[_chunkOKLZYDQBcjs.CONN_STATE_MANAGER_SYMBOL] = {
|
|
4168
4180
|
stateEnabled: true,
|
|
4169
4181
|
get state() {
|
|
4170
4182
|
return thisConn.state;
|
|
@@ -4181,7 +4193,7 @@ var NativeConnAdapter = class {
|
|
|
4181
4193
|
decodeValue(this.#runtime.connParams(this.#conn))
|
|
4182
4194
|
);
|
|
4183
4195
|
}
|
|
4184
|
-
[
|
|
4196
|
+
[_chunkOKLZYDQBcjs.RAW_STATE_SYMBOL]() {
|
|
4185
4197
|
return this.#readState();
|
|
4186
4198
|
}
|
|
4187
4199
|
get state() {
|
|
@@ -4211,7 +4223,7 @@ var NativeConnAdapter = class {
|
|
|
4211
4223
|
},
|
|
4212
4224
|
(newValue) => {
|
|
4213
4225
|
assertCurrentState();
|
|
4214
|
-
|
|
4226
|
+
_chunkMT3ZLU7Ucjs.assertJsonCompatValue.call(void 0, newValue);
|
|
4215
4227
|
}
|
|
4216
4228
|
);
|
|
4217
4229
|
}
|
|
@@ -4219,7 +4231,7 @@ var NativeConnAdapter = class {
|
|
|
4219
4231
|
var _a;
|
|
4220
4232
|
(_a = this.#assertCanMutateState) == null ? void 0 : _a.call(this);
|
|
4221
4233
|
const nextValue = unwrapWriteThroughProxy(value);
|
|
4222
|
-
|
|
4234
|
+
_chunkMT3ZLU7Ucjs.assertJsonCompatValue.call(void 0, nextValue);
|
|
4223
4235
|
this.#writeState(nextValue, { writeNative: true });
|
|
4224
4236
|
}
|
|
4225
4237
|
initializeState(value) {
|
|
@@ -5238,7 +5250,7 @@ var ActorContextHandleAdapter = class {
|
|
|
5238
5250
|
this.#databaseProvider = databaseProvider;
|
|
5239
5251
|
}
|
|
5240
5252
|
this.#request = request;
|
|
5241
|
-
this[
|
|
5253
|
+
this[_chunkOKLZYDQBcjs.ACTOR_CONTEXT_INTERNAL_SYMBOL] = new NativeWorkflowRuntimeAdapter(
|
|
5242
5254
|
this,
|
|
5243
5255
|
() => this.#logByInvocationScope.delete(
|
|
5244
5256
|
_nullishCoalesce(this.#runtime.currentInvocationScope(), () => ( NO_INVOCATION_SCOPE))
|
|
@@ -5266,7 +5278,7 @@ var ActorContextHandleAdapter = class {
|
|
|
5266
5278
|
}
|
|
5267
5279
|
throw databaseClientNotReadyError();
|
|
5268
5280
|
}
|
|
5269
|
-
[
|
|
5281
|
+
[_chunkOKLZYDQBcjs.RAW_STATE_SYMBOL]() {
|
|
5270
5282
|
if (!this.#stateEnabled) {
|
|
5271
5283
|
throw stateNotEnabledError();
|
|
5272
5284
|
}
|
|
@@ -5293,7 +5305,7 @@ var ActorContextHandleAdapter = class {
|
|
|
5293
5305
|
},
|
|
5294
5306
|
(newValue) => {
|
|
5295
5307
|
assertCurrentState();
|
|
5296
|
-
|
|
5308
|
+
_chunkMT3ZLU7Ucjs.assertJsonCompatValue.call(void 0, newValue);
|
|
5297
5309
|
}
|
|
5298
5310
|
);
|
|
5299
5311
|
}
|
|
@@ -5305,7 +5317,7 @@ var ActorContextHandleAdapter = class {
|
|
|
5305
5317
|
}
|
|
5306
5318
|
this.#assertCanMutateState();
|
|
5307
5319
|
const nextValue = unwrapWriteThroughProxy(value);
|
|
5308
|
-
|
|
5320
|
+
_chunkMT3ZLU7Ucjs.assertJsonCompatValue.call(void 0, nextValue);
|
|
5309
5321
|
this.#writeState(nextValue, { scheduleSave: true });
|
|
5310
5322
|
}
|
|
5311
5323
|
initializeState(value) {
|
|
@@ -5390,9 +5402,21 @@ var ActorContextHandleAdapter = class {
|
|
|
5390
5402
|
callNativeSync(() => this.#runtime.actorKey(this.#ctx))
|
|
5391
5403
|
);
|
|
5392
5404
|
}
|
|
5405
|
+
get forkChain() {
|
|
5406
|
+
return callNativeSync(
|
|
5407
|
+
() => this.#runtime.actorForkChain(this.#ctx)
|
|
5408
|
+
).map((link) => ({
|
|
5409
|
+
actorId: link.actorId,
|
|
5410
|
+
key: toActorKey(link.key),
|
|
5411
|
+
forkedAt: link.forkedAt
|
|
5412
|
+
}));
|
|
5413
|
+
}
|
|
5393
5414
|
get region() {
|
|
5394
5415
|
return callNativeSync(() => this.#runtime.actorRegion(this.#ctx));
|
|
5395
5416
|
}
|
|
5417
|
+
get namespace() {
|
|
5418
|
+
return callNativeSync(() => this.#runtime.actorNamespace(this.#ctx));
|
|
5419
|
+
}
|
|
5396
5420
|
get conns() {
|
|
5397
5421
|
if (!this.#connMap) {
|
|
5398
5422
|
this.#connMap = new NativeConnectionMap(
|
|
@@ -5519,7 +5543,7 @@ var ActorContextHandleAdapter = class {
|
|
|
5519
5543
|
log: {
|
|
5520
5544
|
debug: (obj) => logger2().debug(obj)
|
|
5521
5545
|
},
|
|
5522
|
-
nativeDatabaseProvider:
|
|
5546
|
+
nativeDatabaseProvider: _chunkYTSSP6NXcjs.registerNativeStateTransactionOpener.call(void 0,
|
|
5523
5547
|
{
|
|
5524
5548
|
open: async (requestedActorId) => {
|
|
5525
5549
|
void requestedActorId;
|
|
@@ -5542,7 +5566,7 @@ var ActorContextHandleAdapter = class {
|
|
|
5542
5566
|
return this.#db;
|
|
5543
5567
|
}
|
|
5544
5568
|
#bindDatabaseClient(client) {
|
|
5545
|
-
return
|
|
5569
|
+
return _chunkYTSSP6NXcjs.bindNativeStateTransactionContext.call(void 0, client, {
|
|
5546
5570
|
enter: async () => await this.#enterStateTransaction(),
|
|
5547
5571
|
exit: (scope) => this.#exitStateTransaction(
|
|
5548
5572
|
scope
|
|
@@ -5746,7 +5770,7 @@ var ActorContextHandleAdapter = class {
|
|
|
5746
5770
|
const trackedPromise = Promise.resolve(promise).catch((error) => {
|
|
5747
5771
|
logger2().warn({
|
|
5748
5772
|
msg: "keepAwake promise rejected",
|
|
5749
|
-
error:
|
|
5773
|
+
error: _chunkMT3ZLU7Ucjs.stringifyError.call(void 0, error)
|
|
5750
5774
|
});
|
|
5751
5775
|
}).then(() => null);
|
|
5752
5776
|
try {
|
|
@@ -6126,7 +6150,7 @@ function buildActorTracingConfig(actions, tracing) {
|
|
|
6126
6150
|
if (tracing === void 0) return void 0;
|
|
6127
6151
|
return {
|
|
6128
6152
|
sampler: tracing.sampler,
|
|
6129
|
-
actions:
|
|
6153
|
+
actions: _chunkOKLZYDQBcjs.flattenActionTraceSamplers.call(void 0, actions, tracing.actions)
|
|
6130
6154
|
};
|
|
6131
6155
|
}
|
|
6132
6156
|
function buildActorConfig(definition, registryConfig, runtimeKind) {
|
|
@@ -6167,7 +6191,7 @@ function buildActorConfig(definition, registryConfig, runtimeKind) {
|
|
|
6167
6191
|
maxOutgoingMessageSize: registryConfig.maxOutgoingMessageSize,
|
|
6168
6192
|
preloadMaxWorkflowBytes: options.preloadMaxWorkflowBytes,
|
|
6169
6193
|
preloadMaxConnectionsBytes: options.preloadMaxConnectionsBytes,
|
|
6170
|
-
actions: Object.keys(
|
|
6194
|
+
actions: Object.keys(_chunkOKLZYDQBcjs.flattenActionHandlers.call(void 0, config.actions)).sort().map((name) => ({ name })),
|
|
6171
6195
|
inspectorTabs: buildInspectorTabs(config.inspector, runtimeKind)
|
|
6172
6196
|
};
|
|
6173
6197
|
}
|
|
@@ -6243,10 +6267,10 @@ function validateInspectorTabSource(tabId, resolved) {
|
|
|
6243
6267
|
function buildNativeFactory(runtime, registryConfig, definition) {
|
|
6244
6268
|
var _a;
|
|
6245
6269
|
const config = definition.config;
|
|
6246
|
-
const databaseProvider = _nullishCoalesce(config.db, () => (
|
|
6247
|
-
const actionHandlers =
|
|
6270
|
+
const databaseProvider = _nullishCoalesce(config.db, () => ( _chunkYTSSP6NXcjs.db.call(void 0, )));
|
|
6271
|
+
const actionHandlers = _chunkOKLZYDQBcjs.flattenActionHandlers.call(void 0, config.actions);
|
|
6248
6272
|
const schemaConfig = {
|
|
6249
|
-
actionInputSchemas:
|
|
6273
|
+
actionInputSchemas: _chunkOKLZYDQBcjs.flattenActionInputSchemas.call(void 0,
|
|
6250
6274
|
config.actions,
|
|
6251
6275
|
config.actionInputSchemas
|
|
6252
6276
|
),
|
|
@@ -6254,9 +6278,9 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
6254
6278
|
events: config.events,
|
|
6255
6279
|
queues: config.queues
|
|
6256
6280
|
};
|
|
6257
|
-
const createClient = (ctx) =>
|
|
6258
|
-
new (0,
|
|
6259
|
-
|
|
6281
|
+
const createClient = (ctx) => _chunkMUCEIMJWcjs.createClientWithDriver.call(void 0,
|
|
6282
|
+
new (0, _chunkMUCEIMJWcjs.RemoteEngineControlClient)(
|
|
6283
|
+
_chunkMUCEIMJWcjs.convertRegistryConfigToClientConfig.call(void 0, registryConfig)
|
|
6260
6284
|
),
|
|
6261
6285
|
{
|
|
6262
6286
|
encoding: "bare",
|
|
@@ -6268,13 +6292,13 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
6268
6292
|
)
|
|
6269
6293
|
}
|
|
6270
6294
|
);
|
|
6271
|
-
const run =
|
|
6272
|
-
const runHandlerCoordinator =
|
|
6295
|
+
const run = _chunkOKLZYDQBcjs.getRunFunction.call(void 0, config.run);
|
|
6296
|
+
const runHandlerCoordinator = _chunkOKLZYDQBcjs.getRunInspectorKind.call(void 0, config.run) === "workflow" ? new RunHandlerCoordinator(config.run) : void 0;
|
|
6273
6297
|
const getNativeWorkflowInspector = (ctx) => {
|
|
6274
6298
|
var _a2, _b;
|
|
6275
6299
|
const actorId = callNativeSync(() => runtime.actorId(ctx));
|
|
6276
6300
|
const restart = () => callNativeSync(() => runtime.actorRestartRunHandler(ctx));
|
|
6277
|
-
return _nullishCoalesce(((_a2 = runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.getInspector(actorId, restart)) == null ? void 0 : _a2.workflow), () => ( ((_b =
|
|
6301
|
+
return _nullishCoalesce(((_a2 = runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.getInspector(actorId, restart)) == null ? void 0 : _a2.workflow), () => ( ((_b = _chunkOKLZYDQBcjs.getRunInspectorConfig.call(void 0, config.run, actorId)) == null ? void 0 : _b.workflow)));
|
|
6278
6302
|
};
|
|
6279
6303
|
const onStateChange = typeof config.onStateChange === "function" ? (actorCtx, nextState) => {
|
|
6280
6304
|
config.onStateChange(actorCtx, nextState);
|
|
@@ -6448,7 +6472,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
6448
6472
|
400
|
|
6449
6473
|
);
|
|
6450
6474
|
}
|
|
6451
|
-
const cbor =
|
|
6475
|
+
const cbor = _chunkMT3ZLU7Ucjs.encodeCborCompat.call(void 0,
|
|
6452
6476
|
_nullishCoalesce(body.body, () => ( null))
|
|
6453
6477
|
);
|
|
6454
6478
|
const message = await runtime.actorQueueSend(ctx, name, cbor);
|
|
@@ -6758,6 +6782,25 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
6758
6782
|
}
|
|
6759
6783
|
}
|
|
6760
6784
|
) : void 0,
|
|
6785
|
+
onFork: typeof config.onFork === "function" ? wrapNativeCallback(
|
|
6786
|
+
async (error, payload) => {
|
|
6787
|
+
const { ctx, fork } = unwrapTsfnPayload(
|
|
6788
|
+
error,
|
|
6789
|
+
payload
|
|
6790
|
+
);
|
|
6791
|
+
const actorCtx = makeActorCtx(ctx);
|
|
6792
|
+
try {
|
|
6793
|
+
await config.onFork(actorCtx, {
|
|
6794
|
+
actorId: fork.actorId,
|
|
6795
|
+
key: toActorKey(fork.key),
|
|
6796
|
+
forkedAt: fork.forkedAt,
|
|
6797
|
+
input: decodeValue(fork.input)
|
|
6798
|
+
});
|
|
6799
|
+
} finally {
|
|
6800
|
+
await actorCtx.dispose();
|
|
6801
|
+
}
|
|
6802
|
+
}
|
|
6803
|
+
) : void 0,
|
|
6761
6804
|
onWake: typeof config.onWake === "function" ? wrapNativeCallback(
|
|
6762
6805
|
async (error, payload) => {
|
|
6763
6806
|
const { ctx } = unwrapTsfnPayload(error, payload);
|
|
@@ -6816,7 +6859,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
6816
6859
|
);
|
|
6817
6860
|
} finally {
|
|
6818
6861
|
runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.destroy(actorId);
|
|
6819
|
-
|
|
6862
|
+
_chunkOKLZYDQBcjs.disposeRunInspector.call(void 0, config.run, actorId);
|
|
6820
6863
|
await actorCtx.dispose();
|
|
6821
6864
|
}
|
|
6822
6865
|
}
|
|
@@ -6828,7 +6871,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
6828
6871
|
const actorCtx = makeActorCtx(ctx);
|
|
6829
6872
|
const actorId = callNativeSync(() => runtime.actorId(ctx));
|
|
6830
6873
|
runHandlerCoordinator == null ? void 0 : runHandlerCoordinator.destroy(actorId);
|
|
6831
|
-
|
|
6874
|
+
_chunkOKLZYDQBcjs.disposeRunInspector.call(void 0, config.run, actorId);
|
|
6832
6875
|
try {
|
|
6833
6876
|
if (typeof config.onDestroy === "function") {
|
|
6834
6877
|
await config.onDestroy(actorCtx);
|
|
@@ -7045,7 +7088,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
7045
7088
|
...request,
|
|
7046
7089
|
abortController: requestAbortController
|
|
7047
7090
|
});
|
|
7048
|
-
const rawConnParams = handlerRequest.headers.get(
|
|
7091
|
+
const rawConnParams = handlerRequest.headers.get(_chunkMUCEIMJWcjs.HEADER_CONN_PARAMS);
|
|
7049
7092
|
let requestCtx;
|
|
7050
7093
|
let conn;
|
|
7051
7094
|
let removeRequestAbortListener;
|
|
@@ -7102,7 +7145,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
7102
7145
|
requestCtx,
|
|
7103
7146
|
handlerRequest
|
|
7104
7147
|
);
|
|
7105
|
-
if (!
|
|
7148
|
+
if (!_chunkMUCEIMJWcjs.isResponseLike.call(void 0, response)) {
|
|
7106
7149
|
throw new Error(
|
|
7107
7150
|
"onRequest handler must return a Response"
|
|
7108
7151
|
);
|
|
@@ -7192,15 +7235,15 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
7192
7235
|
}
|
|
7193
7236
|
);
|
|
7194
7237
|
})(),
|
|
7195
|
-
getWorkflowHistory:
|
|
7238
|
+
getWorkflowHistory: _chunkOKLZYDQBcjs.hasRunInspectorConfig.call(void 0, config.run) ? wrapNativeCallback(
|
|
7196
7239
|
async (error, payload) => {
|
|
7197
7240
|
var _a2;
|
|
7198
7241
|
const { ctx } = unwrapTsfnPayload(error, payload);
|
|
7199
7242
|
const history = (_a2 = getNativeWorkflowInspector(ctx)) == null ? void 0 : _a2.getHistory();
|
|
7200
|
-
return history == null ? void 0 :
|
|
7243
|
+
return history == null ? void 0 : _chunkMT3ZLU7Ucjs.toUint8Array.call(void 0, history);
|
|
7201
7244
|
}
|
|
7202
7245
|
) : void 0,
|
|
7203
|
-
replayWorkflow:
|
|
7246
|
+
replayWorkflow: _chunkOKLZYDQBcjs.hasRunInspectorConfig.call(void 0, config.run) ? wrapNativeCallback(
|
|
7204
7247
|
async (error, payload) => {
|
|
7205
7248
|
const { ctx, entryId } = unwrapTsfnPayload(
|
|
7206
7249
|
error,
|
|
@@ -7211,7 +7254,7 @@ function buildNativeFactory(runtime, registryConfig, definition) {
|
|
|
7211
7254
|
return void 0;
|
|
7212
7255
|
}
|
|
7213
7256
|
const history = await _asyncNullishCoalesce(await workflowInspector.replayFromStep(entryId), async () => ( null));
|
|
7214
|
-
return history == null ? void 0 :
|
|
7257
|
+
return history == null ? void 0 : _chunkMT3ZLU7Ucjs.toUint8Array.call(void 0, history);
|
|
7215
7258
|
}
|
|
7216
7259
|
) : void 0,
|
|
7217
7260
|
actions: Object.fromEntries(
|
|
@@ -7353,7 +7396,7 @@ async function buildServeConfig(config, resolveNativeBinaries = true) {
|
|
|
7353
7396
|
startServices: resolveNativeBinaries && config.startServices,
|
|
7354
7397
|
handleInspectorHttpInRuntime: true,
|
|
7355
7398
|
serverlessBasePath: config.serverless.basePath,
|
|
7356
|
-
serverlessPackageVersion:
|
|
7399
|
+
serverlessPackageVersion: _chunkMT3ZLU7Ucjs.VERSION,
|
|
7357
7400
|
serverlessClientEndpoint: config.publicEndpoint,
|
|
7358
7401
|
serverlessClientNamespace: config.publicNamespace,
|
|
7359
7402
|
serverlessClientToken: config.publicToken,
|
|
@@ -7367,12 +7410,12 @@ async function buildServeConfig(config, resolveNativeBinaries = true) {
|
|
|
7367
7410
|
} catch (error) {
|
|
7368
7411
|
logger2().warn({
|
|
7369
7412
|
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",
|
|
7370
|
-
error:
|
|
7413
|
+
error: _chunkMT3ZLU7Ucjs.stringifyError.call(void 0, error)
|
|
7371
7414
|
});
|
|
7372
7415
|
}
|
|
7373
7416
|
}
|
|
7374
7417
|
if (resolveNativeBinaries && config.startServices) {
|
|
7375
|
-
const servicesBinary =
|
|
7418
|
+
const servicesBinary = _chunkMT3ZLU7Ucjs.getEnvUniversal.call(void 0, "RIVET_SERVICES_BINARY");
|
|
7376
7419
|
if (servicesBinary) {
|
|
7377
7420
|
serveConfig.servicesBinaryPath = servicesBinary;
|
|
7378
7421
|
} else {
|
|
@@ -7387,13 +7430,13 @@ async function buildServeConfig(config, resolveNativeBinaries = true) {
|
|
|
7387
7430
|
serveConfig.engineHost = config.engineHost;
|
|
7388
7431
|
serveConfig.enginePort = config.enginePort;
|
|
7389
7432
|
if ((_a = config.test) == null ? void 0 : _a.enabled) {
|
|
7390
|
-
serveConfig.inspectorTestToken = _nullishCoalesce(
|
|
7433
|
+
serveConfig.inspectorTestToken = _nullishCoalesce(_chunkMT3ZLU7Ucjs.getEnvUniversal.call(void 0, "_RIVET_TEST_INSPECTOR_TOKEN"), () => ( "token"));
|
|
7391
7434
|
}
|
|
7392
7435
|
return serveConfig;
|
|
7393
7436
|
}
|
|
7394
7437
|
async function buildRegistryWithRuntime(config, runtime) {
|
|
7395
7438
|
var _a;
|
|
7396
|
-
if (((_a = config.test) == null ? void 0 : _a.enabled) &&
|
|
7439
|
+
if (((_a = config.test) == null ? void 0 : _a.enabled) && _chunkMT3ZLU7Ucjs.getEnvUniversal.call(void 0, "_RIVET_TEST_INSPECTOR_TOKEN") === void 0) {
|
|
7397
7440
|
trySetProcessEnv("_RIVET_TEST_INSPECTOR_TOKEN", "token");
|
|
7398
7441
|
}
|
|
7399
7442
|
if (runtime.kind === "napi") {
|
|
@@ -7466,7 +7509,7 @@ function createApplicationFetch(application, runtime) {
|
|
|
7466
7509
|
signal: abortController.signal
|
|
7467
7510
|
})
|
|
7468
7511
|
);
|
|
7469
|
-
if (!
|
|
7512
|
+
if (!_chunkMUCEIMJWcjs.isResponseLike.call(void 0, response)) {
|
|
7470
7513
|
throw new TypeError(
|
|
7471
7514
|
"registry.listen() application fetch must return a Response"
|
|
7472
7515
|
);
|
|
@@ -7521,7 +7564,7 @@ var Registry = class {
|
|
|
7521
7564
|
var _a;
|
|
7522
7565
|
this.#config = config;
|
|
7523
7566
|
if ((_a = config.logging) == null ? void 0 : _a.baseLogger) {
|
|
7524
|
-
|
|
7567
|
+
_chunkMT3ZLU7Ucjs.configureBaseLogger.call(void 0, config.logging.baseLogger);
|
|
7525
7568
|
}
|
|
7526
7569
|
this.#buildConfiguredRegistry = _nullishCoalesce((deps == null ? void 0 : deps.buildConfiguredRegistry), () => ( buildConfiguredRegistry));
|
|
7527
7570
|
this.routes = {
|
|
@@ -7753,10 +7796,10 @@ var Registry = class {
|
|
|
7753
7796
|
if (!opts.application) {
|
|
7754
7797
|
rejectServerless();
|
|
7755
7798
|
}
|
|
7756
|
-
const port = _nullishCoalesce(_nullishCoalesce(opts.port, () => (
|
|
7757
|
-
const publicDir = _nullishCoalesce(opts.publicDir, () => (
|
|
7799
|
+
const port = _nullishCoalesce(_nullishCoalesce(opts.port, () => ( _chunkMT3ZLU7Ucjs.parsePortEnv.call(void 0, process.env.RIVET_PORT))), () => ( 3e3));
|
|
7800
|
+
const publicDir = _nullishCoalesce(opts.publicDir, () => ( _chunkMT3ZLU7Ucjs.getRivetkitPublicDir.call(void 0, )));
|
|
7758
7801
|
const config = this.parseConfig();
|
|
7759
|
-
if (opts.application &&
|
|
7802
|
+
if (opts.application && _chunkMT3ZLU7Ucjs.getRivetkitRuntimeMode.call(void 0, ) !== "serverless") {
|
|
7760
7803
|
if (config.runtime === "wasm") {
|
|
7761
7804
|
throw new Error(
|
|
7762
7805
|
"registry.listen() requires the native runtime; use an application-owned HTTP server with WebAssembly"
|
|
@@ -7832,7 +7875,7 @@ var Registry = class {
|
|
|
7832
7875
|
return jsonRouteResponse(503, {
|
|
7833
7876
|
status: "not_started",
|
|
7834
7877
|
runtime: "rivetkit",
|
|
7835
|
-
version:
|
|
7878
|
+
version: _chunkMT3ZLU7Ucjs.VERSION
|
|
7836
7879
|
});
|
|
7837
7880
|
}
|
|
7838
7881
|
const { runtime, registry } = configured;
|
|
@@ -7840,7 +7883,7 @@ var Registry = class {
|
|
|
7840
7883
|
return jsonRouteResponse(501, {
|
|
7841
7884
|
status: "unsupported",
|
|
7842
7885
|
runtime: "rivetkit",
|
|
7843
|
-
version:
|
|
7886
|
+
version: _chunkMT3ZLU7Ucjs.VERSION
|
|
7844
7887
|
});
|
|
7845
7888
|
}
|
|
7846
7889
|
const response = await runtime.registryHealth(registry);
|
|
@@ -7915,14 +7958,14 @@ var Registry = class {
|
|
|
7915
7958
|
var _a;
|
|
7916
7959
|
if (!this.#runtimeServePromise) {
|
|
7917
7960
|
const configuredEnvoyVersion = (_a = this.#config.node) == null ? void 0 : _a.version;
|
|
7918
|
-
const envoyVersionSource = configuredEnvoyVersion !== void 0 ? "config" :
|
|
7961
|
+
const envoyVersionSource = configuredEnvoyVersion !== void 0 ? "config" : _chunkMT3ZLU7Ucjs.getRivetEnvoyVersion.call(void 0, ) !== void 0 ? "environment" : "default";
|
|
7919
7962
|
logger2().info({
|
|
7920
7963
|
msg: "starting rivetkit envoy",
|
|
7921
|
-
rivetkitVersion:
|
|
7964
|
+
rivetkitVersion: _chunkMT3ZLU7Ucjs.VERSION,
|
|
7922
7965
|
envoyVersion: config.node.version,
|
|
7923
7966
|
envoyVersionSource
|
|
7924
7967
|
});
|
|
7925
|
-
if (envoyVersionSource === "default" &&
|
|
7968
|
+
if (envoyVersionSource === "default" && _chunkMT3ZLU7Ucjs.getNodeEnv.call(void 0, ) === "production") {
|
|
7926
7969
|
logger2().error({
|
|
7927
7970
|
msg: "node version defaulted because neither config.node.version nor RIVET_NODE_VERSION is set; actors will not drain automatically across deploys. See https://rivet.dev/docs/actors/versions",
|
|
7928
7971
|
envoyVersion: config.node.version,
|
|
@@ -8026,7 +8069,7 @@ var Registry = class {
|
|
|
8026
8069
|
const modeAPromise = this.#runtimeServeConfiguredPromise;
|
|
8027
8070
|
const modeBPromise = this.#runtimeServerlessPromise;
|
|
8028
8071
|
const runtimes = /* @__PURE__ */ new Set();
|
|
8029
|
-
const localDevSignal = signalDriven &&
|
|
8072
|
+
const localDevSignal = signalDriven && _chunkMT3ZLU7Ucjs.getNodeEnv.call(void 0, ) !== "production" && config.engineSpawn && config.endpoint !== void 0 && _chunkMUCEIMJWcjs.isLocalEngineEndpoint.call(void 0, config.endpoint);
|
|
8030
8073
|
let gracePeriodMs = (_a = config.shutdown) == null ? void 0 : _a.gracePeriodMs;
|
|
8031
8074
|
if (gracePeriodMs === void 0) {
|
|
8032
8075
|
gracePeriodMs = localDevSignal ? LOCAL_DEV_SHUTDOWN_GRACE_PERIOD_MS : await _asyncNullishCoalesce(await this.#actorStopThresholdMs(
|
|
@@ -8138,7 +8181,7 @@ var Registry = class {
|
|
|
8138
8181
|
}
|
|
8139
8182
|
if (this.#runtimeReadyPromise) return this.#runtimeReadyPromise;
|
|
8140
8183
|
try {
|
|
8141
|
-
if (
|
|
8184
|
+
if (_chunkMT3ZLU7Ucjs.getRivetkitRuntimeMode.call(void 0, ) === "serverless") {
|
|
8142
8185
|
return Promise.reject(
|
|
8143
8186
|
new Error(
|
|
8144
8187
|
"registry.startAndWait() requires envoy runtime mode; serverless registries become ready per request"
|
|
@@ -8162,7 +8205,7 @@ var Registry = class {
|
|
|
8162
8205
|
if (!configuredRegistryPromise || !serveLifecyclePromise) {
|
|
8163
8206
|
throw new Error("registry envoy startup did not initialize");
|
|
8164
8207
|
}
|
|
8165
|
-
const readyTimeoutMs = config.engineSpawn && config.endpoint !== void 0 &&
|
|
8208
|
+
const readyTimeoutMs = config.engineSpawn && config.endpoint !== void 0 && _chunkMUCEIMJWcjs.isLocalEngineEndpoint.call(void 0, config.endpoint) ? LOCAL_ENGINE_READY_TIMEOUT_MS : REGISTRY_READY_TIMEOUT_MS;
|
|
8166
8209
|
let timeout;
|
|
8167
8210
|
const timeoutPromise = new Promise((_resolve, reject) => {
|
|
8168
8211
|
var _a;
|
|
@@ -8212,8 +8255,8 @@ var Registry = class {
|
|
|
8212
8255
|
* ```
|
|
8213
8256
|
*/
|
|
8214
8257
|
start() {
|
|
8215
|
-
if (
|
|
8216
|
-
const publicDir = _nullishCoalesce(
|
|
8258
|
+
if (_chunkMT3ZLU7Ucjs.getRivetkitRuntimeMode.call(void 0, ) === "serverless") {
|
|
8259
|
+
const publicDir = _nullishCoalesce(_chunkMT3ZLU7Ucjs.getRivetkitPublicDir.call(void 0, ), () => ( "/public"));
|
|
8217
8260
|
this.listen({ publicDir }).catch((error) => {
|
|
8218
8261
|
logger2().error({ error }, "auto-listen failed; exiting");
|
|
8219
8262
|
if (typeof process !== "undefined" && typeof process.exit === "function") {
|
|
@@ -8329,13 +8372,13 @@ var Registry = class {
|
|
|
8329
8372
|
};
|
|
8330
8373
|
console.log();
|
|
8331
8374
|
console.log(
|
|
8332
|
-
` RivetKit ${
|
|
8375
|
+
` RivetKit ${_chunkMT3ZLU7Ucjs.VERSION} (Engine - ${kind === "serverless" ? "Serverless" : "Serverful"})`
|
|
8333
8376
|
);
|
|
8334
8377
|
if (config.namespace !== "default") {
|
|
8335
8378
|
logLine("Namespace", config.namespace);
|
|
8336
8379
|
}
|
|
8337
8380
|
if (config.endpoint) {
|
|
8338
|
-
const endpointType = config.startEngine ||
|
|
8381
|
+
const endpointType = config.startEngine || _chunkMUCEIMJWcjs.isLocalEngineEndpoint.call(void 0, config.endpoint) ? "local native" : "remote";
|
|
8339
8382
|
logLine("Endpoint", `${config.endpoint} (${endpointType})`);
|
|
8340
8383
|
}
|
|
8341
8384
|
if (kind === "serverless" && config.publicEndpoint) {
|
|
@@ -8405,5 +8448,5 @@ function setup(input) {
|
|
|
8405
8448
|
|
|
8406
8449
|
|
|
8407
8450
|
|
|
8408
|
-
exports.ALLOWED_PUBLIC_HEADERS =
|
|
8451
|
+
exports.ALLOWED_PUBLIC_HEADERS = _chunkMUCEIMJWcjs.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 = _chunkMUCEIMJWcjs.createClientWithDriver; exports.defineRunHandler = _chunkOKLZYDQBcjs.defineRunHandler; exports.event = event; exports.isStaticActorDefinition = isStaticActorDefinition; exports.isStaticActorInstance = isStaticActorInstance; exports.lookupInRegistry = lookupInRegistry; exports.noopNext = _chunkMT3ZLU7Ucjs.noopNext; exports.queue = queue; exports.setup = setup; exports.toUint8Array = _chunkMT3ZLU7Ucjs.toUint8Array;
|
|
8409
8452
|
//# sourceMappingURL=mod.cjs.map
|