@spacefast/common 0.0.23 → 0.0.24
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/config/domains.d.ts +1 -1
- package/dist/config/domains.js +1 -0
- package/dist/config/index.d.ts +0 -1
- package/dist/config/index.js +0 -1
- package/dist/contracts/abuse.d.ts +2 -0
- package/dist/contracts/abuse.js +12 -0
- package/dist/contracts/access.d.ts +121 -9
- package/dist/contracts/access.js +73 -9
- package/dist/contracts/activity.d.ts +1 -1
- package/dist/contracts/activity.js +0 -9
- package/dist/contracts/api-keys.d.ts +21 -21
- package/dist/contracts/beta.js +1 -1
- package/dist/contracts/billing.d.ts +1 -34
- package/dist/contracts/billing.js +4 -53
- package/dist/contracts/builds.d.ts +8 -8
- package/dist/contracts/builds.js +10 -3
- package/dist/contracts/cli.d.ts +10 -0
- package/dist/contracts/cli.js +10 -0
- package/dist/contracts/collab-public.d.ts +63 -0
- package/dist/contracts/collab-public.js +46 -0
- package/dist/contracts/comments.d.ts +283 -54
- package/dist/contracts/comments.js +173 -52
- package/dist/contracts/common.d.ts +3 -3
- package/dist/contracts/device-auth.d.ts +6 -6
- package/dist/contracts/device-auth.js +1 -1
- package/dist/contracts/docs.d.ts +5 -5
- package/dist/contracts/domains.d.ts +36 -36
- package/dist/contracts/enums.d.ts +33 -30
- package/dist/contracts/enums.js +52 -38
- package/dist/contracts/error-code-meta.d.ts +37 -126
- package/dist/contracts/error-code-meta.js +12 -41
- package/dist/contracts/error-codes.d.ts +1 -1
- package/dist/contracts/error-codes.js +10 -32
- package/dist/contracts/execution.d.ts +35 -57
- package/dist/contracts/execution.js +41 -40
- package/dist/contracts/feature-lifecycle-core.d.ts +0 -6
- package/dist/contracts/feature-lifecycle-core.js +2 -31
- package/dist/contracts/feature-lifecycle.d.ts +8 -38
- package/dist/contracts/feature-lifecycle.js +16 -48
- package/dist/contracts/features.d.ts +15 -13
- package/dist/contracts/features.js +39 -38
- package/dist/contracts/functions.d.ts +97 -70
- package/dist/contracts/functions.js +101 -34
- package/dist/contracts/git.d.ts +1 -1
- package/dist/contracts/grants.d.ts +7 -3
- package/dist/contracts/grants.js +18 -9
- package/dist/contracts/internal.d.ts +14 -1
- package/dist/contracts/internal.js +17 -7
- package/dist/contracts/oauth-resources.d.ts +4 -3
- package/dist/contracts/oauth-resources.js +12 -3
- package/dist/contracts/operations.d.ts +90 -5
- package/dist/contracts/operations.js +75 -1
- package/dist/contracts/pages.d.ts +6 -1
- package/dist/contracts/pages.js +24 -1
- package/dist/contracts/plan-policy.d.ts +1 -3
- package/dist/contracts/plan-policy.js +1 -2
- package/dist/contracts/platform.d.ts +61 -148
- package/dist/contracts/platform.js +70 -126
- package/dist/contracts/publish-archive.d.ts +498 -0
- package/dist/contracts/publish-archive.js +25 -0
- package/dist/contracts/resources.d.ts +12 -24
- package/dist/contracts/resources.js +32 -12
- package/dist/contracts/runtime-api.d.ts +369 -175
- package/dist/contracts/runtime-api.js +372 -348
- package/dist/contracts/runtime-app.d.ts +127 -120
- package/dist/contracts/runtime-app.js +19 -10
- package/dist/contracts/runtime-db.d.ts +1 -1
- package/dist/contracts/runtime-services.d.ts +219 -0
- package/dist/contracts/runtime-services.js +437 -0
- package/dist/contracts/runtime-storage.d.ts +45 -32
- package/dist/contracts/runtime-storage.js +30 -8
- package/dist/contracts/space-config.d.ts +10 -16
- package/dist/contracts/space-config.js +14 -10
- package/dist/contracts/spaces.d.ts +241 -436
- package/dist/contracts/spaces.js +128 -145
- package/dist/contracts/superadmin-activity.d.ts +57 -4
- package/dist/contracts/superadmin-activity.js +48 -2
- package/dist/contracts/superadmin-search.d.ts +126 -0
- package/dist/contracts/superadmin-search.js +61 -0
- package/dist/contracts/superadmin-spaces.d.ts +358 -89
- package/dist/contracts/superadmin-spaces.js +97 -24
- package/dist/contracts/superadmin-teams.d.ts +28 -10
- package/dist/contracts/superadmin-teams.js +5 -8
- package/dist/contracts/superadmin.d.ts +0 -32
- package/dist/contracts/superadmin.js +3 -11
- package/dist/contracts/tags.d.ts +9 -9
- package/dist/contracts/teams.d.ts +38 -0
- package/dist/contracts/teams.js +34 -16
- package/dist/contracts/transfers.d.ts +0 -49
- package/dist/contracts/transfers.js +2 -6
- package/dist/contracts/usage.d.ts +61 -0
- package/dist/contracts/usage.js +64 -0
- package/dist/contracts/variables.d.ts +2 -7
- package/dist/contracts/variables.js +6 -5
- package/dist/contracts/webhooks.d.ts +2 -2
- package/dist/contracts/zero.d.ts +87 -56
- package/dist/contracts/zero.js +82 -20
- package/dist/dashboard-paths/index.d.ts +1 -1
- package/dist/dashboard-paths/index.js +1 -0
- package/dist/docs/agent-prose.d.ts +1 -1
- package/dist/docs/agent-prose.js +57 -61
- package/dist/docs/agent-setup.js +40 -13
- package/dist/docs/catalog.d.ts +19 -19
- package/dist/docs/catalog.js +30 -19
- package/dist/docs/error-docs.js +63 -151
- package/dist/test-helpers/fetch-stub.d.ts +16 -0
- package/dist/test-helpers/fetch-stub.js +24 -0
- package/dist/utils/build-settings.js +9 -3
- package/dist/utils/canonical-json.d.ts +10 -0
- package/dist/utils/canonical-json.js +21 -0
- package/dist/utils/cast-transport.d.ts +28 -0
- package/dist/utils/cast-transport.js +52 -0
- package/dist/utils/claim-token.d.ts +0 -8
- package/dist/utils/claim-token.js +3 -15
- package/dist/utils/credential-policy.d.ts +1 -1
- package/dist/utils/env-file.d.ts +17 -0
- package/dist/utils/env-file.js +96 -0
- package/dist/utils/error-code.d.ts +2 -0
- package/dist/utils/error-code.js +7 -0
- package/dist/utils/generate-space-name.d.ts +8 -10
- package/dist/utils/generate-space-name.js +206 -21
- package/dist/utils/grant-decision.fixtures.json +2938 -0
- package/dist/utils/grants.d.ts +2 -0
- package/dist/utils/grants.js +25 -2
- package/dist/utils/gravatar.d.ts +9 -0
- package/dist/utils/gravatar.js +31 -0
- package/dist/utils/idempotency.d.ts +6 -0
- package/dist/utils/idempotency.js +28 -0
- package/dist/utils/local-space-state.d.ts +1 -5
- package/dist/utils/local-space-state.js +7 -26
- package/dist/utils/page-fonts.d.ts +2 -2
- package/dist/utils/page-fonts.js +22 -4
- package/dist/utils/pages.d.ts +1 -2
- package/dist/utils/pages.js +21 -5
- package/dist/utils/publish-form-data.d.ts +12 -0
- package/dist/utils/publish-form-data.js +10 -0
- package/dist/utils/publish-policy.d.ts +20 -0
- package/dist/utils/publish-policy.fixtures.json +397 -0
- package/dist/utils/publish-policy.js +36 -19
- package/dist/utils/push-new.d.ts +7 -0
- package/dist/utils/push-new.js +7 -0
- package/dist/utils/query-keys.d.ts +0 -1
- package/dist/utils/query-keys.js +0 -1
- package/dist/utils/runtime-paths.d.ts +5 -0
- package/dist/utils/runtime-paths.js +5 -0
- package/dist/utils/runtime-upload-batch.d.ts +0 -5
- package/dist/utils/runtime-upload-batch.js +1 -27
- package/dist/utils/runtime-upload.d.ts +3 -13
- package/dist/utils/runtime-upload.js +4 -14
- package/dist/utils/space-config.d.ts +0 -33
- package/dist/utils/space-config.js +5 -326
- package/dist/utils/storage-policy.d.ts +1 -1
- package/dist/utils/storage-policy.js +3 -1
- package/dist/utils/structured-error.d.ts +14 -0
- package/dist/utils/structured-error.js +22 -0
- package/dist/utils/version-path.js +12 -3
- package/dist/vocabulary.d.ts +5 -3
- package/dist/vocabulary.js +13 -10
- package/package.json +10 -5
- package/dist/config/postgres-budget.d.ts +0 -129
- package/dist/config/postgres-budget.js +0 -140
- package/dist/config/postgres-budget.json +0 -51
- package/dist/contracts/archives.d.ts +0 -331
- package/dist/contracts/archives.js +0 -120
- package/dist/contracts/deployments.d.ts +0 -574
- package/dist/contracts/deployments.js +0 -97
- package/dist/contracts/sites.d.ts +0 -416
- package/dist/contracts/sites.js +0 -168
- package/dist/contracts/superadmin-queues.d.ts +0 -414
- package/dist/contracts/superadmin-queues.js +0 -202
- package/dist/contracts/superadmin-runtime.d.ts +0 -27
- package/dist/contracts/superadmin-runtime.js +0 -38
- package/dist/index.d.ts +0 -1
- package/dist/index.js +0 -1
- package/dist/utils/api.d.ts +0 -4
- package/dist/utils/api.js +0 -13
|
@@ -1,129 +0,0 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
|
-
declare const postgresConnectionBudgetSchema: z.ZodObject<{
|
|
3
|
-
server: z.ZodObject<{
|
|
4
|
-
maxConnections: z.ZodNumber;
|
|
5
|
-
superuserReservedConnections: z.ZodNumber;
|
|
6
|
-
}, z.core.$strip>;
|
|
7
|
-
migrationConnections: z.ZodNumber;
|
|
8
|
-
operationalReserveConnections: z.ZodNumber;
|
|
9
|
-
transactionPools: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
10
|
-
serverConnections: z.ZodNumber;
|
|
11
|
-
}, z.core.$strip>>;
|
|
12
|
-
services: z.ZodObject<{
|
|
13
|
-
api: z.ZodObject<{
|
|
14
|
-
enabledInProduction: z.ZodBoolean;
|
|
15
|
-
replicas: z.ZodNumber;
|
|
16
|
-
poolConnectionsPerReplica: z.ZodNumber;
|
|
17
|
-
fixedConnectionsPerReplica: z.ZodNumber;
|
|
18
|
-
maxPinnedTransactionsPerReplica: z.ZodNumber;
|
|
19
|
-
rolloutOverlapReplicas: z.ZodNumber;
|
|
20
|
-
connectionBudget: z.ZodString;
|
|
21
|
-
}, z.core.$strip>;
|
|
22
|
-
worker: z.ZodObject<{
|
|
23
|
-
enabledInProduction: z.ZodBoolean;
|
|
24
|
-
replicas: z.ZodNumber;
|
|
25
|
-
poolConnectionsPerReplica: z.ZodNumber;
|
|
26
|
-
fixedConnectionsPerReplica: z.ZodNumber;
|
|
27
|
-
maxPinnedTransactionsPerReplica: z.ZodNumber;
|
|
28
|
-
rolloutOverlapReplicas: z.ZodNumber;
|
|
29
|
-
connectionBudget: z.ZodString;
|
|
30
|
-
}, z.core.$strip>;
|
|
31
|
-
cast: z.ZodObject<{
|
|
32
|
-
enabledInProduction: z.ZodBoolean;
|
|
33
|
-
replicas: z.ZodNumber;
|
|
34
|
-
poolConnectionsPerReplica: z.ZodNumber;
|
|
35
|
-
fixedConnectionsPerReplica: z.ZodNumber;
|
|
36
|
-
maxPinnedTransactionsPerReplica: z.ZodNumber;
|
|
37
|
-
rolloutOverlapReplicas: z.ZodNumber;
|
|
38
|
-
connectionBudget: z.ZodString;
|
|
39
|
-
}, z.core.$strip>;
|
|
40
|
-
scanWorker: z.ZodObject<{
|
|
41
|
-
enabledInProduction: z.ZodBoolean;
|
|
42
|
-
replicas: z.ZodNumber;
|
|
43
|
-
poolConnectionsPerReplica: z.ZodNumber;
|
|
44
|
-
fixedConnectionsPerReplica: z.ZodNumber;
|
|
45
|
-
maxPinnedTransactionsPerReplica: z.ZodNumber;
|
|
46
|
-
rolloutOverlapReplicas: z.ZodNumber;
|
|
47
|
-
connectionBudget: z.ZodString;
|
|
48
|
-
}, z.core.$strip>;
|
|
49
|
-
}, z.core.$strip>;
|
|
50
|
-
}, z.core.$strip>;
|
|
51
|
-
export type PostgresConnectionBudget = z.infer<typeof postgresConnectionBudgetSchema>;
|
|
52
|
-
export type PostgresBudgetService = keyof PostgresConnectionBudget["services"];
|
|
53
|
-
export type PostgresConnectionBudgetSummary = {
|
|
54
|
-
usableServerConnections: number;
|
|
55
|
-
directSteadyConnections: number;
|
|
56
|
-
transactionPoolConnections: number;
|
|
57
|
-
transactionPoolPinnedConnections: number;
|
|
58
|
-
transactionPoolQueryHeadroom: number;
|
|
59
|
-
steadyConnections: number;
|
|
60
|
-
rollingDeploySurgeConnections: number;
|
|
61
|
-
migrationConnections: number;
|
|
62
|
-
operationalReserveConnections: number;
|
|
63
|
-
plannedConnections: number;
|
|
64
|
-
unallocatedConnections: number;
|
|
65
|
-
};
|
|
66
|
-
export declare const POSTGRES_CONNECTION_BUDGET: {
|
|
67
|
-
server: {
|
|
68
|
-
maxConnections: number;
|
|
69
|
-
superuserReservedConnections: number;
|
|
70
|
-
};
|
|
71
|
-
migrationConnections: number;
|
|
72
|
-
operationalReserveConnections: number;
|
|
73
|
-
transactionPools: Record<string, {
|
|
74
|
-
serverConnections: number;
|
|
75
|
-
}>;
|
|
76
|
-
services: {
|
|
77
|
-
api: {
|
|
78
|
-
enabledInProduction: boolean;
|
|
79
|
-
replicas: number;
|
|
80
|
-
poolConnectionsPerReplica: number;
|
|
81
|
-
fixedConnectionsPerReplica: number;
|
|
82
|
-
maxPinnedTransactionsPerReplica: number;
|
|
83
|
-
rolloutOverlapReplicas: number;
|
|
84
|
-
connectionBudget: string;
|
|
85
|
-
};
|
|
86
|
-
worker: {
|
|
87
|
-
enabledInProduction: boolean;
|
|
88
|
-
replicas: number;
|
|
89
|
-
poolConnectionsPerReplica: number;
|
|
90
|
-
fixedConnectionsPerReplica: number;
|
|
91
|
-
maxPinnedTransactionsPerReplica: number;
|
|
92
|
-
rolloutOverlapReplicas: number;
|
|
93
|
-
connectionBudget: string;
|
|
94
|
-
};
|
|
95
|
-
cast: {
|
|
96
|
-
enabledInProduction: boolean;
|
|
97
|
-
replicas: number;
|
|
98
|
-
poolConnectionsPerReplica: number;
|
|
99
|
-
fixedConnectionsPerReplica: number;
|
|
100
|
-
maxPinnedTransactionsPerReplica: number;
|
|
101
|
-
rolloutOverlapReplicas: number;
|
|
102
|
-
connectionBudget: string;
|
|
103
|
-
};
|
|
104
|
-
scanWorker: {
|
|
105
|
-
enabledInProduction: boolean;
|
|
106
|
-
replicas: number;
|
|
107
|
-
poolConnectionsPerReplica: number;
|
|
108
|
-
fixedConnectionsPerReplica: number;
|
|
109
|
-
maxPinnedTransactionsPerReplica: number;
|
|
110
|
-
rolloutOverlapReplicas: number;
|
|
111
|
-
connectionBudget: string;
|
|
112
|
-
};
|
|
113
|
-
};
|
|
114
|
-
};
|
|
115
|
-
export declare function calculatePostgresConnectionBudget(plan: PostgresConnectionBudget, server?: {
|
|
116
|
-
maxConnections: number;
|
|
117
|
-
superuserReservedConnections: number;
|
|
118
|
-
}): PostgresConnectionBudgetSummary;
|
|
119
|
-
export declare function assertPostgresServiceConnectionUrl(service: PostgresBudgetService, rawUrl: string, options?: {
|
|
120
|
-
allowDirectDevelopmentConnection?: boolean;
|
|
121
|
-
}): void;
|
|
122
|
-
export declare function assertPostgresServicePoolBudget(service: PostgresBudgetService, configuredPoolConnections: number): void;
|
|
123
|
-
export declare function assertPostgresServiceNamedLockBudget(service: PostgresBudgetService, configuredNamedLockTransactions: number): void;
|
|
124
|
-
export declare function assertPostgresServerBudget(server: {
|
|
125
|
-
maxConnections: number;
|
|
126
|
-
superuserReservedConnections: number;
|
|
127
|
-
}): PostgresConnectionBudgetSummary;
|
|
128
|
-
export declare const POSTGRES_CONNECTION_BUDGET_SUMMARY: PostgresConnectionBudgetSummary;
|
|
129
|
-
export {};
|
|
@@ -1,140 +0,0 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
|
-
import budgetJson from "./postgres-budget.json" with { type: "json" };
|
|
3
|
-
const serviceBudgetSchema = z.object({
|
|
4
|
-
enabledInProduction: z.boolean(),
|
|
5
|
-
replicas: z.number().int().nonnegative(),
|
|
6
|
-
poolConnectionsPerReplica: z.number().int().positive(),
|
|
7
|
-
fixedConnectionsPerReplica: z.number().int().nonnegative(),
|
|
8
|
-
maxPinnedTransactionsPerReplica: z.number().int().nonnegative(),
|
|
9
|
-
rolloutOverlapReplicas: z.number().int().nonnegative(),
|
|
10
|
-
connectionBudget: z.string().min(1),
|
|
11
|
-
});
|
|
12
|
-
const postgresConnectionBudgetSchema = z
|
|
13
|
-
.object({
|
|
14
|
-
server: z.object({
|
|
15
|
-
maxConnections: z.number().int().positive(),
|
|
16
|
-
superuserReservedConnections: z.number().int().nonnegative(),
|
|
17
|
-
}),
|
|
18
|
-
migrationConnections: z.number().int().positive(),
|
|
19
|
-
operationalReserveConnections: z.number().int().nonnegative(),
|
|
20
|
-
transactionPools: z.record(z.string().min(1), z.object({
|
|
21
|
-
serverConnections: z.number().int().positive(),
|
|
22
|
-
})),
|
|
23
|
-
services: z.object({
|
|
24
|
-
api: serviceBudgetSchema,
|
|
25
|
-
worker: serviceBudgetSchema,
|
|
26
|
-
cast: serviceBudgetSchema,
|
|
27
|
-
scanWorker: serviceBudgetSchema,
|
|
28
|
-
}),
|
|
29
|
-
})
|
|
30
|
-
.superRefine((plan, context) => {
|
|
31
|
-
for (const [serviceName, service] of Object.entries(plan.services)) {
|
|
32
|
-
if (service.connectionBudget !== "direct" &&
|
|
33
|
-
!Object.hasOwn(plan.transactionPools, service.connectionBudget)) {
|
|
34
|
-
context.addIssue({
|
|
35
|
-
code: "custom",
|
|
36
|
-
message: `service ${serviceName} references unknown transaction pool ${service.connectionBudget}`,
|
|
37
|
-
path: ["services", serviceName, "connectionBudget"],
|
|
38
|
-
});
|
|
39
|
-
}
|
|
40
|
-
}
|
|
41
|
-
for (const [poolName, pool] of Object.entries(plan.transactionPools)) {
|
|
42
|
-
const maxPinnedTransactions = Object.values(plan.services)
|
|
43
|
-
.filter((service) => service.enabledInProduction && service.connectionBudget === poolName)
|
|
44
|
-
.reduce((total, service) => total +
|
|
45
|
-
(service.replicas + service.rolloutOverlapReplicas) *
|
|
46
|
-
service.maxPinnedTransactionsPerReplica, 0);
|
|
47
|
-
if (maxPinnedTransactions >= pool.serverConnections) {
|
|
48
|
-
context.addIssue({
|
|
49
|
-
code: "custom",
|
|
50
|
-
message: `transaction pool ${poolName} can pin ${maxPinnedTransactions}/${pool.serverConnections} server connections, leaving no callback query capacity`,
|
|
51
|
-
path: ["transactionPools", poolName, "serverConnections"],
|
|
52
|
-
});
|
|
53
|
-
}
|
|
54
|
-
}
|
|
55
|
-
});
|
|
56
|
-
export const POSTGRES_CONNECTION_BUDGET = postgresConnectionBudgetSchema.parse(budgetJson);
|
|
57
|
-
function serviceFootprint(service) {
|
|
58
|
-
return service.poolConnectionsPerReplica + service.fixedConnectionsPerReplica;
|
|
59
|
-
}
|
|
60
|
-
export function calculatePostgresConnectionBudget(plan, server = plan.server) {
|
|
61
|
-
const usableServerConnections = server.maxConnections - server.superuserReservedConnections;
|
|
62
|
-
if (usableServerConnections <= 0) {
|
|
63
|
-
throw new Error(`postgres_connection_budget_invalid: maxConnections=${server.maxConnections} must exceed superuserReservedConnections=${server.superuserReservedConnections}`);
|
|
64
|
-
}
|
|
65
|
-
const directServices = Object.values(plan.services).filter((service) => service.enabledInProduction && service.connectionBudget === "direct");
|
|
66
|
-
const directSteadyConnections = directServices.reduce((total, service) => total + service.replicas * serviceFootprint(service), 0);
|
|
67
|
-
const transactionPoolConnections = Object.values(plan.transactionPools).reduce((total, pool) => total + pool.serverConnections, 0);
|
|
68
|
-
const transactionPoolPinnedConnections = Object.values(plan.services)
|
|
69
|
-
.filter((service) => service.enabledInProduction && service.connectionBudget !== "direct")
|
|
70
|
-
.reduce((total, service) => total +
|
|
71
|
-
(service.replicas + service.rolloutOverlapReplicas) *
|
|
72
|
-
service.maxPinnedTransactionsPerReplica, 0);
|
|
73
|
-
const transactionPoolQueryHeadroom = transactionPoolConnections - transactionPoolPinnedConnections;
|
|
74
|
-
const steadyConnections = directSteadyConnections + transactionPoolConnections;
|
|
75
|
-
const rollingDeploySurgeConnections = directServices.reduce((total, service) => total + service.rolloutOverlapReplicas * serviceFootprint(service), 0);
|
|
76
|
-
const plannedConnections = steadyConnections +
|
|
77
|
-
rollingDeploySurgeConnections +
|
|
78
|
-
plan.migrationConnections +
|
|
79
|
-
plan.operationalReserveConnections;
|
|
80
|
-
return {
|
|
81
|
-
usableServerConnections,
|
|
82
|
-
directSteadyConnections,
|
|
83
|
-
transactionPoolConnections,
|
|
84
|
-
transactionPoolPinnedConnections,
|
|
85
|
-
transactionPoolQueryHeadroom,
|
|
86
|
-
steadyConnections,
|
|
87
|
-
rollingDeploySurgeConnections,
|
|
88
|
-
migrationConnections: plan.migrationConnections,
|
|
89
|
-
operationalReserveConnections: plan.operationalReserveConnections,
|
|
90
|
-
plannedConnections,
|
|
91
|
-
unallocatedConnections: usableServerConnections - plannedConnections,
|
|
92
|
-
};
|
|
93
|
-
}
|
|
94
|
-
export function assertPostgresServiceConnectionUrl(service, rawUrl, options = {}) {
|
|
95
|
-
const parsed = new URL(rawUrl);
|
|
96
|
-
const hostname = parsed.hostname.toLowerCase();
|
|
97
|
-
const isLocalDevelopmentHost = hostname === "localhost" ||
|
|
98
|
-
hostname === "127.0.0.1" ||
|
|
99
|
-
hostname === "::1" ||
|
|
100
|
-
hostname === "[::1]" ||
|
|
101
|
-
(!hostname.includes(".") && !hostname.includes(":"));
|
|
102
|
-
if (options.allowDirectDevelopmentConnection && isLocalDevelopmentHost) {
|
|
103
|
-
return;
|
|
104
|
-
}
|
|
105
|
-
const serviceBudget = POSTGRES_CONNECTION_BUDGET.services[service];
|
|
106
|
-
if (!serviceBudget.enabledInProduction) {
|
|
107
|
-
throw new Error(`postgres_connection_budget_service_disabled: service=${service}; add its replicas and rollout overlap to the shared budget before production startup`);
|
|
108
|
-
}
|
|
109
|
-
const connectionBudget = serviceBudget.connectionBudget;
|
|
110
|
-
const port = parsed.port || "5432";
|
|
111
|
-
if (connectionBudget === "direct") {
|
|
112
|
-
if (port !== "5432") {
|
|
113
|
-
throw new Error(`postgres_connection_budget_url_mismatch: service=${service} planned=direct port=${port}`);
|
|
114
|
-
}
|
|
115
|
-
return;
|
|
116
|
-
}
|
|
117
|
-
if (port !== "6432") {
|
|
118
|
-
throw new Error(`postgres_connection_budget_url_mismatch: service=${service} planned=transaction_pool pool=${connectionBudget} port=${port}`);
|
|
119
|
-
}
|
|
120
|
-
}
|
|
121
|
-
export function assertPostgresServicePoolBudget(service, configuredPoolConnections) {
|
|
122
|
-
const expected = POSTGRES_CONNECTION_BUDGET.services[service].poolConnectionsPerReplica;
|
|
123
|
-
if (configuredPoolConnections !== expected) {
|
|
124
|
-
throw new Error(`postgres_connection_budget_pool_mismatch: service=${service} configured=${configuredPoolConnections} planned=${expected}; update the shared budget and every affected service in one change`);
|
|
125
|
-
}
|
|
126
|
-
}
|
|
127
|
-
export function assertPostgresServiceNamedLockBudget(service, configuredNamedLockTransactions) {
|
|
128
|
-
const expected = POSTGRES_CONNECTION_BUDGET.services[service].maxPinnedTransactionsPerReplica;
|
|
129
|
-
if (configuredNamedLockTransactions !== expected) {
|
|
130
|
-
throw new Error(`postgres_connection_budget_named_lock_mismatch: service=${service} configured=${configuredNamedLockTransactions} planned=${expected}`);
|
|
131
|
-
}
|
|
132
|
-
}
|
|
133
|
-
export function assertPostgresServerBudget(server) {
|
|
134
|
-
const summary = calculatePostgresConnectionBudget(POSTGRES_CONNECTION_BUDGET, server);
|
|
135
|
-
if (summary.unallocatedConnections < 0) {
|
|
136
|
-
throw new Error(`postgres_connection_budget_exceeded: planned=${summary.plannedConnections} usable=${summary.usableServerConnections} max=${server.maxConnections} superuserReserved=${server.superuserReservedConnections}`);
|
|
137
|
-
}
|
|
138
|
-
return summary;
|
|
139
|
-
}
|
|
140
|
-
export const POSTGRES_CONNECTION_BUDGET_SUMMARY = assertPostgresServerBudget(POSTGRES_CONNECTION_BUDGET.server);
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"server": {
|
|
3
|
-
"maxConnections": 25,
|
|
4
|
-
"superuserReservedConnections": 3
|
|
5
|
-
},
|
|
6
|
-
"migrationConnections": 1,
|
|
7
|
-
"operationalReserveConnections": 4,
|
|
8
|
-
"transactionPools": {
|
|
9
|
-
"controlPlaneRuntime": {
|
|
10
|
-
"serverConnections": 7
|
|
11
|
-
}
|
|
12
|
-
},
|
|
13
|
-
"services": {
|
|
14
|
-
"api": {
|
|
15
|
-
"enabledInProduction": true,
|
|
16
|
-
"replicas": 2,
|
|
17
|
-
"poolConnectionsPerReplica": 4,
|
|
18
|
-
"fixedConnectionsPerReplica": 0,
|
|
19
|
-
"maxPinnedTransactionsPerReplica": 1,
|
|
20
|
-
"rolloutOverlapReplicas": 1,
|
|
21
|
-
"connectionBudget": "controlPlaneRuntime"
|
|
22
|
-
},
|
|
23
|
-
"worker": {
|
|
24
|
-
"enabledInProduction": true,
|
|
25
|
-
"replicas": 1,
|
|
26
|
-
"poolConnectionsPerReplica": 4,
|
|
27
|
-
"fixedConnectionsPerReplica": 0,
|
|
28
|
-
"maxPinnedTransactionsPerReplica": 1,
|
|
29
|
-
"rolloutOverlapReplicas": 1,
|
|
30
|
-
"connectionBudget": "controlPlaneRuntime"
|
|
31
|
-
},
|
|
32
|
-
"cast": {
|
|
33
|
-
"enabledInProduction": true,
|
|
34
|
-
"replicas": 1,
|
|
35
|
-
"poolConnectionsPerReplica": 4,
|
|
36
|
-
"fixedConnectionsPerReplica": 1,
|
|
37
|
-
"maxPinnedTransactionsPerReplica": 0,
|
|
38
|
-
"rolloutOverlapReplicas": 1,
|
|
39
|
-
"connectionBudget": "direct"
|
|
40
|
-
},
|
|
41
|
-
"scanWorker": {
|
|
42
|
-
"enabledInProduction": false,
|
|
43
|
-
"replicas": 0,
|
|
44
|
-
"poolConnectionsPerReplica": 2,
|
|
45
|
-
"fixedConnectionsPerReplica": 0,
|
|
46
|
-
"maxPinnedTransactionsPerReplica": 1,
|
|
47
|
-
"rolloutOverlapReplicas": 0,
|
|
48
|
-
"connectionBudget": "controlPlaneRuntime"
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
}
|
|
@@ -1,331 +0,0 @@
|
|
|
1
|
-
import { z } from "zod";
|
|
2
|
-
export declare const archiveListQuerySchema: z.ZodObject<{
|
|
3
|
-
limit: z.ZodDefault<z.ZodCoercedNumber<unknown>>;
|
|
4
|
-
cursor: z.ZodOptional<z.ZodString>;
|
|
5
|
-
}, z.core.$strip>;
|
|
6
|
-
export declare const spaceExportRequestSchema: z.ZodObject<{
|
|
7
|
-
versionIds: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
8
|
-
includeFiles: z.ZodDefault<z.ZodBoolean>;
|
|
9
|
-
}, z.core.$strict>;
|
|
10
|
-
export declare const spaceExportArchiveSchema: z.ZodObject<{
|
|
11
|
-
contentType: z.ZodLiteral<"application/zip">;
|
|
12
|
-
downloadUrl: z.ZodString;
|
|
13
|
-
expiresAt: z.ZodString;
|
|
14
|
-
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
15
|
-
sha256: z.ZodOptional<z.ZodString>;
|
|
16
|
-
}, z.core.$strip>;
|
|
17
|
-
export declare const spaceExportSchema: z.ZodObject<{
|
|
18
|
-
id: z.ZodString;
|
|
19
|
-
spaceId: z.ZodString;
|
|
20
|
-
status: z.ZodEnum<{
|
|
21
|
-
failed: "failed";
|
|
22
|
-
expired: "expired";
|
|
23
|
-
ready: "ready";
|
|
24
|
-
queued: "queued";
|
|
25
|
-
running: "running";
|
|
26
|
-
}>;
|
|
27
|
-
format: z.ZodLiteral<"spacefast_export_v1">;
|
|
28
|
-
diagnostics: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
29
|
-
code: z.ZodString;
|
|
30
|
-
severity: z.ZodEnum<{
|
|
31
|
-
info: "info";
|
|
32
|
-
error: "error";
|
|
33
|
-
warning: "warning";
|
|
34
|
-
}>;
|
|
35
|
-
message: z.ZodString;
|
|
36
|
-
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
37
|
-
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
38
|
-
registrar: "registrar";
|
|
39
|
-
wpcloud: "wpcloud";
|
|
40
|
-
dns: "dns";
|
|
41
|
-
runtime: "runtime";
|
|
42
|
-
}>>>;
|
|
43
|
-
details: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
44
|
-
fix: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
45
|
-
retryable: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
46
|
-
}, z.core.$strip>>>;
|
|
47
|
-
archive: z.ZodOptional<z.ZodObject<{
|
|
48
|
-
contentType: z.ZodLiteral<"application/zip">;
|
|
49
|
-
downloadUrl: z.ZodString;
|
|
50
|
-
expiresAt: z.ZodString;
|
|
51
|
-
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
52
|
-
sha256: z.ZodOptional<z.ZodString>;
|
|
53
|
-
}, z.core.$strip>>;
|
|
54
|
-
operationId: z.ZodNullable<z.ZodString>;
|
|
55
|
-
createdAt: z.ZodString;
|
|
56
|
-
updatedAt: z.ZodString;
|
|
57
|
-
}, z.core.$strip>;
|
|
58
|
-
export declare const spaceExportListResponseSchema: z.ZodObject<{
|
|
59
|
-
data: z.ZodArray<z.ZodObject<{
|
|
60
|
-
id: z.ZodString;
|
|
61
|
-
spaceId: z.ZodString;
|
|
62
|
-
status: z.ZodEnum<{
|
|
63
|
-
failed: "failed";
|
|
64
|
-
expired: "expired";
|
|
65
|
-
ready: "ready";
|
|
66
|
-
queued: "queued";
|
|
67
|
-
running: "running";
|
|
68
|
-
}>;
|
|
69
|
-
format: z.ZodLiteral<"spacefast_export_v1">;
|
|
70
|
-
diagnostics: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
71
|
-
code: z.ZodString;
|
|
72
|
-
severity: z.ZodEnum<{
|
|
73
|
-
info: "info";
|
|
74
|
-
error: "error";
|
|
75
|
-
warning: "warning";
|
|
76
|
-
}>;
|
|
77
|
-
message: z.ZodString;
|
|
78
|
-
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
79
|
-
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
80
|
-
registrar: "registrar";
|
|
81
|
-
wpcloud: "wpcloud";
|
|
82
|
-
dns: "dns";
|
|
83
|
-
runtime: "runtime";
|
|
84
|
-
}>>>;
|
|
85
|
-
details: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
86
|
-
fix: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
87
|
-
retryable: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
88
|
-
}, z.core.$strip>>>;
|
|
89
|
-
archive: z.ZodOptional<z.ZodObject<{
|
|
90
|
-
contentType: z.ZodLiteral<"application/zip">;
|
|
91
|
-
downloadUrl: z.ZodString;
|
|
92
|
-
expiresAt: z.ZodString;
|
|
93
|
-
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
94
|
-
sha256: z.ZodOptional<z.ZodString>;
|
|
95
|
-
}, z.core.$strip>>;
|
|
96
|
-
operationId: z.ZodNullable<z.ZodString>;
|
|
97
|
-
createdAt: z.ZodString;
|
|
98
|
-
updatedAt: z.ZodString;
|
|
99
|
-
}, z.core.$strip>>;
|
|
100
|
-
pagination: z.ZodObject<{
|
|
101
|
-
nextCursor: z.ZodNullable<z.ZodString>;
|
|
102
|
-
hasMore: z.ZodBoolean;
|
|
103
|
-
}, z.core.$strip>;
|
|
104
|
-
}, z.core.$strip>;
|
|
105
|
-
export declare const spaceImportSourceSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
106
|
-
kind: z.ZodLiteral<"upload">;
|
|
107
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
108
|
-
kind: z.ZodLiteral<"url">;
|
|
109
|
-
url: z.ZodString;
|
|
110
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
111
|
-
kind: z.ZodLiteral<"export">;
|
|
112
|
-
exportId: z.ZodString;
|
|
113
|
-
}, z.core.$strip>], "kind">;
|
|
114
|
-
export declare const spaceImportRequestSchema: z.ZodObject<{
|
|
115
|
-
source: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
116
|
-
kind: z.ZodLiteral<"upload">;
|
|
117
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
118
|
-
kind: z.ZodLiteral<"url">;
|
|
119
|
-
url: z.ZodString;
|
|
120
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
121
|
-
kind: z.ZodLiteral<"export">;
|
|
122
|
-
exportId: z.ZodString;
|
|
123
|
-
}, z.core.$strip>], "kind">;
|
|
124
|
-
publish: z.ZodDefault<z.ZodBoolean>;
|
|
125
|
-
}, z.core.$strip>;
|
|
126
|
-
export declare const spaceImportSchema: z.ZodObject<{
|
|
127
|
-
id: z.ZodString;
|
|
128
|
-
targetSpaceId: z.ZodString;
|
|
129
|
-
status: z.ZodEnum<{
|
|
130
|
-
failed: "failed";
|
|
131
|
-
canceled: "canceled";
|
|
132
|
-
created: "created";
|
|
133
|
-
ready: "ready";
|
|
134
|
-
waiting_for_archive: "waiting_for_archive";
|
|
135
|
-
validating: "validating";
|
|
136
|
-
materializing: "materializing";
|
|
137
|
-
}>;
|
|
138
|
-
archiveUpload: z.ZodOptional<z.ZodObject<{
|
|
139
|
-
id: z.ZodString;
|
|
140
|
-
mode: z.ZodEnum<{
|
|
141
|
-
source: "source";
|
|
142
|
-
dist: "dist";
|
|
143
|
-
}>;
|
|
144
|
-
expiresAt: z.ZodString;
|
|
145
|
-
summary: z.ZodObject<{
|
|
146
|
-
upload: z.ZodNumber;
|
|
147
|
-
reused: z.ZodNumber;
|
|
148
|
-
ignored: z.ZodNumber;
|
|
149
|
-
}, z.core.$strip>;
|
|
150
|
-
targets: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
151
|
-
path: z.ZodString;
|
|
152
|
-
method: z.ZodEnum<{
|
|
153
|
-
POST: "POST";
|
|
154
|
-
PUT: "PUT";
|
|
155
|
-
}>;
|
|
156
|
-
url: z.ZodUnion<[z.ZodString, z.ZodString]>;
|
|
157
|
-
headers: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
158
|
-
body: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
159
|
-
kind: z.ZodLiteral<"url">;
|
|
160
|
-
url: z.ZodString;
|
|
161
|
-
}, z.core.$strip>], "kind">>;
|
|
162
|
-
size: z.ZodOptional<z.ZodNumber>;
|
|
163
|
-
maxBytes: z.ZodOptional<z.ZodNumber>;
|
|
164
|
-
sha256: z.ZodOptional<z.ZodString>;
|
|
165
|
-
contentType: z.ZodOptional<z.ZodString>;
|
|
166
|
-
}, z.core.$strip>>>;
|
|
167
|
-
links: z.ZodObject<{
|
|
168
|
-
resume: z.ZodString;
|
|
169
|
-
finalize: z.ZodString;
|
|
170
|
-
}, z.core.$strip>;
|
|
171
|
-
details: z.ZodOptional<z.ZodObject<{
|
|
172
|
-
reused: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
173
|
-
path: z.ZodString;
|
|
174
|
-
reason: z.ZodString;
|
|
175
|
-
}, z.core.$strip>>>;
|
|
176
|
-
ignored: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
177
|
-
path: z.ZodString;
|
|
178
|
-
reason: z.ZodString;
|
|
179
|
-
}, z.core.$strip>>>;
|
|
180
|
-
diagnostics: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
181
|
-
code: z.ZodString;
|
|
182
|
-
severity: z.ZodEnum<{
|
|
183
|
-
info: "info";
|
|
184
|
-
error: "error";
|
|
185
|
-
warning: "warning";
|
|
186
|
-
}>;
|
|
187
|
-
message: z.ZodString;
|
|
188
|
-
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
189
|
-
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
190
|
-
registrar: "registrar";
|
|
191
|
-
wpcloud: "wpcloud";
|
|
192
|
-
dns: "dns";
|
|
193
|
-
runtime: "runtime";
|
|
194
|
-
}>>>;
|
|
195
|
-
details: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
196
|
-
fix: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
197
|
-
retryable: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
198
|
-
}, z.core.$strip>>>;
|
|
199
|
-
}, z.core.$strip>>;
|
|
200
|
-
}, z.core.$strip>>;
|
|
201
|
-
draftVersionIds: z.ZodArray<z.ZodString>;
|
|
202
|
-
diagnostics: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
203
|
-
code: z.ZodString;
|
|
204
|
-
severity: z.ZodEnum<{
|
|
205
|
-
info: "info";
|
|
206
|
-
error: "error";
|
|
207
|
-
warning: "warning";
|
|
208
|
-
}>;
|
|
209
|
-
message: z.ZodString;
|
|
210
|
-
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
211
|
-
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
212
|
-
registrar: "registrar";
|
|
213
|
-
wpcloud: "wpcloud";
|
|
214
|
-
dns: "dns";
|
|
215
|
-
runtime: "runtime";
|
|
216
|
-
}>>>;
|
|
217
|
-
details: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
218
|
-
fix: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
219
|
-
retryable: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
220
|
-
}, z.core.$strip>>>;
|
|
221
|
-
operationId: z.ZodNullable<z.ZodString>;
|
|
222
|
-
createdAt: z.ZodString;
|
|
223
|
-
updatedAt: z.ZodString;
|
|
224
|
-
}, z.core.$strip>;
|
|
225
|
-
export declare const spaceImportListResponseSchema: z.ZodObject<{
|
|
226
|
-
data: z.ZodArray<z.ZodObject<{
|
|
227
|
-
id: z.ZodString;
|
|
228
|
-
targetSpaceId: z.ZodString;
|
|
229
|
-
status: z.ZodEnum<{
|
|
230
|
-
failed: "failed";
|
|
231
|
-
canceled: "canceled";
|
|
232
|
-
created: "created";
|
|
233
|
-
ready: "ready";
|
|
234
|
-
waiting_for_archive: "waiting_for_archive";
|
|
235
|
-
validating: "validating";
|
|
236
|
-
materializing: "materializing";
|
|
237
|
-
}>;
|
|
238
|
-
archiveUpload: z.ZodOptional<z.ZodObject<{
|
|
239
|
-
id: z.ZodString;
|
|
240
|
-
mode: z.ZodEnum<{
|
|
241
|
-
source: "source";
|
|
242
|
-
dist: "dist";
|
|
243
|
-
}>;
|
|
244
|
-
expiresAt: z.ZodString;
|
|
245
|
-
summary: z.ZodObject<{
|
|
246
|
-
upload: z.ZodNumber;
|
|
247
|
-
reused: z.ZodNumber;
|
|
248
|
-
ignored: z.ZodNumber;
|
|
249
|
-
}, z.core.$strip>;
|
|
250
|
-
targets: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
251
|
-
path: z.ZodString;
|
|
252
|
-
method: z.ZodEnum<{
|
|
253
|
-
POST: "POST";
|
|
254
|
-
PUT: "PUT";
|
|
255
|
-
}>;
|
|
256
|
-
url: z.ZodUnion<[z.ZodString, z.ZodString]>;
|
|
257
|
-
headers: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
258
|
-
body: z.ZodOptional<z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
259
|
-
kind: z.ZodLiteral<"url">;
|
|
260
|
-
url: z.ZodString;
|
|
261
|
-
}, z.core.$strip>], "kind">>;
|
|
262
|
-
size: z.ZodOptional<z.ZodNumber>;
|
|
263
|
-
maxBytes: z.ZodOptional<z.ZodNumber>;
|
|
264
|
-
sha256: z.ZodOptional<z.ZodString>;
|
|
265
|
-
contentType: z.ZodOptional<z.ZodString>;
|
|
266
|
-
}, z.core.$strip>>>;
|
|
267
|
-
links: z.ZodObject<{
|
|
268
|
-
resume: z.ZodString;
|
|
269
|
-
finalize: z.ZodString;
|
|
270
|
-
}, z.core.$strip>;
|
|
271
|
-
details: z.ZodOptional<z.ZodObject<{
|
|
272
|
-
reused: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
273
|
-
path: z.ZodString;
|
|
274
|
-
reason: z.ZodString;
|
|
275
|
-
}, z.core.$strip>>>;
|
|
276
|
-
ignored: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
277
|
-
path: z.ZodString;
|
|
278
|
-
reason: z.ZodString;
|
|
279
|
-
}, z.core.$strip>>>;
|
|
280
|
-
diagnostics: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
281
|
-
code: z.ZodString;
|
|
282
|
-
severity: z.ZodEnum<{
|
|
283
|
-
info: "info";
|
|
284
|
-
error: "error";
|
|
285
|
-
warning: "warning";
|
|
286
|
-
}>;
|
|
287
|
-
message: z.ZodString;
|
|
288
|
-
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
289
|
-
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
290
|
-
registrar: "registrar";
|
|
291
|
-
wpcloud: "wpcloud";
|
|
292
|
-
dns: "dns";
|
|
293
|
-
runtime: "runtime";
|
|
294
|
-
}>>>;
|
|
295
|
-
details: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
296
|
-
fix: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
297
|
-
retryable: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
298
|
-
}, z.core.$strip>>>;
|
|
299
|
-
}, z.core.$strip>>;
|
|
300
|
-
}, z.core.$strip>>;
|
|
301
|
-
draftVersionIds: z.ZodArray<z.ZodString>;
|
|
302
|
-
diagnostics: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
303
|
-
code: z.ZodString;
|
|
304
|
-
severity: z.ZodEnum<{
|
|
305
|
-
info: "info";
|
|
306
|
-
error: "error";
|
|
307
|
-
warning: "warning";
|
|
308
|
-
}>;
|
|
309
|
-
message: z.ZodString;
|
|
310
|
-
path: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
311
|
-
provider: z.ZodOptional<z.ZodNullable<z.ZodEnum<{
|
|
312
|
-
registrar: "registrar";
|
|
313
|
-
wpcloud: "wpcloud";
|
|
314
|
-
dns: "dns";
|
|
315
|
-
runtime: "runtime";
|
|
316
|
-
}>>>;
|
|
317
|
-
details: z.ZodOptional<z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>>;
|
|
318
|
-
fix: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
319
|
-
retryable: z.ZodOptional<z.ZodNullable<z.ZodBoolean>>;
|
|
320
|
-
}, z.core.$strip>>>;
|
|
321
|
-
operationId: z.ZodNullable<z.ZodString>;
|
|
322
|
-
createdAt: z.ZodString;
|
|
323
|
-
updatedAt: z.ZodString;
|
|
324
|
-
}, z.core.$strip>>;
|
|
325
|
-
pagination: z.ZodObject<{
|
|
326
|
-
nextCursor: z.ZodNullable<z.ZodString>;
|
|
327
|
-
hasMore: z.ZodBoolean;
|
|
328
|
-
}, z.core.$strip>;
|
|
329
|
-
}, z.core.$strip>;
|
|
330
|
-
export type SpaceExport = z.infer<typeof spaceExportSchema>;
|
|
331
|
-
export type SpaceImport = z.infer<typeof spaceImportSchema>;
|