@vendure/cloud-config 0.3.2 → 0.4.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/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -1
- package/dist/index.js.map +1 -1
- package/dist/platform-capabilities.d.ts +1 -1
- package/dist/platform-capabilities.d.ts.map +1 -1
- package/dist/platform-capabilities.js +4 -0
- package/dist/platform-capabilities.js.map +1 -1
- package/dist/plugin-attribution.d.ts +1 -0
- package/dist/plugin-attribution.d.ts.map +1 -1
- package/dist/plugin-attribution.js +7 -3
- package/dist/plugin-attribution.js.map +1 -1
- package/dist/tenant-workflows.d.ts +44 -0
- package/dist/tenant-workflows.d.ts.map +1 -0
- package/dist/tenant-workflows.js +219 -0
- package/dist/tenant-workflows.js.map +1 -0
- package/package.json +4 -4
package/dist/index.d.ts
CHANGED
|
@@ -5,7 +5,7 @@ export type { CloudApiOptions, CloudAssetOptions, CloudAuthOptions, CloudConfig,
|
|
|
5
5
|
export { PLATFORM_OWNED_FIELDS, findPlatformOwnedField, type PlatformOwnedField, type PlatformOwnedFieldPath, } from "./platform-fields.js";
|
|
6
6
|
export { DuplicatePlatformCapabilityError, MissingPlatformCapabilityError, PLATFORM_CAPABILITIES, cloudPluginsForCapabilities, type PlatformCapability, type PlatformCapabilityPlugins, } from "./platform-capabilities.js";
|
|
7
7
|
export { PlatformFieldSetByConfigError, listPlatformOwnedFieldsSetIn, } from "./runtime-backstop.js";
|
|
8
|
-
export { PlatformFieldSetByPluginError, PLUGIN_CONFIGURATION_METADATA_KEY, assertNoCustomerPluginWroteAPlatformField, pluginName, recordPlatformFieldWrites, type ExtensionOfPlugin, type PendingPlatformFieldWrites, type PlatformFieldWrite, type PluginConstructor, type PluginLike, } from "./plugin-attribution.js";
|
|
8
|
+
export { PlatformFieldSetByPluginError, PLUGIN_CONFIGURATION_METADATA_KEY, assertNoCustomerPluginWroteAPlatformField, pluginName, pluginTarget, recordPlatformFieldWrites, type ExtensionOfPlugin, type PendingPlatformFieldWrites, type PlatformFieldWrite, type PluginConstructor, type PluginLike, } from "./plugin-attribution.js";
|
|
9
9
|
export { CLOUD_PLUGIN_COMPATIBILITY, composeCloudConfig, PlatformFieldOverwrittenError, applyPlatformFields, assertPlatformFieldsHold, hoistCloudPluginsLast, mergeDashboardConfigWithDefaults, platformDefaultFieldValues, type ComposeCloudConfigOptions, type DashboardConfigDefaults, type PlatformFieldValues, } from "./composition.js";
|
|
10
10
|
export { CLOUD_ASSET_ROUTE, CLOUD_ASSET_SERVER_PLUGIN_KIND, CloudAssetServerPlugin, MAX_IMAGE_TRANSFORM_DIMENSION, PLATFORM_SUPPLIED_ASSET_SERVER_OPTIONS, resolveAssetServerSettings, type CloudAssetServerPluginOptions, type CloudAssetServerSettings, type CustomerAssetServerOptions, } from "./cloud-asset-server-plugin.js";
|
|
11
11
|
export { CLOUD_DASHBOARD_PLUGIN_KIND, CloudDashboardPlugin, DEFAULT_DASHBOARD_ROUTE, InvalidDashboardRouteError, PLATFORM_SUPPLIED_DASHBOARD_OPTIONS, resolveDashboardSettings, type CloudDashboardPluginOptions, type CloudDashboardSettings, } from "./cloud-dashboard-plugin.js";
|
|
@@ -13,5 +13,6 @@ export { declareCloudPlugin, isCloudPluginDeclaration, listCloudPluginDeclaratio
|
|
|
13
13
|
export { SUPERSEDED_PLUGINS, SupersededPluginDeclaredError, assertNoSupersededPluginDeclared, findSupersededPlugin, type SupersededPlugin, type SupersededPluginDeclaration, } from "./superseded-plugins.js";
|
|
14
14
|
export { MissingSecretsError, assertNoMissingSecrets, listDeclaredSecrets, listMissingSecrets, redactSecrets, secret, } from "./secrets.js";
|
|
15
15
|
export { installOutboundHostCheck, type OutboundHostCheckOptions, type UndeclaredHostReport, type UndeclaredHostReporter, } from "./outbound-hosts.js";
|
|
16
|
+
export { DuplicateTenantWorkflowError, InvalidTenantWorkflowError, LateTenantWorkflowDeclarationError, RESERVED_TENANT_WORKFLOW_NAME_PREFIX, TenantWorkflowDeclarationError, TenantWorkflowRegistrySealedTwiceError, TenantWorkflowsAlreadyDeclaredError, declareTenantWorkflows, sealTenantWorkflowRegistry, sealedTenantWorkflowRegistry, type InvalidTenantWorkflowReason, type RegisteredTenantWorkflow, type SealedTenantWorkflowRegistry, type TenantWorkflow, type TenantWorkflowDefinition, } from "./tenant-workflows.js";
|
|
16
17
|
export { CloudConfigError } from "./errors.js";
|
|
17
18
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,eAAe,EACf,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,GACvB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,gCAAgC,EAChC,4BAA4B,EAC5B,sBAAsB,EACtB,kBAAkB,EAClB,0BAA0B,EAC1B,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,GACxB,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,yBAAyB,EACzB,qCAAqC,EACrC,8BAA8B,EAC9B,KAAK,eAAe,EACpB,KAAK,cAAc,EACnB,KAAK,aAAa,GACnB,MAAM,iBAAiB,CAAC;AACzB,YAAY,EACV,eAAe,EACf,iBAAiB,EACjB,gBAAgB,EAChB,WAAW,EACX,oBAAoB,EACpB,qBAAqB,EACrB,kBAAkB,EAClB,oBAAoB,EACpB,aAAa,GACd,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,qBAAqB,EACrB,sBAAsB,EACtB,KAAK,kBAAkB,EACvB,KAAK,sBAAsB,GAC5B,MAAM,sBAAsB,CAAC;AAC9B,OAAO,EACL,gCAAgC,EAChC,8BAA8B,EAC9B,qBAAqB,EACrB,2BAA2B,EAC3B,KA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zB,KAAK,sBAAsB,GAC5B,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,4BAA4B,EAC5B,0BAA0B,EAC1B,kCAAkC,EAClC,oCAAoC,EACpC,8BAA8B,EAC9B,sCAAsC,EACtC,mCAAmC,EACnC,sBAAsB,EACtB,0BAA0B,EAC1B,4BAA4B,EAC5B,KAAK,2BAA2B,EAChC,KAAK,wBAAwB,EAC7B,KAAK,4BAA4B,EACjC,KAAK,cAAc,EACnB,KAAK,wBAAwB,GAC9B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -4,7 +4,7 @@ export { InvalidMigrationNameError, MigrationGlobMatchedNoMigrationsError, Migra
|
|
|
4
4
|
export { PLATFORM_OWNED_FIELDS, findPlatformOwnedField, } from "./platform-fields.js";
|
|
5
5
|
export { DuplicatePlatformCapabilityError, MissingPlatformCapabilityError, PLATFORM_CAPABILITIES, cloudPluginsForCapabilities, } from "./platform-capabilities.js";
|
|
6
6
|
export { PlatformFieldSetByConfigError, listPlatformOwnedFieldsSetIn, } from "./runtime-backstop.js";
|
|
7
|
-
export { PlatformFieldSetByPluginError, PLUGIN_CONFIGURATION_METADATA_KEY, assertNoCustomerPluginWroteAPlatformField, pluginName, recordPlatformFieldWrites, } from "./plugin-attribution.js";
|
|
7
|
+
export { PlatformFieldSetByPluginError, PLUGIN_CONFIGURATION_METADATA_KEY, assertNoCustomerPluginWroteAPlatformField, pluginName, pluginTarget, recordPlatformFieldWrites, } from "./plugin-attribution.js";
|
|
8
8
|
export { CLOUD_PLUGIN_COMPATIBILITY, composeCloudConfig, PlatformFieldOverwrittenError, applyPlatformFields, assertPlatformFieldsHold, hoistCloudPluginsLast, mergeDashboardConfigWithDefaults, platformDefaultFieldValues, } from "./composition.js";
|
|
9
9
|
export { CLOUD_ASSET_ROUTE, CLOUD_ASSET_SERVER_PLUGIN_KIND, CloudAssetServerPlugin, MAX_IMAGE_TRANSFORM_DIMENSION, PLATFORM_SUPPLIED_ASSET_SERVER_OPTIONS, resolveAssetServerSettings, } from "./cloud-asset-server-plugin.js";
|
|
10
10
|
export { CLOUD_DASHBOARD_PLUGIN_KIND, CloudDashboardPlugin, DEFAULT_DASHBOARD_ROUTE, InvalidDashboardRouteError, PLATFORM_SUPPLIED_DASHBOARD_OPTIONS, resolveDashboardSettings, } from "./cloud-dashboard-plugin.js";
|
|
@@ -12,5 +12,6 @@ export { declareCloudPlugin, isCloudPluginDeclaration, listCloudPluginDeclaratio
|
|
|
12
12
|
export { SUPERSEDED_PLUGINS, SupersededPluginDeclaredError, assertNoSupersededPluginDeclared, findSupersededPlugin, } from "./superseded-plugins.js";
|
|
13
13
|
export { MissingSecretsError, assertNoMissingSecrets, listDeclaredSecrets, listMissingSecrets, redactSecrets, secret, } from "./secrets.js";
|
|
14
14
|
export { installOutboundHostCheck, } from "./outbound-hosts.js";
|
|
15
|
+
export { DuplicateTenantWorkflowError, InvalidTenantWorkflowError, LateTenantWorkflowDeclarationError, RESERVED_TENANT_WORKFLOW_NAME_PREFIX, TenantWorkflowDeclarationError, TenantWorkflowRegistrySealedTwiceError, TenantWorkflowsAlreadyDeclaredError, declareTenantWorkflows, sealTenantWorkflowRegistry, sealedTenantWorkflowRegistry, } from "./tenant-workflows.js";
|
|
15
16
|
export { CloudConfigError } from "./errors.js";
|
|
16
17
|
//# sourceMappingURL=index.js.map
|
package/dist/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,eAAe,GAGhB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,gCAAgC,EAChC,4BAA4B,EAC5B,sBAAsB,EACtB,kBAAkB,EAClB,0BAA0B,GAK3B,MAAM,wBAAwB,CAAC;AAChC,OAAO,EACL,yBAAyB,EACzB,qCA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AA6B,EAC7B,gCAAgC,EAChC,oBAAoB,GAGrB,MAAM,yBAAyB,CAAC;AACjC,OAAO,EACL,mBAAmB,EACnB,sBAAsB,EACtB,mBAAmB,EACnB,kBAAkB,EAClB,aAAa,EACb,MAAM,GACP,MAAM,cAAc,CAAC;AACtB,OAAO,EACL,wBAAwB,GAIzB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACL,4BAA4B,EAC5B,0BAA0B,EAC1B,kCAAkC,EAClC,oCAAoC,EACpC,8BAA8B,EAC9B,sCAAsC,EACtC,mCAAmC,EACnC,sBAAsB,EACtB,0BAA0B,EAC1B,4BAA4B,GAM7B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { CloudConfigError } from "./errors.js";
|
|
2
2
|
import { type PluginLike } from "./plugin-attribution.js";
|
|
3
|
-
export declare const PLATFORM_CAPABILITIES: readonly ["cache", "jobQueue", "scheduler", "dashboard", "assets"];
|
|
3
|
+
export declare const PLATFORM_CAPABILITIES: readonly ["cache", "jobQueue", "scheduler", "dashboard", "assets", "durableExecution"];
|
|
4
4
|
export type PlatformCapability = (typeof PLATFORM_CAPABILITIES)[number];
|
|
5
5
|
export type PlatformCapabilityPlugins = Record<PlatformCapability, PluginLike>;
|
|
6
6
|
export declare class MissingPlatformCapabilityError extends CloudConfigError {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"platform-capabilities.d.ts","sourceRoot":"","sources":["../src/platform-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,KAAK,UAAU,EAAc,MAAM,yBAAyB,CAAC;AActE,eAAO,MAAM,qBAAqB,
|
|
1
|
+
{"version":3,"file":"platform-capabilities.d.ts","sourceRoot":"","sources":["../src/platform-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,KAAK,UAAU,EAAc,MAAM,yBAAyB,CAAC;AActE,eAAO,MAAM,qBAAqB,wFAUxB,CAAC;AAEX,MAAM,MAAM,kBAAkB,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAGxE,MAAM,MAAM,yBAAyB,GAAG,MAAM,CAAC,kBAAkB,EAAE,UAAU,CAAC,CAAC;AAE/E,qBAAa,8BAA+B,SAAQ,gBAAgB;IAClE,QAAQ,CAAC,YAAY,EAAE,SAAS,kBAAkB,EAAE,CAAC;gBAEzC,YAAY,EAAE,SAAS,kBAAkB,EAAE;CAMxD;AAED,qBAAa,gCAAiC,SAAQ,gBAAgB;IACpE,QAAQ,CAAC,YAAY,EAAE,SAAS,kBAAkB,EAAE,CAAC;gBAEzC,YAAY,EAAE,SAAS,kBAAkB,EAAE,EAAE,MAAM,EAAE,MAAM;CAMxE;AAWD,wBAAgB,2BAA2B,CACzC,eAAe,EAAE,yBAAyB,GACzC,UAAU,EAAE,CAmBd"}
|
|
@@ -18,6 +18,10 @@ export const PLATFORM_CAPABILITIES = [
|
|
|
18
18
|
"scheduler",
|
|
19
19
|
"dashboard",
|
|
20
20
|
"assets",
|
|
21
|
+
// Durable workflows in the customer's own database (ADR-0060). The managed runtime supplies the
|
|
22
|
+
// binding and the local runtime the substitute; in both, an environment whose code declares no
|
|
23
|
+
// workflow runs no executor and pays nothing for the entry being here.
|
|
24
|
+
"durableExecution",
|
|
21
25
|
];
|
|
22
26
|
export class MissingPlatformCapabilityError extends CloudConfigError {
|
|
23
27
|
capabilities;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"platform-capabilities.js","sourceRoot":"","sources":["../src/platform-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAmB,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAEtE,iGAAiG;AACjG,6FAA6F;AAC7F,kGAAkG;AAClG,EAAE;AACF,gGAAgG;AAChG,8FAA8F;AAC9F,iGAAiG;AACjG,+FAA+F;AAC/F,wCAAwC;AACxC,EAAE;AACF,gGAAgG;AAChG,iEAAiE;AACjE,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC,OAAO;IACP,UAAU;IACV,WAAW;IACX,WAAW;IACX,QAAQ;
|
|
1
|
+
{"version":3,"file":"platform-capabilities.js","sourceRoot":"","sources":["../src/platform-capabilities.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAmB,UAAU,EAAE,MAAM,yBAAyB,CAAC;AAEtE,iGAAiG;AACjG,6FAA6F;AAC7F,kGAAkG;AAClG,EAAE;AACF,gGAAgG;AAChG,8FAA8F;AAC9F,iGAAiG;AACjG,+FAA+F;AAC/F,wCAAwC;AACxC,EAAE;AACF,gGAAgG;AAChG,iEAAiE;AACjE,MAAM,CAAC,MAAM,qBAAqB,GAAG;IACnC,OAAO;IACP,UAAU;IACV,WAAW;IACX,WAAW;IACX,QAAQ;IACR,gGAAgG;IAChG,+FAA+F;IAC/F,uEAAuE;IACvE,kBAAkB;CACV,CAAC;AAOX,MAAM,OAAO,8BAA+B,SAAQ,gBAAgB;IACzD,YAAY,CAAgC;IAErD,YAAY,YAA2C;QACrD,KAAK,CACH,sDAAsD,YAAY,CAAC,IAAI,CAAC,IAAI,CAAC,8NAA8N,CAC5S,CAAC;QACF,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;IACnC,CAAC;CACF;AAED,MAAM,OAAO,gCAAiC,SAAQ,gBAAgB;IAC3D,YAAY,CAAgC;IAErD,YAAY,YAA2C,EAAE,MAAc;QACrE,KAAK,CACH,kBAAkB,YAAY,CAAC,IAAI,CAAC,OAAO,CAAC,wCAAwC,MAAM,qLAAqL,CAChR,CAAC;QACF,IAAI,CAAC,YAAY,GAAG,YAAY,CAAC;IACnC,CAAC;CACF;AAED,4FAA4F;AAC5F,gCAAgC;AAChC,EAAE;AACF,iGAAiG;AACjG,oGAAoG;AACpG,mGAAmG;AACnG,kGAAkG;AAClG,6FAA6F;AAC7F,gEAAgE;AAChE,MAAM,UAAU,2BAA2B,CACzC,eAA0C;IAE1C,MAAM,OAAO,GAAG,qBAAqB,CAAC,MAAM,CAC1C,CAAC,UAAU,EAAE,EAAE,CAAC,eAAe,CAAC,UAAU,CAAC,KAAK,SAAS,CAC1D,CAAC;IACF,IAAI,OAAO,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACvB,MAAM,IAAI,8BAA8B,CAAC,OAAO,CAAC,CAAC;IACpD,CAAC;IAED,MAAM,UAAU,GAAG,IAAI,GAAG,EAAkC,CAAC;IAC7D,KAAK,MAAM,UAAU,IAAI,qBAAqB,EAAE,CAAC;QAC/C,MAAM,MAAM,GAAG,eAAe,CAAC,UAAU,CAAC,CAAC;QAC3C,MAAM,KAAK,GAAG,UAAU,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC;QACrC,IAAI,KAAK,KAAK,SAAS,EAAE,CAAC;YACxB,MAAM,IAAI,gCAAgC,CAAC,CAAC,KAAK,EAAE,UAAU,CAAC,EAAE,UAAU,CAAC,MAAM,CAAC,CAAC,CAAC;QACtF,CAAC;QACD,UAAU,CAAC,GAAG,CAAC,MAAM,EAAE,UAAU,CAAC,CAAC;IACrC,CAAC;IAED,OAAO,qBAAqB,CAAC,GAAG,CAAC,CAAC,UAAU,EAAE,EAAE,CAAC,eAAe,CAAC,UAAU,CAAC,CAAC,CAAC;AAChF,CAAC"}
|
|
@@ -14,6 +14,7 @@ export interface PlatformFieldWrite {
|
|
|
14
14
|
export type ExtensionOfPlugin = ReadonlyMap<PluginLike, {
|
|
15
15
|
readonly id: string;
|
|
16
16
|
}>;
|
|
17
|
+
export declare function pluginTarget(plugin: PluginLike): object;
|
|
17
18
|
export declare function pluginName(plugin: PluginLike): string;
|
|
18
19
|
export interface PendingPlatformFieldWrites {
|
|
19
20
|
readonly writes: readonly PlatformFieldWrite[];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin-attribution.d.ts","sourceRoot":"","sources":["../src/plugin-attribution.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE/C,OAAO,EAAyB,KAAK,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAWtF,eAAO,MAAM,iCAAiC,kBAAkB,CAAC;AAIjE,MAAM,MAAM,iBAAiB,GAAG,QAAQ,MAAM,GAAG,IAAI,EAAE,KAAK,EAAE,KAAK,OAAO,CAAC;AAC3E,MAAM,MAAM,UAAU,GAAG,iBAAiB,GAAG;IAAE,QAAQ,CAAC,MAAM,EAAE,iBAAiB,CAAA;CAAE,CAAC;AAEpF,MAAM,WAAW,kBAAkB;IACjC,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,kBAAkB,CAAC;IAI1B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAID,MAAM,MAAM,iBAAiB,GAAG,WAAW,CAAC,UAAU,EAAE;IAAE,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;
|
|
1
|
+
{"version":3,"file":"plugin-attribution.d.ts","sourceRoot":"","sources":["../src/plugin-attribution.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAE/C,OAAO,EAAyB,KAAK,kBAAkB,EAAE,MAAM,sBAAsB,CAAC;AAWtF,eAAO,MAAM,iCAAiC,kBAAkB,CAAC;AAIjE,MAAM,MAAM,iBAAiB,GAAG,QAAQ,MAAM,GAAG,IAAI,EAAE,KAAK,EAAE,KAAK,OAAO,CAAC;AAC3E,MAAM,MAAM,UAAU,GAAG,iBAAiB,GAAG;IAAE,QAAQ,CAAC,MAAM,EAAE,iBAAiB,CAAA;CAAE,CAAC;AAEpF,MAAM,WAAW,kBAAkB;IACjC,MAAM,EAAE,MAAM,CAAC;IACf,KAAK,EAAE,kBAAkB,CAAC;IAI1B,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAID,MAAM,MAAM,iBAAiB,GAAG,WAAW,CAAC,UAAU,EAAE;IAAE,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAMjF,wBAAgB,YAAY,CAAC,MAAM,EAAE,UAAU,GAAG,MAAM,CAKvD;AAED,wBAAgB,UAAU,CAAC,MAAM,EAAE,UAAU,GAAG,MAAM,CAIrD;AAsBD,MAAM,WAAW,0BAA0B;IACzC,QAAQ,CAAC,MAAM,EAAE,SAAS,kBAAkB,EAAE,CAAC;CAChD;AAED,wBAAgB,yBAAyB,CACvC,OAAO,EAAE,SAAS,UAAU,EAAE,EAC9B,WAAW,GAAE,iBAA6B,GACzC,0BAA0B,CA0C5B;AAYD,qBAAa,6BAA8B,SAAQ,gBAAgB;IACjE,QAAQ,CAAC,MAAM,EAAE,SAAS,kBAAkB,EAAE,CAAC;gBAEnC,MAAM,EAAE,SAAS,kBAAkB,EAAE;CAiBlD;AAED,wBAAgB,yCAAyC,CACvD,MAAM,EAAE,SAAS,kBAAkB,EAAE,EACrC,gBAAgB,EAAE,SAAS,MAAM,EAAE,GAClC,IAAI,CAKN"}
|
|
@@ -12,14 +12,18 @@ import { PLATFORM_OWNED_FIELDS } from "./platform-fields.js";
|
|
|
12
12
|
// A test pins this string to core's real value, so a rename there fails our build rather
|
|
13
13
|
// than silently disabling attribution.
|
|
14
14
|
export const PLUGIN_CONFIGURATION_METADATA_KEY = "configuration";
|
|
15
|
-
|
|
15
|
+
// Where a plugin's class-level state lives, for either shape core's plugins array carries. Exported
|
|
16
|
+
// because more than one mechanism has to agree on it: attribution writes configuration metadata here
|
|
17
|
+
// and the Cloud Runtime reads its durable workflow declarations off the same target, and a second
|
|
18
|
+
// copy of this rule is a wrapper whose plugin one of them silently walks past.
|
|
19
|
+
export function pluginTarget(plugin) {
|
|
16
20
|
if (typeof plugin === "object" && plugin !== null && "module" in plugin) {
|
|
17
21
|
return plugin.module;
|
|
18
22
|
}
|
|
19
23
|
return plugin;
|
|
20
24
|
}
|
|
21
25
|
export function pluginName(plugin) {
|
|
22
|
-
const target =
|
|
26
|
+
const target = pluginTarget(plugin);
|
|
23
27
|
const named = target.name;
|
|
24
28
|
return typeof named === "string" && named.length > 0 ? named : "an anonymous plugin";
|
|
25
29
|
}
|
|
@@ -35,7 +39,7 @@ export function recordPlatformFieldWrites(plugins, extensionOf = new Map()) {
|
|
|
35
39
|
// and the boot message reports writes the plugin did not make.
|
|
36
40
|
const wrappedTargets = new WeakSet();
|
|
37
41
|
for (const plugin of plugins) {
|
|
38
|
-
const target =
|
|
42
|
+
const target = pluginTarget(plugin);
|
|
39
43
|
if (wrappedTargets.has(target))
|
|
40
44
|
continue;
|
|
41
45
|
const original = Reflect.getMetadata(PLUGIN_CONFIGURATION_METADATA_KEY, target);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"plugin-attribution.js","sourceRoot":"","sources":["../src/plugin-attribution.ts"],"names":[],"mappings":"AAAA,OAAO,kBAAkB,CAAC;AAC1B,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,QAAQ,EAAE,MAAM,WAAW,CAAC;AACrC,OAAO,EAAE,qBAAqB,EAA2B,MAAM,sBAAsB,CAAC;AAEtF,wEAAwE;AACxE,6FAA6F;AAC7F,4FAA4F;AAC5F,6FAA6F;AAC7F,uFAAuF;AACvF,2DAA2D;AAC3D,EAAE;AACF,yFAAyF;AACzF,uCAAuC;AACvC,MAAM,CAAC,MAAM,iCAAiC,GAAG,eAAe,CAAC;AAoBjE,
|
|
1
|
+
{"version":3,"file":"plugin-attribution.js","sourceRoot":"","sources":["../src/plugin-attribution.ts"],"names":[],"mappings":"AAAA,OA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CAAC,MAAM,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,CAAC,gBAAgB,CAAC,QAAQ,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;IACrF,IAAI,SAAS,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACzB,MAAM,IAAI,6BAA6B,CAAC,SAAS,CAAC,CAAC;IACrD,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import { CloudConfigError } from "./errors.js";
|
|
2
|
+
import { type PluginLike } from "./plugin-attribution.js";
|
|
3
|
+
export type TenantWorkflow = (...args: never[]) => Promise<unknown>;
|
|
4
|
+
export declare const RESERVED_TENANT_WORKFLOW_NAME_PREFIX = "vendure-cloud.";
|
|
5
|
+
export interface TenantWorkflowDefinition {
|
|
6
|
+
readonly name: string;
|
|
7
|
+
readonly workflow: TenantWorkflow;
|
|
8
|
+
}
|
|
9
|
+
export interface RegisteredTenantWorkflow extends TenantWorkflowDefinition {
|
|
10
|
+
readonly declaredBy: string;
|
|
11
|
+
}
|
|
12
|
+
export interface SealedTenantWorkflowRegistry {
|
|
13
|
+
readonly workflows: readonly RegisteredTenantWorkflow[];
|
|
14
|
+
readonly digest: string;
|
|
15
|
+
}
|
|
16
|
+
export declare class TenantWorkflowDeclarationError extends CloudConfigError {
|
|
17
|
+
}
|
|
18
|
+
export type InvalidTenantWorkflowReason = "not-a-list" | "not-a-definition" | "name-not-a-string" | "no-name" | "untrimmed-name" | "name-contains-newline" | "reserved-name" | "not-a-function" | "plugin-not-extensible";
|
|
19
|
+
export declare class InvalidTenantWorkflowError extends TenantWorkflowDeclarationError {
|
|
20
|
+
readonly declaredBy: string;
|
|
21
|
+
readonly reason: InvalidTenantWorkflowReason;
|
|
22
|
+
constructor(declaredBy: string, reason: InvalidTenantWorkflowReason, detail: string);
|
|
23
|
+
}
|
|
24
|
+
export declare class DuplicateTenantWorkflowError extends TenantWorkflowDeclarationError {
|
|
25
|
+
readonly workflowName: string;
|
|
26
|
+
readonly declaredBy: string;
|
|
27
|
+
readonly conflictsWith: string;
|
|
28
|
+
constructor(workflowName: string, declaredBy: string, conflictsWith: string);
|
|
29
|
+
}
|
|
30
|
+
export declare class TenantWorkflowsAlreadyDeclaredError extends TenantWorkflowDeclarationError {
|
|
31
|
+
readonly declaredBy: string;
|
|
32
|
+
constructor(declaredBy: string);
|
|
33
|
+
}
|
|
34
|
+
export declare class LateTenantWorkflowDeclarationError extends TenantWorkflowDeclarationError {
|
|
35
|
+
readonly declaredBy: string;
|
|
36
|
+
constructor(declaredBy: string);
|
|
37
|
+
}
|
|
38
|
+
export declare class TenantWorkflowRegistrySealedTwiceError extends TenantWorkflowDeclarationError {
|
|
39
|
+
constructor();
|
|
40
|
+
}
|
|
41
|
+
export declare function declareTenantWorkflows(plugin: PluginLike, workflows: readonly TenantWorkflowDefinition[]): void;
|
|
42
|
+
export declare function sealTenantWorkflowRegistry(plugins: readonly PluginLike[]): SealedTenantWorkflowRegistry;
|
|
43
|
+
export declare function sealedTenantWorkflowRegistry(): SealedTenantWorkflowRegistry | undefined;
|
|
44
|
+
//# sourceMappingURL=tenant-workflows.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tenant-workflows.d.ts","sourceRoot":"","sources":["../src/tenant-workflows.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAE,KAAK,UAAU,EAA4B,MAAM,yBAAyB,CAAC;AAyBpF,MAAM,MAAM,cAAc,GAAG,CAAC,GAAG,IAAI,EAAE,KAAK,EAAE,KAAK,OAAO,CAAC,OAAO,CAAC,CAAC;AAMpE,eAAO,MAAM,oCAAoC,mBAAmB,CAAC;AAOrE,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,QAAQ,EAAE,cAAc,CAAC;CACnC;AAED,MAAM,WAAW,wBAAyB,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I,CA4BN;AAID,wBAAgB,0BAA0B,CACxC,OAAO,EAAE,SAAS,UAAU,EAAE,GAC7B,4BAA4B,CAuC9B;AAID,wBAAgB,4BAA4B,IAAI,4BAA4B,GAAG,SAAS,CAEvF"}
|
|
@@ -0,0 +1,219 @@
|
|
|
1
|
+
import { createHash } from "node:crypto";
|
|
2
|
+
import { CloudConfigError } from "./errors.js";
|
|
3
|
+
import { pluginName, pluginTarget } from "./plugin-attribution.js";
|
|
4
|
+
// How a tenant's durable workflows reach the executor the platform launches. ADR-0060's fourth open
|
|
5
|
+
// item owns the decision, the alternative it rejects and the reasoning; read it first.
|
|
6
|
+
//
|
|
7
|
+
// **It lives here rather than beside the executor because a customer has to be able to call it.**
|
|
8
|
+
// Under ADR-0046 the image supplies `@vendure-cloud/cloud-runtime` and a customer never installs it,
|
|
9
|
+
// so a declaration seam there reaches the platform's own plugins and nobody else's. This package is
|
|
10
|
+
// what `@vendure/cloud` re-exports, which is what a customer pins.
|
|
11
|
+
// Registered rather than module-local, for the reason the cloud config handle's symbol is
|
|
12
|
+
// (ADR-0043): a second copy of this package would otherwise write markers the sealing copy cannot
|
|
13
|
+
// read, and a plugin's workflows would never register with nothing reporting it.
|
|
14
|
+
const DECLARATION = Symbol.for("vendure-cloud.tenant-workflows");
|
|
15
|
+
// Whether any copy has sealed. Registered for the same reason the marker is, and a boolean rather
|
|
16
|
+
// than the registry itself so that reading it needs no validation: a second copy that began with
|
|
17
|
+
// its own flag unset would accept a declaration the sealing copy has already gone past, write it to
|
|
18
|
+
// the shared marker, and leave nobody to register it.
|
|
19
|
+
const SEALED = Symbol.for("vendure-cloud.tenant-workflows.sealed");
|
|
20
|
+
// Reserved for workflows the platform may come to register on a tenant executor. Those would not
|
|
21
|
+
// arrive through this seam, so the seal could not see the collision; refusing the prefix now costs
|
|
22
|
+
// one comparison, and reserving it after a customer has shipped a workflow under it would strand
|
|
23
|
+
// the recorded steps behind that name.
|
|
24
|
+
export const RESERVED_TENANT_WORKFLOW_NAME_PREFIX = "vendure-cloud.";
|
|
25
|
+
export class TenantWorkflowDeclarationError extends CloudConfigError {
|
|
26
|
+
}
|
|
27
|
+
export class InvalidTenantWorkflowError extends TenantWorkflowDeclarationError {
|
|
28
|
+
declaredBy;
|
|
29
|
+
reason;
|
|
30
|
+
constructor(declaredBy, reason, detail) {
|
|
31
|
+
super(`Vendure Cloud: ${declaredBy} declared durable workflows the platform cannot register. ${detail} Refusing to boot.\n`);
|
|
32
|
+
this.declaredBy = declaredBy;
|
|
33
|
+
this.reason = reason;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
// A workflow name is the identity its recorded steps are replayed against, so two workflows cannot
|
|
37
|
+
// share one. Two plugins claiming a name and one plugin claiming it twice are different mistakes to
|
|
38
|
+
// correct, so they are different sentences.
|
|
39
|
+
export class DuplicateTenantWorkflowError extends TenantWorkflowDeclarationError {
|
|
40
|
+
workflowName;
|
|
41
|
+
declaredBy;
|
|
42
|
+
conflictsWith;
|
|
43
|
+
constructor(workflowName, declaredBy, conflictsWith) {
|
|
44
|
+
const name = JSON.stringify(workflowName);
|
|
45
|
+
super(declaredBy === conflictsWith
|
|
46
|
+
? `Vendure Cloud: ${declaredBy} declared the durable workflow ${name} twice. A workflow name is the identity its recorded steps are replayed against, so two workflows cannot share one. Rename one of them. Refusing to boot.\n`
|
|
47
|
+
: `Vendure Cloud: the durable workflow ${name} was declared by both ${declaredBy} and ${conflictsWith}. A workflow name is the identity its recorded steps are replayed against, so two workflows cannot share one. Rename one of them. Refusing to boot.\n`);
|
|
48
|
+
this.workflowName = workflowName;
|
|
49
|
+
this.declaredBy = declaredBy;
|
|
50
|
+
this.conflictsWith = conflictsWith;
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
export class TenantWorkflowsAlreadyDeclaredError extends TenantWorkflowDeclarationError {
|
|
54
|
+
declaredBy;
|
|
55
|
+
constructor(declaredBy) {
|
|
56
|
+
super(`Vendure Cloud: ${declaredBy} declared its durable workflows twice. The second declaration would replace the first, so the workflows in it would never run. Declare them once. Refusing to boot.\n`);
|
|
57
|
+
this.declaredBy = declaredBy;
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
export class LateTenantWorkflowDeclarationError extends TenantWorkflowDeclarationError {
|
|
61
|
+
declaredBy;
|
|
62
|
+
constructor(declaredBy) {
|
|
63
|
+
super(`Vendure Cloud: ${declaredBy} declared durable workflows after the platform had read the registered set. Declare them where the plugin class is defined. Refusing to boot.\n`);
|
|
64
|
+
this.declaredBy = declaredBy;
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
export class TenantWorkflowRegistrySealedTwiceError extends TenantWorkflowDeclarationError {
|
|
68
|
+
constructor() {
|
|
69
|
+
super("Vendure Cloud: the durable workflow registry was sealed twice in one process. Two seals are two answers to which workflows this process runs, and only one of them reaches the executor. Refusing to boot.\n");
|
|
70
|
+
}
|
|
71
|
+
}
|
|
72
|
+
// This copy's answer, held so that a caller reaching the seal's result from a second call site does
|
|
73
|
+
// not have to seal again — which would refuse. It is undefined in a copy that did not seal, and the
|
|
74
|
+
// seal refuses in every copy once any of them has, so there is exactly one of these in a process.
|
|
75
|
+
let sealed;
|
|
76
|
+
function anyCopyHasSealed() {
|
|
77
|
+
return Reflect.get(globalThis, SEALED) === true;
|
|
78
|
+
}
|
|
79
|
+
function readDeclaration(target) {
|
|
80
|
+
// An own declaration only. A subclass of a plugin that declares workflows inherits the marker down
|
|
81
|
+
// the prototype chain, and both classes in one plugins array would then present the same names — a
|
|
82
|
+
// duplicate refusal against a boot that had nothing wrong with it. A subclass that wants workflows
|
|
83
|
+
// declares its own.
|
|
84
|
+
if (!Object.hasOwn(target, DECLARATION))
|
|
85
|
+
return undefined;
|
|
86
|
+
return target[DECLARATION];
|
|
87
|
+
}
|
|
88
|
+
export function declareTenantWorkflows(plugin, workflows) {
|
|
89
|
+
const declaredBy = pluginName(plugin);
|
|
90
|
+
if (anyCopyHasSealed()) {
|
|
91
|
+
throw new LateTenantWorkflowDeclarationError(declaredBy);
|
|
92
|
+
}
|
|
93
|
+
// `pluginTarget`, because a plugin reaches the array either as a class or as a DynamicModule
|
|
94
|
+
// wrapping one and the declaration belongs on the class. A declaration written on the wrapper
|
|
95
|
+
// would be missed by every read.
|
|
96
|
+
const target = pluginTarget(plugin);
|
|
97
|
+
if (readDeclaration(target) !== undefined) {
|
|
98
|
+
throw new TenantWorkflowsAlreadyDeclaredError(declaredBy);
|
|
99
|
+
}
|
|
100
|
+
// Checked here as well as at the seal, so that the stack names the file the declaration was
|
|
101
|
+
// written in.
|
|
102
|
+
const checked = assertIsRegistrable(workflows, declaredBy);
|
|
103
|
+
if (!Object.isExtensible(target)) {
|
|
104
|
+
// `defineProperty` would throw a bare TypeError naming neither the plugin nor what it was doing,
|
|
105
|
+
// which is the outcome the checks above exist to avoid.
|
|
106
|
+
throw new InvalidTenantWorkflowError(declaredBy, "plugin-not-extensible", "The plugin class is sealed or frozen, so the declaration cannot be attached to it.");
|
|
107
|
+
}
|
|
108
|
+
// Frozen through to each entry, for the reason the sealed set is. Non-enumerable, so the plugin
|
|
109
|
+
// spreads and serialises as it did before — a visible property would appear in anything that
|
|
110
|
+
// inspects the plugins array as configuration nobody wrote.
|
|
111
|
+
Object.defineProperty(target, DECLARATION, { value: checked });
|
|
112
|
+
}
|
|
113
|
+
// The one read, and the point after which nothing may be added. Every run mode may call it; the
|
|
114
|
+
// process that launches an executor registers exactly what it returns.
|
|
115
|
+
export function sealTenantWorkflowRegistry(plugins) {
|
|
116
|
+
if (anyCopyHasSealed()) {
|
|
117
|
+
throw new TenantWorkflowRegistrySealedTwiceError();
|
|
118
|
+
}
|
|
119
|
+
const byName = new Map();
|
|
120
|
+
// A plugins array holding one class twice, or a class and a DynamicModule around it, resolves to
|
|
121
|
+
// one declaration. Without this the second pass reports that declaration as a duplicate of itself
|
|
122
|
+
// and refuses a boot that had nothing wrong with it.
|
|
123
|
+
const read = new Set();
|
|
124
|
+
for (const plugin of plugins) {
|
|
125
|
+
const target = pluginTarget(plugin);
|
|
126
|
+
if (read.has(target))
|
|
127
|
+
continue;
|
|
128
|
+
read.add(target);
|
|
129
|
+
const declared = readDeclaration(target);
|
|
130
|
+
if (declared === undefined)
|
|
131
|
+
continue;
|
|
132
|
+
const declaredBy = pluginName(plugin);
|
|
133
|
+
// Validated again, because a declaration can arrive through the registered marker from a copy of
|
|
134
|
+
// this package that predates a rule added here, having never passed the checks above.
|
|
135
|
+
for (const definition of assertIsRegistrable(declared, declaredBy)) {
|
|
136
|
+
const first = byName.get(definition.name);
|
|
137
|
+
if (first !== undefined) {
|
|
138
|
+
throw new DuplicateTenantWorkflowError(definition.name, first.declaredBy, declaredBy);
|
|
139
|
+
}
|
|
140
|
+
byName.set(definition.name, Object.freeze({ ...definition, declaredBy }));
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
// Compared by code unit rather than with `localeCompare`, which reads the process's locale and
|
|
144
|
+
// would order two processes' identical sets differently.
|
|
145
|
+
const workflows = [...byName.values()].sort(compareByName);
|
|
146
|
+
sealed = Object.freeze({
|
|
147
|
+
workflows: Object.freeze(workflows),
|
|
148
|
+
digest: digestOf(workflows),
|
|
149
|
+
});
|
|
150
|
+
Reflect.set(globalThis, SEALED, true);
|
|
151
|
+
return sealed;
|
|
152
|
+
}
|
|
153
|
+
// What this copy sealed, for a caller that needs the set at launch and the digest beside the
|
|
154
|
+
// application version and does not hold the seal's return value at both.
|
|
155
|
+
export function sealedTenantWorkflowRegistry() {
|
|
156
|
+
return sealed;
|
|
157
|
+
}
|
|
158
|
+
function compareByName(a, b) {
|
|
159
|
+
if (a.name === b.name)
|
|
160
|
+
return 0;
|
|
161
|
+
return a.name < b.name ? -1 : 1;
|
|
162
|
+
}
|
|
163
|
+
// Newline-separated for the reason ADR-0061 separates its own two inputs with one: a name carrying a
|
|
164
|
+
// newline is refused, so no two sets of names compose one digest. SHA-256, lowercase hex, UTF-8 and
|
|
165
|
+
// the separator are all things two builds have to agree on, so a test pins the output against
|
|
166
|
+
// literals rather than recomputing it.
|
|
167
|
+
function digestOf(workflows) {
|
|
168
|
+
return createHash("sha256")
|
|
169
|
+
.update(workflows.map((workflow) => workflow.name).join("\n"), "utf8")
|
|
170
|
+
.digest("hex");
|
|
171
|
+
}
|
|
172
|
+
// A plugin written in JavaScript, or compiled against an older copy of this package, carries
|
|
173
|
+
// whatever it holds. So the list, each entry and each field are checked rather than the two fields
|
|
174
|
+
// TypeScript happens to name.
|
|
175
|
+
function assertIsRegistrable(workflows, declaredBy) {
|
|
176
|
+
if (!Array.isArray(workflows)) {
|
|
177
|
+
throw new InvalidTenantWorkflowError(declaredBy, "not-a-list", `The declaration is ${describeType(workflows)} rather than a list of workflows.`);
|
|
178
|
+
}
|
|
179
|
+
const checked = [];
|
|
180
|
+
const names = new Set();
|
|
181
|
+
for (const definition of workflows) {
|
|
182
|
+
if (typeof definition !== "object" || definition === null) {
|
|
183
|
+
throw new InvalidTenantWorkflowError(declaredBy, "not-a-definition", `The declaration holds ${describeType(definition)} where a workflow was expected.`);
|
|
184
|
+
}
|
|
185
|
+
const { name, workflow } = definition;
|
|
186
|
+
if (typeof name !== "string") {
|
|
187
|
+
throw new InvalidTenantWorkflowError(declaredBy, "name-not-a-string", `A workflow is named ${describeType(name)} rather than a string.`);
|
|
188
|
+
}
|
|
189
|
+
if (name.length === 0) {
|
|
190
|
+
throw new InvalidTenantWorkflowError(declaredBy, "no-name", "A workflow needs a name.");
|
|
191
|
+
}
|
|
192
|
+
if (name.trim() !== name) {
|
|
193
|
+
throw new InvalidTenantWorkflowError(declaredBy, "untrimmed-name", `The name ${JSON.stringify(name)} is surrounded by whitespace, which nothing reading a log line can see and which makes two names a person reads as one.`);
|
|
194
|
+
}
|
|
195
|
+
if (name.includes("\n")) {
|
|
196
|
+
throw new InvalidTenantWorkflowError(declaredBy, "name-contains-newline", `The name ${JSON.stringify(name)} contains a newline, which separates one name from the next in the registered set's identity.`);
|
|
197
|
+
}
|
|
198
|
+
if (name.startsWith(RESERVED_TENANT_WORKFLOW_NAME_PREFIX)) {
|
|
199
|
+
throw new InvalidTenantWorkflowError(declaredBy, "reserved-name", `The name ${JSON.stringify(name)} begins with ${JSON.stringify(RESERVED_TENANT_WORKFLOW_NAME_PREFIX)}, which Vendure Cloud reserves for its own workflows.`);
|
|
200
|
+
}
|
|
201
|
+
if (typeof workflow !== "function") {
|
|
202
|
+
throw new InvalidTenantWorkflowError(declaredBy, "not-a-function", `The workflow ${JSON.stringify(name)} is ${describeType(workflow)} rather than a function.`);
|
|
203
|
+
}
|
|
204
|
+
if (names.has(name)) {
|
|
205
|
+
throw new DuplicateTenantWorkflowError(name, declaredBy, declaredBy);
|
|
206
|
+
}
|
|
207
|
+
names.add(name);
|
|
208
|
+
checked.push(Object.freeze({ name, workflow }));
|
|
209
|
+
}
|
|
210
|
+
return Object.freeze(checked);
|
|
211
|
+
}
|
|
212
|
+
function describeType(value) {
|
|
213
|
+
if (value === null)
|
|
214
|
+
return "null";
|
|
215
|
+
if (Array.isArray(value))
|
|
216
|
+
return "a list";
|
|
217
|
+
return `a value of type ${typeof value}`;
|
|
218
|
+
}
|
|
219
|
+
//# sourceMappingURL=tenant-workflows.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"tenant-workflows.js","sourceRoot":"","sources":["../src/tenant-workflows.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AACzC,OAAO,EAAE,gBAAgB,EAAE,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAmB,UAAU,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAEpF,oGAAoG;AACpG,uFAAuF;AACvF,EAAE;AACF,kGAAkG;AAClG,qGAAqG;AACrG,oGAAoG;AACpG,mEAAmE;AAEnE,0FAA0F;AAC1F,kGAAkG;AAClG,iFAAiF;AACjF,MAAM,WAAW,GAAG,MAAM,CAAC,GAAG,CAAC,gCAAgC,CAAC,CAAC;AAEjE,kGAAk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,IAAI;QAAE,OAAO,MAAM,CAAC;IAClC,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;QAAE,OAAO,QAAQ,CAAC;IAC1C,OAAO,mBAAmB,OAAO,KAAK,EAAE,CAAC;AAC3C,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vendure/cloud-config",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.4.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "The Cloud Config interface a Vendure Cloud application is written against.",
|
|
6
6
|
"license": "MIT",
|
|
@@ -49,7 +49,7 @@
|
|
|
49
49
|
},
|
|
50
50
|
"dependencies": {
|
|
51
51
|
"reflect-metadata": "^0.2.2",
|
|
52
|
-
"tinyglobby": "^0.2.
|
|
52
|
+
"tinyglobby": "^0.2.17"
|
|
53
53
|
},
|
|
54
54
|
"peerDependencies": {
|
|
55
55
|
"@vendure/asset-server-plugin": "^3.7.0",
|
|
@@ -58,8 +58,8 @@
|
|
|
58
58
|
"devDependencies": {
|
|
59
59
|
"@types/node": "^22.20.1",
|
|
60
60
|
"@vendure-cloud/tsconfig": "workspace:*",
|
|
61
|
-
"@vendure/asset-server-plugin": "3.7.
|
|
62
|
-
"@vendure/core": "3.7.
|
|
61
|
+
"@vendure/asset-server-plugin": "3.7.3",
|
|
62
|
+
"@vendure/core": "3.7.3",
|
|
63
63
|
"typescript": "catalog:",
|
|
64
64
|
"vitest": "^3.2.6"
|
|
65
65
|
}
|