@cosmicdrift/kumiko-server-runtime 0.387.0 → 0.388.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/boot/boot-crypto.js +3 -3
- package/dist/boot/shared-boot-steps.d.ts +43 -0
- package/dist/boot/shared-boot-steps.js +154 -0
- package/dist/boot/wait-for-database.d.ts +3 -0
- package/dist/boot/wait-for-database.js +3 -3
- package/dist/boot/worker-boot-core.js +18 -38
- package/dist/boot-options/billing-option.d.ts +18 -9
- package/dist/boot-options/billing-option.js +44 -18
- package/dist/boot-options/file-storage-option.js +6 -6
- package/dist/boot-options/option-env-schema.js +11 -2
- package/dist/boot-options/resolve-boot-options.js +9 -3
- package/dist/boot-options/stack-boot-requirements.js +1 -1
- package/dist/csp-hashes.js +1 -1
- package/dist/fatal-error-handlers.js +7 -0
- package/dist/require-env.d.ts +2 -0
- package/dist/require-env.js +21 -0
- package/dist/run-bootstrap.d.ts +1 -1
- package/dist/run-bootstrap.js +1 -1
- package/dist/run-prod-app-auth.d.ts +17 -0
- package/dist/run-prod-app-auth.js +83 -0
- package/dist/run-prod-app-boot-context.js +7 -3
- package/dist/run-prod-app-config.d.ts +36 -0
- package/dist/run-prod-app-config.js +169 -0
- package/dist/run-prod-app-connections.d.ts +16 -0
- package/dist/run-prod-app-connections.js +55 -0
- package/dist/run-prod-app-entrypoint.d.ts +14 -0
- package/dist/run-prod-app-entrypoint.js +147 -0
- package/dist/run-prod-app-handle.d.ts +20 -0
- package/dist/run-prod-app-handle.js +104 -0
- package/dist/run-prod-app-request-context.d.ts +15 -0
- package/dist/run-prod-app-request-context.js +103 -0
- package/dist/run-prod-app-seeds.d.ts +13 -0
- package/dist/run-prod-app-seeds.js +86 -0
- package/dist/run-prod-app.d.ts +20 -18
- package/dist/run-prod-app.js +46 -726
- package/dist/run-worker-app.d.ts +1 -1
- package/package.json +15 -7
- package/src/changes.json +25 -0
package/dist/run-worker-app.d.ts
CHANGED
|
@@ -90,7 +90,7 @@ export type RunWorkerAppOptions = {
|
|
|
90
90
|
readonly fileStorage?: FileStorageBootOption;
|
|
91
91
|
/** Same as RunProdAppOptions["kmsMode"]; cannot be combined with `kms` / `blindIndexKey` / `allowPlaintextPii`. */
|
|
92
92
|
readonly kmsMode?: KmsMode;
|
|
93
|
-
/** Same as RunProdAppOptions["billing"]: mounts subscription
|
|
93
|
+
/** Same as RunProdAppOptions["billing"]: mounts the configured subscription providers so the registry matches the API. The webhook route belongs to the API process. */
|
|
94
94
|
readonly billing?: BillingBootOption;
|
|
95
95
|
/** Same as RunProdAppOptions["featureToggles"]: mounts feature-toggles and layers the operator switches over the tier resolver. */
|
|
96
96
|
readonly featureToggles?: boolean;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cosmicdrift/kumiko-server-runtime",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.388.0",
|
|
4
4
|
"description": "Production server-boot runtime for Kumiko apps: connections, schema-drift-gate, seeds, lifecycle, graceful shutdown. Symmetric to kumiko-dev-server's runDevApp, without dev/scaffold tooling.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Marc Frost <marc@cosmicdriftgamestudio.com>",
|
|
@@ -50,6 +50,10 @@
|
|
|
50
50
|
"types": "./dist/boot/apply-boot-seeds.d.ts",
|
|
51
51
|
"default": "./dist/boot/apply-boot-seeds.js"
|
|
52
52
|
},
|
|
53
|
+
"./boot/shared-boot-steps": {
|
|
54
|
+
"types": "./dist/boot/shared-boot-steps.d.ts",
|
|
55
|
+
"default": "./dist/boot/shared-boot-steps.js"
|
|
56
|
+
},
|
|
53
57
|
"./boot/boot-crypto": {
|
|
54
58
|
"types": "./dist/boot/boot-crypto.d.ts",
|
|
55
59
|
"default": "./dist/boot/boot-crypto.js"
|
|
@@ -88,18 +92,18 @@
|
|
|
88
92
|
}
|
|
89
93
|
},
|
|
90
94
|
"dependencies": {
|
|
91
|
-
"@cosmicdrift/kumiko-bundled-features": "0.
|
|
92
|
-
"@cosmicdrift/kumiko-framework": "0.
|
|
93
|
-
"@cosmicdrift/kumiko-renderer": "0.
|
|
94
|
-
"@cosmicdrift/kumiko-renderer-mail-html": "0.
|
|
95
|
-
"@cosmicdrift/kumiko-types": "0.
|
|
95
|
+
"@cosmicdrift/kumiko-bundled-features": "0.388.0",
|
|
96
|
+
"@cosmicdrift/kumiko-framework": "0.388.0",
|
|
97
|
+
"@cosmicdrift/kumiko-renderer": "0.388.0",
|
|
98
|
+
"@cosmicdrift/kumiko-renderer-mail-html": "0.388.0",
|
|
99
|
+
"@cosmicdrift/kumiko-types": "0.388.0",
|
|
96
100
|
"bun-types": "^1.3.13",
|
|
97
101
|
"ioredis": "^5.10.1",
|
|
98
102
|
"temporal-polyfill": "^0.3.2",
|
|
99
103
|
"zod": "^4.4.3"
|
|
100
104
|
},
|
|
101
105
|
"devDependencies": {
|
|
102
|
-
"@cosmicdrift/kumiko-testing": "0.
|
|
106
|
+
"@cosmicdrift/kumiko-testing": "0.388.0"
|
|
103
107
|
},
|
|
104
108
|
"publishConfig": {
|
|
105
109
|
"registry": "https://registry.npmjs.org",
|
|
@@ -137,6 +141,10 @@
|
|
|
137
141
|
"types": "./dist/boot/apply-boot-seeds.d.ts",
|
|
138
142
|
"default": "./dist/boot/apply-boot-seeds.js"
|
|
139
143
|
},
|
|
144
|
+
"./boot/shared-boot-steps": {
|
|
145
|
+
"types": "./dist/boot/shared-boot-steps.d.ts",
|
|
146
|
+
"default": "./dist/boot/shared-boot-steps.js"
|
|
147
|
+
},
|
|
140
148
|
"./boot/boot-crypto": {
|
|
141
149
|
"types": "./dist/boot/boot-crypto.d.ts",
|
|
142
150
|
"default": "./dist/boot/boot-crypto.js"
|
package/src/changes.json
CHANGED
|
@@ -1,4 +1,29 @@
|
|
|
1
1
|
[
|
|
2
|
+
{
|
|
3
|
+
"version": "0.388.0",
|
|
4
|
+
"type": "improvement",
|
|
5
|
+
"title": "runProdApp split into boot phases, boot steps shared with dev and worker",
|
|
6
|
+
"detail": "runProdApp() keeps its signature and behavior. Config resolution, feature composition, dependency connection, request context, auth wiring, entrypoint, seeds and the returned handle now live in run-prod-app-*.ts files next to run-prod-app.ts. Steps that prod, dev and the worker ran as copies (env defaults, feature composition, boot validation, the auth-mfa switch-tenant gate, the tier and feature-toggle resolver, standard boot seeds, shared auth routes, the KMS health gate and the database pools) live once in the new subpath @cosmicdrift/kumiko-server-runtime/boot/shared-boot-steps. requireEnv is still exported from run-prod-app under the same name."
|
|
7
|
+
},
|
|
8
|
+
{
|
|
9
|
+
"version": "0.388.0",
|
|
10
|
+
"type": "fix",
|
|
11
|
+
"title": "runProdApp releases connections when the boot fails",
|
|
12
|
+
"detail": "A failing boot closes the database pools, the Redis client and the KMS adapter it already opened. The KMS health wait logs \"KMS not reachable\" instead of \"database not reachable\"."
|
|
13
|
+
},
|
|
14
|
+
{
|
|
15
|
+
"version": "0.388.0",
|
|
16
|
+
"type": "fix",
|
|
17
|
+
"title": "Boot validation and shutdown hardening",
|
|
18
|
+
"detail": "The KMS and app database waits share one deadline so a boot never outlasts the liveness window. An app-supplied master key provider is checked at boot, also in a dry run. Additional fileStorage providers get the same production and S3 checks as the default one, and their env keys are validated. appOverrides without auth or delivery feature abort instead of being dropped. A fatal shutdown keeps its listeners installed, and inline script hashing handles a \">\" inside quoted attributes."
|
|
19
|
+
},
|
|
20
|
+
{
|
|
21
|
+
"version": "0.388.0",
|
|
22
|
+
"type": "breaking",
|
|
23
|
+
"title": "billing boot option takes stripe and/or dodo",
|
|
24
|
+
"detail": "billing.stripe is now optional and billing.dodo is new (priceToTier, oneOffPriceIds). At least one is required. resolveBillingOption returns features (an array) instead of feature, and one webhook route serves every provider on stripe.webhookPath or SUBSCRIPTION_WEBHOOK_PATH. DODO_PAYMENTS_API_KEY and DODO_PAYMENTS_WEBHOOK_KEY are the env bridge.",
|
|
25
|
+
"migration": "Callers of resolveBillingOption use billing.features instead of billing.feature."
|
|
26
|
+
},
|
|
2
27
|
{
|
|
3
28
|
"version": "0.385.0",
|
|
4
29
|
"type": "improvement",
|