@supacloud/compiler 0.48.0 → 0.50.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/application-development.d.ts +1 -0
- package/dist/cli.js +284 -47
- package/dist/contract-manifest.d.ts +5 -1
- package/dist/delivery-bundle-worker.js +3 -1
- package/dist/feature.d.ts +2 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +288 -51
- package/dist/migration-app-version.d.ts +1 -1
- package/dist/migration-elysia-version.d.ts +1 -1
- package/dist/types.d.ts +12 -0
- package/package.json +5 -5
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ApplicationGraph, FeaturePersistenceNode } from "./types";
|
|
1
|
+
import type { ApplicationGraph, FeatureDatabaseSourceNode, FeaturePersistenceNode } from "./types";
|
|
2
2
|
export interface ContractManifest {
|
|
3
3
|
version: 1;
|
|
4
4
|
commands: Array<{
|
|
@@ -41,6 +41,7 @@ export interface ContractManifest {
|
|
|
41
41
|
features: Array<{
|
|
42
42
|
name: string;
|
|
43
43
|
states: string[];
|
|
44
|
+
database?: FeatureDatabaseSourceNode;
|
|
44
45
|
tenantField?: string;
|
|
45
46
|
transitions: Array<{
|
|
46
47
|
name: string;
|
|
@@ -54,6 +55,7 @@ export interface ContractManifest {
|
|
|
54
55
|
idempotency?: "required" | "none";
|
|
55
56
|
audit?: string;
|
|
56
57
|
job?: string;
|
|
58
|
+
invalidateTags?: string[];
|
|
57
59
|
jobDetails?: {
|
|
58
60
|
name: string;
|
|
59
61
|
className: string;
|
|
@@ -76,6 +78,8 @@ export interface ContractManifest {
|
|
|
76
78
|
handler: string;
|
|
77
79
|
command?: string;
|
|
78
80
|
permission?: string;
|
|
81
|
+
idempotency?: "required" | "none";
|
|
82
|
+
tags?: string[];
|
|
79
83
|
requestSchemas: Partial<Record<"body" | "params" | "query" | "headers" | "cookie", string>>;
|
|
80
84
|
responseSchema?: string;
|
|
81
85
|
/** Status-aware response schemas; legacy responseSchema remains for compatibility. */
|
|
@@ -10085,7 +10085,7 @@ function parseDeliveryPlanResult(value) {
|
|
|
10085
10085
|
throw new Error("Invalid delivery plan result.");
|
|
10086
10086
|
return value;
|
|
10087
10087
|
}
|
|
10088
|
-
var objectOptions, reference, references, kind, isolation, DeliveryFilePathSchema, functionTarget, DeliveryOptionsSchema, DeliveryDiagnosticSchema, routeSchema, jobSchema, DeliveryTargetSchema, DeliveryPlanSchema, DeliveryPlanResultSchema, DeliveryConfigurationError;
|
|
10088
|
+
var objectOptions, reference, references, kind, isolation, mode, DeliveryFilePathSchema, functionTarget, DeliveryOptionsSchema, DeliveryDiagnosticSchema, routeSchema, jobSchema, DeliveryTargetSchema, DeliveryPlanSchema, DeliveryPlanResultSchema, DeliveryConfigurationError;
|
|
10089
10089
|
var init_delivery_schema = __esm(() => {
|
|
10090
10090
|
init_build2();
|
|
10091
10091
|
init_value2();
|
|
@@ -10095,6 +10095,7 @@ var init_delivery_schema = __esm(() => {
|
|
|
10095
10095
|
references = _Array_(reference, { uniqueItems: true });
|
|
10096
10096
|
kind = Union([Literal("api"), Literal("jobs"), Literal("webhook"), Literal("function")]);
|
|
10097
10097
|
isolation = Union([Literal("shared"), Literal("process")]);
|
|
10098
|
+
mode = Union([Literal("required"), Literal("none")]);
|
|
10098
10099
|
DeliveryFilePathSchema = String2({
|
|
10099
10100
|
maxLength: 512,
|
|
10100
10101
|
pattern: "^(?:[A-Za-z0-9_-][A-Za-z0-9_.-]*/)*[A-Za-z0-9_-][A-Za-z0-9_.-]*$"
|
|
@@ -10168,6 +10169,7 @@ var init_delivery_schema = __esm(() => {
|
|
|
10168
10169
|
]),
|
|
10169
10170
|
path: String2(),
|
|
10170
10171
|
command: Optional(String2()),
|
|
10172
|
+
idempotency: Optional(mode),
|
|
10171
10173
|
reason: Union([Literal("default-http"), Literal("explicit-module")])
|
|
10172
10174
|
}, objectOptions);
|
|
10173
10175
|
jobSchema = _Object_({
|
package/dist/feature.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
|
-
import type { Diagnostic, FeatureSpecNode, ModuleNode } from "./types";
|
|
1
|
+
import type { ControllerNode, Diagnostic, FeatureSpecNode, ModuleNode, RouteNode } from "./types";
|
|
2
|
+
export declare function featureTransitionForRoute(module: ModuleNode, controller: ControllerNode, route: RouteNode): FeatureSpecNode["transitions"][number] | undefined;
|
|
2
3
|
/** Validate the declaration itself and its bindings within the owning module. */
|
|
3
4
|
export declare function validateFeatureSpec(spec: FeatureSpecNode, module?: ModuleNode): Diagnostic[];
|
|
4
5
|
/**
|
package/dist/index.d.ts
CHANGED
|
@@ -52,7 +52,7 @@ export { DEFAULT_SUPACLOUD_CONFIG, compileOptionsFromConfig, defineSupacloudConf
|
|
|
52
52
|
export type { SupaCloudConfig } from "./config";
|
|
53
53
|
export { camelName } from "./util";
|
|
54
54
|
export { ANGULAR_ENTERPRISE_RULES, CLEAN_ARCHITECTURE_RULES, MODULAR_MONOLITH_RULES, MODULE_BOUNDARY_PROFILES, getModuleBoundaryPreset, getModuleBoundaryProfile, resolveModuleBoundaries, } from "./profiles";
|
|
55
|
-
export type { ApplicationGraph, AspectRefNode, CachedModuleEntry, CheckProjectResult, CommandExecutionCapabilities, CommandNode, CompileOptions, DatabaseGovernanceOptions, CompileResult, CompileStats, ControllerNode, DependencyGraphCache, DependencyGraphIndex, Diagnostic, DiagnosticFix, EffectCompilerOptions, EffectErrorMappingNode, EffectRetryPolicy, EffectRouteNode, ModuleBoundaryPresetName, ModuleBoundaryProfile, ModuleBoundaryRule, ModuleNode, JobNode, ProviderKind, ProviderNode, QueryNode, RouteNode, Scope, TokenKind, TypeSafetyOptions, ValidateOptions, WatchEvent, WatchHandle, WatchOptions, FeatureSpecNode, FeatureTransitionNode, FeaturePersistenceNode, GraphqlOptions, GraphqlContractSummary, OpenApiOptions, OpenApiSecurityScheme, OpenApiServer, } from "./types";
|
|
55
|
+
export type { ApplicationGraph, AspectRefNode, CachedModuleEntry, CheckProjectResult, CommandExecutionCapabilities, CommandNode, CompileOptions, DatabaseGovernanceOptions, CompileResult, CompileStats, ControllerNode, DependencyGraphCache, DependencyGraphIndex, Diagnostic, DiagnosticFix, EffectCompilerOptions, EffectErrorMappingNode, EffectRetryPolicy, EffectRouteNode, ModuleBoundaryPresetName, ModuleBoundaryProfile, ModuleBoundaryRule, ModuleNode, JobNode, ProviderKind, ProviderNode, QueryNode, RouteNode, Scope, TokenKind, TypeSafetyOptions, ValidateOptions, WatchEvent, WatchHandle, WatchOptions, FeatureSpecNode, FeatureTransitionNode, FeatureDatabaseSourceNode, FeaturePersistenceNode, GraphqlOptions, GraphqlContractSummary, OpenApiOptions, OpenApiSecurityScheme, OpenApiServer, } from "./types";
|
|
56
56
|
export { inspectRouteContracts, validateRouteContracts } from "./route-contracts";
|
|
57
57
|
export { validateEffectPolicies, validateJobPolicies } from "./effect-governance";
|
|
58
58
|
export { pullGraphqlSchema } from "./graphql-schema";
|