@cadenza.io/service 2.21.0 → 2.21.2
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-CRVK2HUv.d.mts} +46 -1
- package/dist/{Cadenza-Cq1mscQf.d.ts → Cadenza-CRVK2HUv.d.ts} +46 -1
- package/dist/browser/index.js +1369 -482
- package/dist/browser/index.js.map +1 -1
- package/dist/browser/index.mjs +1368 -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 +1480 -568
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +1476 -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,11 @@ 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;
|
|
378
|
+
private authorityBootstrapRecoveryActive;
|
|
374
379
|
handleInstanceUpdateTask: Task;
|
|
375
380
|
handleTransportUpdateTask: Task;
|
|
376
381
|
handleGlobalSignalRegistrationTask: Task;
|
|
@@ -413,6 +418,13 @@ declare class ServiceRegistry {
|
|
|
413
418
|
private getAuthorityBootstrapRestTarget;
|
|
414
419
|
hasAuthorityBootstrapHandshakeEstablished(): boolean;
|
|
415
420
|
private invalidateAuthorityBootstrapHandshake;
|
|
421
|
+
private clearAuthorityBootstrapHandshakeRetryTimer;
|
|
422
|
+
private invalidateAuthorityBootstrapHandshakeRetryState;
|
|
423
|
+
private markAuthorityBootstrapHandshakeSatisfied;
|
|
424
|
+
private buildJitteredAuthorityBootstrapHandshakeRetryDelayMs;
|
|
425
|
+
private scheduleAuthorityBootstrapHandshakeRetry;
|
|
426
|
+
private restartAuthorityBootstrapHandshakeRetryChain;
|
|
427
|
+
private restartAuthorityBootstrapRecovery;
|
|
416
428
|
private requestAuthorityBootstrapHandshake;
|
|
417
429
|
private invokeAuthorityBootstrapRoutine;
|
|
418
430
|
private registerRemoteIntentDeputy;
|
|
@@ -482,6 +494,8 @@ declare class ServiceRegistry {
|
|
|
482
494
|
private recordRoutingFailure;
|
|
483
495
|
private clearRoutingCooldown;
|
|
484
496
|
private hasRouteableInstanceForRouting;
|
|
497
|
+
private hasPendingRouteableInstanceForSelection;
|
|
498
|
+
private maybeSchedulePendingRouteSelectionRetry;
|
|
485
499
|
private refreshRoutingCooldownsForService;
|
|
486
500
|
private buildTransportFailureKey;
|
|
487
501
|
private clearTransportFailureState;
|
|
@@ -1141,6 +1155,7 @@ declare class CadenzaService {
|
|
|
1141
1155
|
protected static isBootstrapped: boolean;
|
|
1142
1156
|
protected static serviceCreated: boolean;
|
|
1143
1157
|
protected static bootstrapSyncCompleted: boolean;
|
|
1158
|
+
protected static bootstrapSyncCompletedAt: number;
|
|
1144
1159
|
protected static bootstrapSignalRegistrationsCompleted: boolean;
|
|
1145
1160
|
protected static bootstrapIntentRegistrationsCompleted: boolean;
|
|
1146
1161
|
protected static defaultDatabaseServiceName: string | null;
|
|
@@ -1149,9 +1164,17 @@ declare class CadenzaService {
|
|
|
1149
1164
|
protected static frontendSyncScheduled: boolean;
|
|
1150
1165
|
protected static serviceManifestRevision: number;
|
|
1151
1166
|
protected static lastPublishedServiceManifestHashes: Partial<Record<ServiceManifestPublicationLayer, string>>;
|
|
1167
|
+
protected static serviceManifestPublishedAt: Partial<Record<ServiceManifestPublicationLayer, number>>;
|
|
1152
1168
|
protected static serviceManifestPublicationInFlight: boolean;
|
|
1153
1169
|
protected static serviceManifestPublicationPendingReason: string | null;
|
|
1154
1170
|
protected static serviceManifestPublicationPendingLayer: ServiceManifestPublicationLayer | null;
|
|
1171
|
+
protected static serviceManifestPublicationRetryReason: string | null;
|
|
1172
|
+
protected static serviceManifestPublicationRetryLayer: ServiceManifestPublicationLayer | null;
|
|
1173
|
+
protected static serviceManifestPublicationRetryTimer: ReturnType<typeof setTimeout> | null;
|
|
1174
|
+
protected static serviceManifestPublicationRetryCount: number;
|
|
1175
|
+
protected static localServiceManifestDefinitionInserted: boolean;
|
|
1176
|
+
protected static localServiceManifestInstanceInserted: boolean;
|
|
1177
|
+
protected static initialServiceManifestPublicationRequested: boolean;
|
|
1155
1178
|
private static shutdownHandlersRegistered;
|
|
1156
1179
|
private static shutdownInFlight;
|
|
1157
1180
|
private static shutdownHandlerCleanup;
|
|
@@ -1161,11 +1184,27 @@ declare class CadenzaService {
|
|
|
1161
1184
|
private static replayRegisteredTaskSignalObservations;
|
|
1162
1185
|
private static replayRegisteredTaskGraphMetadata;
|
|
1163
1186
|
private static normalizeServiceManifestPublicationLayer;
|
|
1187
|
+
private static clampServiceManifestPublicationLayer;
|
|
1164
1188
|
private static mergeServiceManifestPublicationRequest;
|
|
1189
|
+
private static getServiceManifestPublicationGate;
|
|
1165
1190
|
private static requestServiceManifestPublication;
|
|
1166
1191
|
private static scheduleServiceManifestPublicationRetry;
|
|
1192
|
+
private static shouldPublishBusinessManifestForTaskContext;
|
|
1193
|
+
private static isRoutingCriticalManifestSignalName;
|
|
1194
|
+
private static isRoutingCriticalManifestIntentName;
|
|
1195
|
+
private static isRoutingCriticalManifestTask;
|
|
1196
|
+
private static hasRoutingCriticalManifestBindingInContext;
|
|
1197
|
+
private static shouldPublishBusinessManifestForHelperContext;
|
|
1198
|
+
private static shouldPublishBusinessManifestForGlobalContext;
|
|
1199
|
+
private static shouldPublishBusinessManifestForRoutineContext;
|
|
1200
|
+
private static shouldRequestServiceManifestPublicationForSignal;
|
|
1201
|
+
private static maybeRequestInitialServiceManifestPublication;
|
|
1202
|
+
private static scheduleInitialServiceManifestPublicationFallback;
|
|
1167
1203
|
private static publishServiceManifestIfNeeded;
|
|
1168
1204
|
private static ensureServiceManifestPublicationTasks;
|
|
1205
|
+
private static isLocalAuthorityService;
|
|
1206
|
+
private static canPublishServiceManifestToAuthority;
|
|
1207
|
+
private static shouldRequireAuthorityBootstrapHandshakeForManifestPublication;
|
|
1169
1208
|
private static buildLegacyLocalCadenzaDBTaskName;
|
|
1170
1209
|
private static buildGeneratedLocalCadenzaDBTaskName;
|
|
1171
1210
|
/**
|
|
@@ -1592,6 +1631,12 @@ declare class CadenzaService {
|
|
|
1592
1631
|
* ```
|
|
1593
1632
|
*/
|
|
1594
1633
|
static createTask(name: string, func: TaskFunction, description?: string, options?: TaskOptions): Task;
|
|
1634
|
+
static createHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1635
|
+
static createMetaHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1636
|
+
static createHelperFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createHelperFromDefinition>[0]): HelperDefinition;
|
|
1637
|
+
static createGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1638
|
+
static createMetaGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1639
|
+
static createGlobalFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createGlobalFromDefinition>[0]): GlobalDefinition;
|
|
1595
1640
|
/**
|
|
1596
1641
|
* Creates a meta task with the specified name, functionality, description, and options.
|
|
1597
1642
|
* 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,11 @@ 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;
|
|
378
|
+
private authorityBootstrapRecoveryActive;
|
|
374
379
|
handleInstanceUpdateTask: Task;
|
|
375
380
|
handleTransportUpdateTask: Task;
|
|
376
381
|
handleGlobalSignalRegistrationTask: Task;
|
|
@@ -413,6 +418,13 @@ declare class ServiceRegistry {
|
|
|
413
418
|
private getAuthorityBootstrapRestTarget;
|
|
414
419
|
hasAuthorityBootstrapHandshakeEstablished(): boolean;
|
|
415
420
|
private invalidateAuthorityBootstrapHandshake;
|
|
421
|
+
private clearAuthorityBootstrapHandshakeRetryTimer;
|
|
422
|
+
private invalidateAuthorityBootstrapHandshakeRetryState;
|
|
423
|
+
private markAuthorityBootstrapHandshakeSatisfied;
|
|
424
|
+
private buildJitteredAuthorityBootstrapHandshakeRetryDelayMs;
|
|
425
|
+
private scheduleAuthorityBootstrapHandshakeRetry;
|
|
426
|
+
private restartAuthorityBootstrapHandshakeRetryChain;
|
|
427
|
+
private restartAuthorityBootstrapRecovery;
|
|
416
428
|
private requestAuthorityBootstrapHandshake;
|
|
417
429
|
private invokeAuthorityBootstrapRoutine;
|
|
418
430
|
private registerRemoteIntentDeputy;
|
|
@@ -482,6 +494,8 @@ declare class ServiceRegistry {
|
|
|
482
494
|
private recordRoutingFailure;
|
|
483
495
|
private clearRoutingCooldown;
|
|
484
496
|
private hasRouteableInstanceForRouting;
|
|
497
|
+
private hasPendingRouteableInstanceForSelection;
|
|
498
|
+
private maybeSchedulePendingRouteSelectionRetry;
|
|
485
499
|
private refreshRoutingCooldownsForService;
|
|
486
500
|
private buildTransportFailureKey;
|
|
487
501
|
private clearTransportFailureState;
|
|
@@ -1141,6 +1155,7 @@ declare class CadenzaService {
|
|
|
1141
1155
|
protected static isBootstrapped: boolean;
|
|
1142
1156
|
protected static serviceCreated: boolean;
|
|
1143
1157
|
protected static bootstrapSyncCompleted: boolean;
|
|
1158
|
+
protected static bootstrapSyncCompletedAt: number;
|
|
1144
1159
|
protected static bootstrapSignalRegistrationsCompleted: boolean;
|
|
1145
1160
|
protected static bootstrapIntentRegistrationsCompleted: boolean;
|
|
1146
1161
|
protected static defaultDatabaseServiceName: string | null;
|
|
@@ -1149,9 +1164,17 @@ declare class CadenzaService {
|
|
|
1149
1164
|
protected static frontendSyncScheduled: boolean;
|
|
1150
1165
|
protected static serviceManifestRevision: number;
|
|
1151
1166
|
protected static lastPublishedServiceManifestHashes: Partial<Record<ServiceManifestPublicationLayer, string>>;
|
|
1167
|
+
protected static serviceManifestPublishedAt: Partial<Record<ServiceManifestPublicationLayer, number>>;
|
|
1152
1168
|
protected static serviceManifestPublicationInFlight: boolean;
|
|
1153
1169
|
protected static serviceManifestPublicationPendingReason: string | null;
|
|
1154
1170
|
protected static serviceManifestPublicationPendingLayer: ServiceManifestPublicationLayer | null;
|
|
1171
|
+
protected static serviceManifestPublicationRetryReason: string | null;
|
|
1172
|
+
protected static serviceManifestPublicationRetryLayer: ServiceManifestPublicationLayer | null;
|
|
1173
|
+
protected static serviceManifestPublicationRetryTimer: ReturnType<typeof setTimeout> | null;
|
|
1174
|
+
protected static serviceManifestPublicationRetryCount: number;
|
|
1175
|
+
protected static localServiceManifestDefinitionInserted: boolean;
|
|
1176
|
+
protected static localServiceManifestInstanceInserted: boolean;
|
|
1177
|
+
protected static initialServiceManifestPublicationRequested: boolean;
|
|
1155
1178
|
private static shutdownHandlersRegistered;
|
|
1156
1179
|
private static shutdownInFlight;
|
|
1157
1180
|
private static shutdownHandlerCleanup;
|
|
@@ -1161,11 +1184,27 @@ declare class CadenzaService {
|
|
|
1161
1184
|
private static replayRegisteredTaskSignalObservations;
|
|
1162
1185
|
private static replayRegisteredTaskGraphMetadata;
|
|
1163
1186
|
private static normalizeServiceManifestPublicationLayer;
|
|
1187
|
+
private static clampServiceManifestPublicationLayer;
|
|
1164
1188
|
private static mergeServiceManifestPublicationRequest;
|
|
1189
|
+
private static getServiceManifestPublicationGate;
|
|
1165
1190
|
private static requestServiceManifestPublication;
|
|
1166
1191
|
private static scheduleServiceManifestPublicationRetry;
|
|
1192
|
+
private static shouldPublishBusinessManifestForTaskContext;
|
|
1193
|
+
private static isRoutingCriticalManifestSignalName;
|
|
1194
|
+
private static isRoutingCriticalManifestIntentName;
|
|
1195
|
+
private static isRoutingCriticalManifestTask;
|
|
1196
|
+
private static hasRoutingCriticalManifestBindingInContext;
|
|
1197
|
+
private static shouldPublishBusinessManifestForHelperContext;
|
|
1198
|
+
private static shouldPublishBusinessManifestForGlobalContext;
|
|
1199
|
+
private static shouldPublishBusinessManifestForRoutineContext;
|
|
1200
|
+
private static shouldRequestServiceManifestPublicationForSignal;
|
|
1201
|
+
private static maybeRequestInitialServiceManifestPublication;
|
|
1202
|
+
private static scheduleInitialServiceManifestPublicationFallback;
|
|
1167
1203
|
private static publishServiceManifestIfNeeded;
|
|
1168
1204
|
private static ensureServiceManifestPublicationTasks;
|
|
1205
|
+
private static isLocalAuthorityService;
|
|
1206
|
+
private static canPublishServiceManifestToAuthority;
|
|
1207
|
+
private static shouldRequireAuthorityBootstrapHandshakeForManifestPublication;
|
|
1169
1208
|
private static buildLegacyLocalCadenzaDBTaskName;
|
|
1170
1209
|
private static buildGeneratedLocalCadenzaDBTaskName;
|
|
1171
1210
|
/**
|
|
@@ -1592,6 +1631,12 @@ declare class CadenzaService {
|
|
|
1592
1631
|
* ```
|
|
1593
1632
|
*/
|
|
1594
1633
|
static createTask(name: string, func: TaskFunction, description?: string, options?: TaskOptions): Task;
|
|
1634
|
+
static createHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1635
|
+
static createMetaHelper(name: string, func: HelperFunction, description?: string): HelperDefinition;
|
|
1636
|
+
static createHelperFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createHelperFromDefinition>[0]): HelperDefinition;
|
|
1637
|
+
static createGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1638
|
+
static createMetaGlobal(name: string, value: unknown, description?: string): GlobalDefinition;
|
|
1639
|
+
static createGlobalFromDefinition(definition: Parameters<typeof _cadenza_io_core__default.createGlobalFromDefinition>[0]): GlobalDefinition;
|
|
1595
1640
|
/**
|
|
1596
1641
|
* Creates a meta task with the specified name, functionality, description, and options.
|
|
1597
1642
|
* This is used for creating tasks that lives on the meta layer.
|