@cadenza.io/service 2.21.0 → 2.21.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/{Cadenza-Cq1mscQf.d.mts → Cadenza-gGtFW_Y-.d.mts} +45 -1
- package/dist/{Cadenza-Cq1mscQf.d.ts → Cadenza-gGtFW_Y-.d.ts} +45 -1
- package/dist/browser/index.js +1326 -482
- package/dist/browser/index.js.map +1 -1
- package/dist/browser/index.mjs +1325 -479
- package/dist/browser/index.mjs.map +1 -1
- package/dist/index.d.mts +8 -4
- package/dist/index.d.ts +8 -4
- package/dist/index.js +1437 -568
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1433 -568
- package/dist/index.mjs.map +1 -1
- package/dist/nuxt/index.d.mts +2 -2
- package/dist/nuxt/index.d.ts +2 -2
- package/dist/react/index.d.mts +2 -2
- package/dist/react/index.d.ts +2 -2
- package/dist/vue/index.d.mts +2 -2
- package/dist/vue/index.d.ts +2 -2
- package/package.json +4 -4
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Task, ThrottleTagGetter, Schema, GraphContext, AnyObject, InquiryOptions, TaskResult, GraphRoutine, SchemaDefinition, Actor, SignalBroker, InquiryBroker, GraphRunner, GraphRegistry, CadenzaMode, EmitOptions, Intent, RuntimeValidationPolicy, RuntimeValidationScope, TaskOptions, ActorSpec, ActorFactoryOptions, ActorDefinition, TaskFunction, DebounceOptions, DebounceTask, EphemeralTaskOptions, EphemeralTask } from '@cadenza.io/core';
|
|
1
|
+
import _cadenza_io_core__default, { Task, ThrottleTagGetter, Schema, GraphContext, AnyObject, InquiryOptions, TaskResult, GraphRoutine, SchemaDefinition, Actor, SignalBroker, InquiryBroker, GraphRunner, GraphRegistry, CadenzaMode, EmitOptions, Intent, RuntimeValidationPolicy, RuntimeValidationScope, TaskOptions, ActorSpec, ActorFactoryOptions, ActorDefinition, TaskFunction, HelperFunction, HelperDefinition, GlobalDefinition, DebounceOptions, DebounceTask, EphemeralTaskOptions, EphemeralTask } from '@cadenza.io/core';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Represents a task that delegates execution of a routine to a remote system or service.
|
|
@@ -371,6 +371,10 @@ declare class ServiceRegistry {
|
|
|
371
371
|
private knownGlobalSignalMaps;
|
|
372
372
|
private authorityBootstrapRoute;
|
|
373
373
|
private authorityBootstrapHandshakeInFlight;
|
|
374
|
+
private authorityBootstrapHandshakeRetryTimer;
|
|
375
|
+
private authorityBootstrapHandshakeRetryIndex;
|
|
376
|
+
private authorityBootstrapHandshakeRetryGeneration;
|
|
377
|
+
private authorityBootstrapHandshakeRetryReason;
|
|
374
378
|
handleInstanceUpdateTask: Task;
|
|
375
379
|
handleTransportUpdateTask: Task;
|
|
376
380
|
handleGlobalSignalRegistrationTask: Task;
|
|
@@ -413,6 +417,13 @@ declare class ServiceRegistry {
|
|
|
413
417
|
private getAuthorityBootstrapRestTarget;
|
|
414
418
|
hasAuthorityBootstrapHandshakeEstablished(): boolean;
|
|
415
419
|
private invalidateAuthorityBootstrapHandshake;
|
|
420
|
+
private clearAuthorityBootstrapHandshakeRetryTimer;
|
|
421
|
+
private invalidateAuthorityBootstrapHandshakeRetryState;
|
|
422
|
+
private markAuthorityBootstrapHandshakeSatisfied;
|
|
423
|
+
private buildJitteredAuthorityBootstrapHandshakeRetryDelayMs;
|
|
424
|
+
private scheduleAuthorityBootstrapHandshakeRetry;
|
|
425
|
+
private restartAuthorityBootstrapHandshakeRetryChain;
|
|
426
|
+
private restartAuthorityBootstrapRecovery;
|
|
416
427
|
private requestAuthorityBootstrapHandshake;
|
|
417
428
|
private invokeAuthorityBootstrapRoutine;
|
|
418
429
|
private registerRemoteIntentDeputy;
|
|
@@ -482,6 +493,8 @@ declare class ServiceRegistry {
|
|
|
482
493
|
private recordRoutingFailure;
|
|
483
494
|
private clearRoutingCooldown;
|
|
484
495
|
private hasRouteableInstanceForRouting;
|
|
496
|
+
private hasPendingRouteableInstanceForSelection;
|
|
497
|
+
private maybeSchedulePendingRouteSelectionRetry;
|
|
485
498
|
private refreshRoutingCooldownsForService;
|
|
486
499
|
private buildTransportFailureKey;
|
|
487
500
|
private clearTransportFailureState;
|
|
@@ -1141,6 +1154,7 @@ declare class CadenzaService {
|
|
|
1141
1154
|
protected static isBootstrapped: boolean;
|
|
1142
1155
|
protected static serviceCreated: boolean;
|
|
1143
1156
|
protected static bootstrapSyncCompleted: boolean;
|
|
1157
|
+
protected static bootstrapSyncCompletedAt: number;
|
|
1144
1158
|
protected static bootstrapSignalRegistrationsCompleted: boolean;
|
|
1145
1159
|
protected static bootstrapIntentRegistrationsCompleted: boolean;
|
|
1146
1160
|
protected static defaultDatabaseServiceName: string | null;
|
|
@@ -1149,9 +1163,17 @@ declare class CadenzaService {
|
|
|
1149
1163
|
protected static frontendSyncScheduled: boolean;
|
|
1150
1164
|
protected static serviceManifestRevision: number;
|
|
1151
1165
|
protected static lastPublishedServiceManifestHashes: Partial<Record<ServiceManifestPublicationLayer, string>>;
|
|
1166
|
+
protected static serviceManifestPublishedAt: Partial<Record<ServiceManifestPublicationLayer, number>>;
|
|
1152
1167
|
protected static serviceManifestPublicationInFlight: boolean;
|
|
1153
1168
|
protected static serviceManifestPublicationPendingReason: string | null;
|
|
1154
1169
|
protected static serviceManifestPublicationPendingLayer: ServiceManifestPublicationLayer | null;
|
|
1170
|
+
protected static serviceManifestPublicationRetryReason: string | null;
|
|
1171
|
+
protected static serviceManifestPublicationRetryLayer: ServiceManifestPublicationLayer | null;
|
|
1172
|
+
protected static serviceManifestPublicationRetryTimer: ReturnType<typeof setTimeout> | null;
|
|
1173
|
+
protected static serviceManifestPublicationRetryCount: number;
|
|
1174
|
+
protected static localServiceManifestDefinitionInserted: boolean;
|
|
1175
|
+
protected static localServiceManifestInstanceInserted: boolean;
|
|
1176
|
+
protected static initialServiceManifestPublicationRequested: boolean;
|
|
1155
1177
|
private static shutdownHandlersRegistered;
|
|
1156
1178
|
private static shutdownInFlight;
|
|
1157
1179
|
private static shutdownHandlerCleanup;
|
|
@@ -1161,11 +1183,27 @@ declare class CadenzaService {
|
|
|
1161
1183
|
private static replayRegisteredTaskSignalObservations;
|
|
1162
1184
|
private static replayRegisteredTaskGraphMetadata;
|
|
1163
1185
|
private static normalizeServiceManifestPublicationLayer;
|
|
1186
|
+
private static clampServiceManifestPublicationLayer;
|
|
1164
1187
|
private static mergeServiceManifestPublicationRequest;
|
|
1188
|
+
private static getServiceManifestPublicationGate;
|
|
1165
1189
|
private static requestServiceManifestPublication;
|
|
1166
1190
|
private static scheduleServiceManifestPublicationRetry;
|
|
1191
|
+
private static shouldPublishBusinessManifestForTaskContext;
|
|
1192
|
+
private static isRoutingCriticalManifestSignalName;
|
|
1193
|
+
private static isRoutingCriticalManifestIntentName;
|
|
1194
|
+
private static isRoutingCriticalManifestTask;
|
|
1195
|
+
private static hasRoutingCriticalManifestBindingInContext;
|
|
1196
|
+
private static shouldPublishBusinessManifestForHelperContext;
|
|
1197
|
+
private static shouldPublishBusinessManifestForGlobalContext;
|
|
1198
|
+
private static shouldPublishBusinessManifestForRoutineContext;
|
|
1199
|
+
private static shouldRequestServiceManifestPublicationForSignal;
|
|
1200
|
+
private static maybeRequestInitialServiceManifestPublication;
|
|
1201
|
+
private static scheduleInitialServiceManifestPublicationFallback;
|
|
1167
1202
|
private static publishServiceManifestIfNeeded;
|
|
1168
1203
|
private static ensureServiceManifestPublicationTasks;
|
|
1204
|
+
private static isLocalAuthorityService;
|
|
1205
|
+
private static canPublishServiceManifestToAuthority;
|
|
1206
|
+
private static shouldRequireAuthorityBootstrapHandshakeForManifestPublication;
|
|
1169
1207
|
private static buildLegacyLocalCadenzaDBTaskName;
|
|
1170
1208
|
private static buildGeneratedLocalCadenzaDBTaskName;
|
|
1171
1209
|
/**
|
|
@@ -1592,6 +1630,12 @@ declare class CadenzaService {
|
|
|
1592
1630
|
* ```
|
|
1593
1631
|
*/
|
|
1594
1632
|
static createTask(name: string, func: TaskFunction, description?: string, options?: TaskOptions): Task;
|
|
1633
|
+
static createHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1634
|
+
static createMetaHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1635
|
+
static createHelperFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createHelperFromDefinition>[0]): HelperDefinition;
|
|
1636
|
+
static createGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1637
|
+
static createMetaGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1638
|
+
static createGlobalFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createGlobalFromDefinition>[0]): GlobalDefinition;
|
|
1595
1639
|
/**
|
|
1596
1640
|
* Creates a meta task with the specified name, functionality, description, and options.
|
|
1597
1641
|
* This is used for creating tasks that lives on the meta layer.
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Task, ThrottleTagGetter, Schema, GraphContext, AnyObject, InquiryOptions, TaskResult, GraphRoutine, SchemaDefinition, Actor, SignalBroker, InquiryBroker, GraphRunner, GraphRegistry, CadenzaMode, EmitOptions, Intent, RuntimeValidationPolicy, RuntimeValidationScope, TaskOptions, ActorSpec, ActorFactoryOptions, ActorDefinition, TaskFunction, DebounceOptions, DebounceTask, EphemeralTaskOptions, EphemeralTask } from '@cadenza.io/core';
|
|
1
|
+
import _cadenza_io_core__default, { Task, ThrottleTagGetter, Schema, GraphContext, AnyObject, InquiryOptions, TaskResult, GraphRoutine, SchemaDefinition, Actor, SignalBroker, InquiryBroker, GraphRunner, GraphRegistry, CadenzaMode, EmitOptions, Intent, RuntimeValidationPolicy, RuntimeValidationScope, TaskOptions, ActorSpec, ActorFactoryOptions, ActorDefinition, TaskFunction, HelperFunction, HelperDefinition, GlobalDefinition, DebounceOptions, DebounceTask, EphemeralTaskOptions, EphemeralTask } from '@cadenza.io/core';
|
|
2
2
|
|
|
3
3
|
/**
|
|
4
4
|
* Represents a task that delegates execution of a routine to a remote system or service.
|
|
@@ -371,6 +371,10 @@ declare class ServiceRegistry {
|
|
|
371
371
|
private knownGlobalSignalMaps;
|
|
372
372
|
private authorityBootstrapRoute;
|
|
373
373
|
private authorityBootstrapHandshakeInFlight;
|
|
374
|
+
private authorityBootstrapHandshakeRetryTimer;
|
|
375
|
+
private authorityBootstrapHandshakeRetryIndex;
|
|
376
|
+
private authorityBootstrapHandshakeRetryGeneration;
|
|
377
|
+
private authorityBootstrapHandshakeRetryReason;
|
|
374
378
|
handleInstanceUpdateTask: Task;
|
|
375
379
|
handleTransportUpdateTask: Task;
|
|
376
380
|
handleGlobalSignalRegistrationTask: Task;
|
|
@@ -413,6 +417,13 @@ declare class ServiceRegistry {
|
|
|
413
417
|
private getAuthorityBootstrapRestTarget;
|
|
414
418
|
hasAuthorityBootstrapHandshakeEstablished(): boolean;
|
|
415
419
|
private invalidateAuthorityBootstrapHandshake;
|
|
420
|
+
private clearAuthorityBootstrapHandshakeRetryTimer;
|
|
421
|
+
private invalidateAuthorityBootstrapHandshakeRetryState;
|
|
422
|
+
private markAuthorityBootstrapHandshakeSatisfied;
|
|
423
|
+
private buildJitteredAuthorityBootstrapHandshakeRetryDelayMs;
|
|
424
|
+
private scheduleAuthorityBootstrapHandshakeRetry;
|
|
425
|
+
private restartAuthorityBootstrapHandshakeRetryChain;
|
|
426
|
+
private restartAuthorityBootstrapRecovery;
|
|
416
427
|
private requestAuthorityBootstrapHandshake;
|
|
417
428
|
private invokeAuthorityBootstrapRoutine;
|
|
418
429
|
private registerRemoteIntentDeputy;
|
|
@@ -482,6 +493,8 @@ declare class ServiceRegistry {
|
|
|
482
493
|
private recordRoutingFailure;
|
|
483
494
|
private clearRoutingCooldown;
|
|
484
495
|
private hasRouteableInstanceForRouting;
|
|
496
|
+
private hasPendingRouteableInstanceForSelection;
|
|
497
|
+
private maybeSchedulePendingRouteSelectionRetry;
|
|
485
498
|
private refreshRoutingCooldownsForService;
|
|
486
499
|
private buildTransportFailureKey;
|
|
487
500
|
private clearTransportFailureState;
|
|
@@ -1141,6 +1154,7 @@ declare class CadenzaService {
|
|
|
1141
1154
|
protected static isBootstrapped: boolean;
|
|
1142
1155
|
protected static serviceCreated: boolean;
|
|
1143
1156
|
protected static bootstrapSyncCompleted: boolean;
|
|
1157
|
+
protected static bootstrapSyncCompletedAt: number;
|
|
1144
1158
|
protected static bootstrapSignalRegistrationsCompleted: boolean;
|
|
1145
1159
|
protected static bootstrapIntentRegistrationsCompleted: boolean;
|
|
1146
1160
|
protected static defaultDatabaseServiceName: string | null;
|
|
@@ -1149,9 +1163,17 @@ declare class CadenzaService {
|
|
|
1149
1163
|
protected static frontendSyncScheduled: boolean;
|
|
1150
1164
|
protected static serviceManifestRevision: number;
|
|
1151
1165
|
protected static lastPublishedServiceManifestHashes: Partial<Record<ServiceManifestPublicationLayer, string>>;
|
|
1166
|
+
protected static serviceManifestPublishedAt: Partial<Record<ServiceManifestPublicationLayer, number>>;
|
|
1152
1167
|
protected static serviceManifestPublicationInFlight: boolean;
|
|
1153
1168
|
protected static serviceManifestPublicationPendingReason: string | null;
|
|
1154
1169
|
protected static serviceManifestPublicationPendingLayer: ServiceManifestPublicationLayer | null;
|
|
1170
|
+
protected static serviceManifestPublicationRetryReason: string | null;
|
|
1171
|
+
protected static serviceManifestPublicationRetryLayer: ServiceManifestPublicationLayer | null;
|
|
1172
|
+
protected static serviceManifestPublicationRetryTimer: ReturnType<typeof setTimeout> | null;
|
|
1173
|
+
protected static serviceManifestPublicationRetryCount: number;
|
|
1174
|
+
protected static localServiceManifestDefinitionInserted: boolean;
|
|
1175
|
+
protected static localServiceManifestInstanceInserted: boolean;
|
|
1176
|
+
protected static initialServiceManifestPublicationRequested: boolean;
|
|
1155
1177
|
private static shutdownHandlersRegistered;
|
|
1156
1178
|
private static shutdownInFlight;
|
|
1157
1179
|
private static shutdownHandlerCleanup;
|
|
@@ -1161,11 +1183,27 @@ declare class CadenzaService {
|
|
|
1161
1183
|
private static replayRegisteredTaskSignalObservations;
|
|
1162
1184
|
private static replayRegisteredTaskGraphMetadata;
|
|
1163
1185
|
private static normalizeServiceManifestPublicationLayer;
|
|
1186
|
+
private static clampServiceManifestPublicationLayer;
|
|
1164
1187
|
private static mergeServiceManifestPublicationRequest;
|
|
1188
|
+
private static getServiceManifestPublicationGate;
|
|
1165
1189
|
private static requestServiceManifestPublication;
|
|
1166
1190
|
private static scheduleServiceManifestPublicationRetry;
|
|
1191
|
+
private static shouldPublishBusinessManifestForTaskContext;
|
|
1192
|
+
private static isRoutingCriticalManifestSignalName;
|
|
1193
|
+
private static isRoutingCriticalManifestIntentName;
|
|
1194
|
+
private static isRoutingCriticalManifestTask;
|
|
1195
|
+
private static hasRoutingCriticalManifestBindingInContext;
|
|
1196
|
+
private static shouldPublishBusinessManifestForHelperContext;
|
|
1197
|
+
private static shouldPublishBusinessManifestForGlobalContext;
|
|
1198
|
+
private static shouldPublishBusinessManifestForRoutineContext;
|
|
1199
|
+
private static shouldRequestServiceManifestPublicationForSignal;
|
|
1200
|
+
private static maybeRequestInitialServiceManifestPublication;
|
|
1201
|
+
private static scheduleInitialServiceManifestPublicationFallback;
|
|
1167
1202
|
private static publishServiceManifestIfNeeded;
|
|
1168
1203
|
private static ensureServiceManifestPublicationTasks;
|
|
1204
|
+
private static isLocalAuthorityService;
|
|
1205
|
+
private static canPublishServiceManifestToAuthority;
|
|
1206
|
+
private static shouldRequireAuthorityBootstrapHandshakeForManifestPublication;
|
|
1169
1207
|
private static buildLegacyLocalCadenzaDBTaskName;
|
|
1170
1208
|
private static buildGeneratedLocalCadenzaDBTaskName;
|
|
1171
1209
|
/**
|
|
@@ -1592,6 +1630,12 @@ declare class CadenzaService {
|
|
|
1592
1630
|
* ```
|
|
1593
1631
|
*/
|
|
1594
1632
|
static createTask(name: string, func: TaskFunction, description?: string, options?: TaskOptions): Task;
|
|
1633
|
+
static createHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1634
|
+
static createMetaHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1635
|
+
static createHelperFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createHelperFromDefinition>[0]): HelperDefinition;
|
|
1636
|
+
static createGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1637
|
+
static createMetaGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1638
|
+
static createGlobalFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createGlobalFromDefinition>[0]): GlobalDefinition;
|
|
1595
1639
|
/**
|
|
1596
1640
|
* Creates a meta task with the specified name, functionality, description, and options.
|
|
1597
1641
|
* This is used for creating tasks that lives on the meta layer.
|