@dudousxd/nestjs-durable-core 0.91.0 → 0.93.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.cjs +255 -22
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +78 -8
- package/dist/index.d.ts +78 -8
- package/dist/index.js +249 -22
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -2671,6 +2671,14 @@ interface StartRunMessage {
|
|
|
2671
2671
|
tags?: string[] | undefined;
|
|
2672
2672
|
/** Typed, queryable run data to stamp on the run (same as {@link StartOptions.searchAttributes}). */
|
|
2673
2673
|
searchAttributes?: SearchAttributes | undefined;
|
|
2674
|
+
/**
|
|
2675
|
+
* The customer (data tenant) the run belongs to, as the tenant process sees it. Only a claim: the
|
|
2676
|
+
* control plane keeps it when the process's verified token grants `tenancy:*` or
|
|
2677
|
+
* `tenancy:<tenantId>` in its `capabilities`, else the run gets no customer tenant.
|
|
2678
|
+
*/
|
|
2679
|
+
tenantId?: string | undefined;
|
|
2680
|
+
/** The kind of {@link tenantId} (`organization`, `clinic`, …). */
|
|
2681
|
+
tenantKind?: string | undefined;
|
|
2674
2682
|
}
|
|
2675
2683
|
/**
|
|
2676
2684
|
* A tenant worker → control plane read/control request over the shared transport. Enqueued on
|
|
@@ -4083,6 +4091,36 @@ declare const CONTROL_FLOW_SIGNAL: unique symbol;
|
|
|
4083
4091
|
*/
|
|
4084
4092
|
declare function isWorkflowControlFlowSignal(error: unknown): boolean;
|
|
4085
4093
|
|
|
4094
|
+
/**
|
|
4095
|
+
* One loaded copy of this package: its version and the real path of its package root. Two copies are
|
|
4096
|
+
* the same when their roots are, so the `src` and `dist` builds of one checkout, the ESM and CJS
|
|
4097
|
+
* builds of one install, or one module evaluated twice (test runners reload modules) count once.
|
|
4098
|
+
*/
|
|
4099
|
+
interface DurableCopy {
|
|
4100
|
+
version: string;
|
|
4101
|
+
root: string;
|
|
4102
|
+
}
|
|
4103
|
+
/** What every loaded copy writes to, shared through `globalThis` so copies can see each other. */
|
|
4104
|
+
interface DurableCopyRegistry {
|
|
4105
|
+
copies: Map<string, DurableCopy>;
|
|
4106
|
+
/** Set once a module booted: a copy that loads after that cannot be caught at boot any more. */
|
|
4107
|
+
booted: boolean;
|
|
4108
|
+
}
|
|
4109
|
+
/** Thrown at boot when two different installs of `@dudousxd/nestjs-durable-core` are loaded in one process. */
|
|
4110
|
+
declare class DuplicateDurableCopyError extends Error {
|
|
4111
|
+
readonly copies: DurableCopy[];
|
|
4112
|
+
constructor(copies: DurableCopy[]);
|
|
4113
|
+
}
|
|
4114
|
+
/** Every distinct copy registered so far. */
|
|
4115
|
+
declare function durableCopies(registry?: DurableCopyRegistry): DurableCopy[];
|
|
4116
|
+
/** Throws {@link DuplicateDurableCopyError} when more than one distinct copy is registered. */
|
|
4117
|
+
declare function assertSingleDurableCopy(registry?: DurableCopyRegistry): void;
|
|
4118
|
+
/**
|
|
4119
|
+
* Called on the boot path (`DurableModule.forRoot` / `forRootAsync`): check now, and make any
|
|
4120
|
+
* distinct copy that loads later fail on load. Safe to call any number of times.
|
|
4121
|
+
*/
|
|
4122
|
+
declare function sealDurableCopies(registry?: DurableCopyRegistry): void;
|
|
4123
|
+
|
|
4086
4124
|
/**
|
|
4087
4125
|
* A start-time concurrency quota for ONE start: at most `limit` runs sharing `key` may be in flight
|
|
4088
4126
|
* (in `countStatuses`) at once; a start that would exceed it is rejected with
|
|
@@ -4262,6 +4300,12 @@ interface EngineTenancy {
|
|
|
4262
4300
|
filter(): TenantFilter;
|
|
4263
4301
|
/** Run `fn` with `tenant` restored as the ambient context tenant. */
|
|
4264
4302
|
run<T>(tenant: RunTenant, fn: () => T): T;
|
|
4303
|
+
/**
|
|
4304
|
+
* Run `fn` as durable's own work (a workflow turn, a recovery, a worker's step), where no request
|
|
4305
|
+
* asks for a tenant: a host whose tenancy requires one (`required: true`) must not reject a
|
|
4306
|
+
* missing tenant inside it. Optional: without it, `fn` runs as is.
|
|
4307
|
+
*/
|
|
4308
|
+
system?<T>(fn: () => T): T;
|
|
4265
4309
|
}
|
|
4266
4310
|
/** A row that may carry a tenant (a run, a schedule). */
|
|
4267
4311
|
interface TenantRow {
|
|
@@ -5215,9 +5259,10 @@ interface VerifiedTenant {
|
|
|
5215
5259
|
/** The tenant the token authenticates as. The responder trusts THIS, never the request body. */
|
|
5216
5260
|
tenant: string;
|
|
5217
5261
|
/**
|
|
5218
|
-
* Capabilities the token grants, if the issuer scopes them.
|
|
5219
|
-
*
|
|
5220
|
-
* call every verb, scoped to
|
|
5262
|
+
* Capabilities the token grants, if the issuer scopes them. `tenancy:*` or `tenancy:<id>` lets the
|
|
5263
|
+
* process claim that customer tenant for the runs it starts (see `StartRunMessage.tenantId`). The
|
|
5264
|
+
* run-request responder does not enforce them: a verified tenant can call every verb, scoped to
|
|
5265
|
+
* its own namespace.
|
|
5221
5266
|
*/
|
|
5222
5267
|
capabilities?: string[] | undefined;
|
|
5223
5268
|
}
|
|
@@ -5267,6 +5312,17 @@ declare function signTenantToken(tenant: string, secret: string, opts?: {
|
|
|
5267
5312
|
* responder does not enforce it yet, see {@link VerifiedTenant.capabilities}).
|
|
5268
5313
|
*/
|
|
5269
5314
|
declare function hmacTenantVerifier(secret: string | string[], capabilities?: string[]): TenantVerifier;
|
|
5315
|
+
/**
|
|
5316
|
+
* Verify a wire message's `tenant`: with a verifier, the {@link VerifiedTenant} it derives (`null` on
|
|
5317
|
+
* reject); without one, the wire value trusted verbatim, with no capabilities.
|
|
5318
|
+
*/
|
|
5319
|
+
declare function verifyWireTenant(wireTenant: string, verifyTenant: TenantVerifier | undefined): Promise<VerifiedTenant | null>;
|
|
5320
|
+
/**
|
|
5321
|
+
* Whether a verified tenant process may claim the customer `tenantId` for a run it starts: its
|
|
5322
|
+
* `capabilities` hold `tenancy:*` (any customer) or `tenancy:<tenantId>`. An unverified process (no
|
|
5323
|
+
* verifier) holds none, so it never may.
|
|
5324
|
+
*/
|
|
5325
|
+
declare function grantsClientTenant(verified: VerifiedTenant | null, tenantId: string): boolean;
|
|
5270
5326
|
/**
|
|
5271
5327
|
* Resolve the tenant a wire message is ALLOWED to act as. With a verifier, the wire `tenant` is the
|
|
5272
5328
|
* signed token: it is verified and the real tenant derived from it (`null` on reject). Without one,
|
|
@@ -6561,6 +6617,12 @@ declare class WorkflowEngine {
|
|
|
6561
6617
|
* tenant reads as null (see {@link WorkflowEngineDeps.tenancy}).
|
|
6562
6618
|
*/
|
|
6563
6619
|
getRun(runId: string): Promise<WorkflowRun | null>;
|
|
6620
|
+
/**
|
|
6621
|
+
* The runs matching `query`, narrowed to the ones the caller may see (with tenancy on, another
|
|
6622
|
+
* tenant's runs are left out, like {@link getRun}). Pair it with `workflow` / `statuses` to bound
|
|
6623
|
+
* the scan on a large store. `overlap: 'skip'` schedules use it to find their in-flight runs.
|
|
6624
|
+
*/
|
|
6625
|
+
listRuns(query: RunQuery): Promise<WorkflowRun[]>;
|
|
6564
6626
|
/** A run's full checkpoint timeline, ordered by seq (what the testing kit's `captureHistory`
|
|
6565
6627
|
* reads, next to {@link getRun}). Empty for a run the caller may not see. */
|
|
6566
6628
|
listCheckpoints(runId: string): Promise<StepCheckpoint[]>;
|
|
@@ -8951,9 +9013,11 @@ interface ScheduledWorkflow<W extends WorkflowRef = WorkflowRef> {
|
|
|
8951
9013
|
/** Temporarily stop firing this schedule (kept registered). Defaults to false. */
|
|
8952
9014
|
paused?: boolean;
|
|
8953
9015
|
/**
|
|
8954
|
-
* What to do when
|
|
8955
|
-
* `'allow'` (default) starts the new window anyway; `'skip'` skips
|
|
8956
|
-
*
|
|
9016
|
+
* What to do when an earlier window's run hasn't finished yet (interval and cron schedules alike):
|
|
9017
|
+
* `'allow'` (default) starts the new window anyway; `'skip'` skips every window while any earlier
|
|
9018
|
+
* run of this schedule is still in flight (pending, running, suspended, blocked or cancelling), so a
|
|
9019
|
+
* slow run can't pile up overlapping executions. With `backfill`, missed windows start one at a
|
|
9020
|
+
* time.
|
|
8957
9021
|
*/
|
|
8958
9022
|
overlap?: 'allow' | 'skip';
|
|
8959
9023
|
/**
|
|
@@ -9027,7 +9091,13 @@ declare function scheduleRunIdAt(s: ScheduledWorkflow, nowMs: number): string;
|
|
|
9027
9091
|
* has seen a window's run exist, later calls in that window skip it without a store read. A
|
|
9028
9092
|
* jittered window is deferred to a later call, never slept on.
|
|
9029
9093
|
*/
|
|
9030
|
-
declare function runSchedules(engine:
|
|
9094
|
+
declare function runSchedules(engine: ScheduleTickEngine, schedules: readonly ScheduledWorkflow[], nowMs: number, opts?: RunSchedulesOptions): Promise<string[]>;
|
|
9095
|
+
/**
|
|
9096
|
+
* What {@link runSchedules} needs from the engine. `listRuns` is what lets `overlap: 'skip'` find an
|
|
9097
|
+
* in-flight run this process never saw (started before a restart, or by another instance); a driver
|
|
9098
|
+
* without it only sees the runs it observed itself plus the previous window.
|
|
9099
|
+
*/
|
|
9100
|
+
type ScheduleTickEngine = Pick<WorkflowEngine, 'start' | 'getRun'> & Partial<Pick<WorkflowEngine, 'isDraining' | 'listRuns'>>;
|
|
9031
9101
|
|
|
9032
9102
|
/**
|
|
9033
9103
|
* A {@link StepLogger} that appends to `events`, stamping each line with `now()`. Shared by the
|
|
@@ -9596,4 +9666,4 @@ declare function prevRRuleFireMs(rule: ParsedRRule, atMs: number): number | null
|
|
|
9596
9666
|
*/
|
|
9597
9667
|
declare function settleResultsWithPlainCalls(store: Pick<StateStore, 'getRun' | 'getCheckpoint'> & Partial<Pick<StateStore, 'getRuns' | 'getCheckpointsForSettle' | 'getCheckpoints' | 'settleCheckpointsIfPending'>>, results: StepResultSettlement[]): Promise<(StepCheckpoint | null)[]>;
|
|
9598
9668
|
|
|
9599
|
-
export { ACCUMULATOR_SEEN_MAX, ANY_WAIT_GROUP, type AccumulatorHost, type AccumulatorStartOptions, type Admission, type AdmissionBackend, type AdmissionItem, type AllOptions, type AllSettledOptions, type AllStepsOptions, type AllStepsSettledOptions, type AnnouncedWorkflow, type AnnouncementEvidence, type AttributeFilter, type AttributeOp, type AttributePredicateOperand, type AttributeValue, type BackoffStrategy, type BlockedDispatch, type BlockedResolution, type BufferedSignalRow, CHILD_EDGE_PREFIXES, CONTROL_FLOW_SIGNAL, CORE_ORIGIN, CURRENT_PROTOCOL_VERSION, type CapabilityRequirement, type CheckpointAggregatingStore, type CheckpointNameKind, type CheckpointQuery, type CheckpointStat, type ChildCallOptions, type ChildWait, CodecStateStore, type CodecStateStoreOptions, type ConcurrencyConfig, ConcurrencyLimitError, type ConcurrencyQuota, type ConsoleCapabilities, ContinueAsNew, type ControlMessage, type ControlPlane, DEFAULT_CONCURRENCY_STATUSES, DEFAULT_PARTITION, DEFAULT_STALLED_AFTER_MS, DURABLE_OPTIONS, DURABLE_OPTIONS_CANONICAL, DURABLE_STEP_CONFIG, DURABLE_STEP_NAME, type Disagreement, type DispatchDiagnostics, type DispatchPlan, type DurableExecution, type DurableExecutionWrapper, type DurableTopology, type DurableWebhook, DurableWorkflow, type DynamicWorkflowCtx, ENGINE_MINTED_TAG_PREFIXES, ENTITY_WORKFLOW, EVENT_BUFFER_SCAN_LIMIT, EVENT_TOKEN_PREFIX, type EngineEvent, type EngineEventType, type EngineListener, type EngineTenancy, Entities, type EntityConfig, type EntityHandler, type EntityHost, type EntityWorkflowHost, EventAccumulators, type EventBatchConfig, type EventSubscription, FAN_SUMMARY_FAILURES, type FanJoin, type FanPage, type FanPageQuery, type FanSummary, type FanWait, FatalError, type FindStalledRunsOptions, GatherError, type GatherItemFailure, type GroupHealth, HANDOFF_SEQ_BASE, type Heartbeat, type HeartbeatSighting, type HeartbeatStatus, type HistoryEvent, InMemoryAdmissionBackend, InMemoryRunQueue, InMemoryStateStore, InMemoryTransport, type InferSearchAttributes, LEGACY_V1_CAPABILITIES, LEGACY_V1_PROTOCOL, LIFECYCLE_COALESCED_TAG_PREFIX, LIFECYCLE_HEAL_WINDOW_MS, LIFECYCLE_ORPHAN_MS, LIFECYCLE_OWED_TAG_PREFIX, LIFECYCLE_PENDING_TAG, LIFECYCLE_REGISTRY_HEARTBEAT_MS, LIFECYCLE_REGISTRY_STALE_MS, LIFECYCLE_REGISTRY_TAG, LIFECYCLE_REGISTRY_TTL_MS, LIFECYCLE_REGISTRY_WORKFLOW, LIFECYCLE_TRACE_TAG_PREFIX, LIFECYCLE_TRIGGERED_TAG_PREFIX, LIFECYCLE_TRIGGER_FAILED_TAG_PREFIX, type LifecycleDelivery, type LifecycleDeliveryState, type LifecycleEventOf, type LifecycleKind, type LifecycleRegistryEntry, type LifecycleSource, type LifecycleSubscriptionLink, type ListStalledRunsOptions, type MetricsCollector, type MetricsSnapshot, type NamedTransport, type NegotiateOptions, type NegotiationOutcome, type NegotiationReason, type NegotiationResult, NestedWorkflowCallError, NonDeterminismError, type OnErrorInput, type OnErrorRoute, type OnEventEntry, type OwnedLeaseReclaim, PARENT_CLOSE_TAG_PREFIX, type ParentClosePolicy, type ParsedRRule, type PartitionSighting, type PayloadCodec, type QueueConfig, QueueController, REMOTE_EVENT, RUN_HISTORY_FIXTURE_VERSION, RUN_VALUE_FACET_LIMIT, RUN_VALUE_FACET_SCAN, RUN_WAIT_TOKEN_PREFIX, type RawWorkerDescriptor, RemoteStepError, RemoteStepTimeout, type RemoteTask, RemoteWorkflowExecutor, RemoteWorkflowTimeout, type RepublishLifecycleResult, type RepublishLifecycleTarget, type RetentionPolicy, type RoutableDispatch, type RoutableResolution, type RoutingResolution, type RunAttributeRow, type RunConsumerOptions, type RunDetail, type RunDetailOptions, type RunDispatch, type RunDispatcher, type RunFacetQuery, type RunFacetRow, RunGateway, type RunListItem, type RunQuery, type RunQueueOptions, type RunReply, type RunReplyResult, type RunRequest, type RunRequestKind, type RunResult, type RunSchedulesOptions, type RunScope, type RunStatus, type RunTenant, type RunValueAxis, type RunValueFacetOptions, type RunValueFacetOrder, type RunValueFacetRow, type RunWaitLink, type RunWaiting, SINGLETON_ACTIVE_STATUSES, SINGLETON_ADMITTED_TAG, SINGLETON_LOCK_CHUNK, SINGLETON_RESERVED_TAGS, SINGLETON_TRACKED_TAG, STATE_STORE, STATE_STORE_CANONICAL, SUMMARY_CHILD_LIMIT, type ScalarAttributeFilter, ScheduleAlreadyExistsError, ScheduleClient, type ScheduleClientOptions, type ScheduleDescription, type ScheduleHost, type ScheduleListQuery, ScheduleNotFoundError, type ScheduleOptions, type ScheduleQuery, type ScheduleRecord, type ScheduledWorkflow, type SchemaIssue, type SchemaValidationCode, SchemaValidationError, type SearchAttributes, type SearchAttributesSchema, type Settled, type SignalOptions, SignalTimeoutError, type SignalWaiter, type SingletonConfig, SingletonQueueFullError, type StalePendingStep, type StalledRunInfo, StandardSchemaV1, type StartOptions, type StartRunMessage, type StateStore, type StepCheckpoint, type StepConfig, type StepDef, type StepDispatchOpts, type StepError, type StepEvent, type StepHandler, type StepInterceptor, type StepInvocation, type StepKind, type StepLogger, type StepOptions, type StepRef, type StepResult, type StepResultSettlement, type StepScope, type StepSettlement, type StepUndo, type StoreTransaction, type SubProcessHandle, TERMINAL_RUN_STATUSES, TRANSPORT, TRANSPORT_CANONICAL, type TenantEvent, type TenantFilter, type TenantRow, type TenantTokenSource, type TenantVerifier, type Transport, type UndoOf, type UpdateResult, type UpdateValidator, VERSION_UNDECLARED_TAG, type VerifiedTenant, WORKFLOW_NAME_KEY, type WaitAnyCondition, type WaitAnyOutcome, type WaitAnyResult, type WaitCondition, type WaitConditionSpec, type WaitForRunOptions, type WireDates, type WorkerAdjust, type WorkerConcurrencyStatus, type WorkerDescriptor, type WorkerHeartbeat, type WorkerLifecycle, type WorkerStatus, type WorkflowAnnouncement, WorkflowBlocked, type WorkflowClass, type WorkflowCommand, type WorkflowCtx, type WorkflowDecision, type WorkflowDirectory, WorkflowEngine, type WorkflowEngineDeps, type WorkflowExecutor, type WorkflowHandler, type WorkflowInputOf, type WorkflowLifecycleEvent, type WorkflowLifecycleLinks, WorkflowNotRegistered, type WorkflowOutputOf, type WorkflowRef, type WorkflowRegistration, type WorkflowRun, type WorkflowStartClient, type WorkflowStepEvent, WorkflowSuspended, type WorkflowTask, acceptingSubscription, accumulatorRunId, aggregateAnnouncements, aggregatesCheckpoints, announcementsOf, anyCheckpointName, applyAttributeQuery, assertConcurrency, assertRoutes, attributeColumnFor, attributeOperand, attributePredicateOperands, axisIsRunColumn, bindWorkflowClass, breakpointToken, bufferedEventReaches, buildWorkflowDirectory, canRoute, capableWorkers, carriesLifecyclePending, checkpointNameKind, checkpointStatsOf, childIdsOf, classifyWaiterToken, clearDurableExecutionWrappers, clearTerminalSingletonAdmission, coalescedSubscribersOf, codeAndDetails, codeOf, collectMetrics, concurrencyTag, controlPlaneDescriptor, countRuns, coveredTokens, createStepLogger, currentStep, currentStepScope, currentWorkflowCtx, debug, describeWorker, descriptorHash, detailsOf, error, etagMatches, eventMatchOf, eventMatches, eventNameOf, eventPrefix, eventToken, extendEtag, facetOrigin, fanPageBounds, fanPageEtag, findStalledRuns, foldedCount, getRunsByIds, handoffHandlerId, handoffName, hasDurableExecutionWrappers, heartbeatStatus, hmacTenantVerifier, indexWaitersByRun, info, inheritTenant, isAnyCheckpoint, isAnyMember, isEngineMintedTag, isEventToken, isFailedMember, isLegacyDescriptor, isLifecycleTag, isNonEmptyRunScope, isRemoteEvent, isWorkflowControlFlowSignal, legacySingletonHolders, lifecycleDeliveriesOf, lifecycleEventName, lifecycleEventOf, lifecycleKindOf, lifecycleRegistryNamespace, lifecycleRegistryRunId, lifecycleRegistrySubscriptions, lifecycleRunId, lifecycleSourceOf, lifecycleTraceparentOf, listSignalWaitersOfRuns, liveHandoff, log, markRemoteEvent, matchesAttributes, matchesTenantPredicates, mergeRunFacetRows, mergeRunValueFacetRows, missingCapabilities, negotiate, nextCronFireMs, nextRRuleFireMs, normalizeAttributeRows, normalizeDescriptor, observedAnnouncements, onErrorRunId, owedSubscribersOf, pageFan, pageFanFromStore, parentRunIdOf, parseDuration, parseLifecycleEvent, parseRRule, parseWebhookToken, partitionOfToken, planDispatch, poolNamespace, prevCronFireMs, prevRRuleFireMs, queryCheckpointsOf, readBufferedEvent, readRunsByIds, readSearchAttributes, requiredCapabilities, resolveConcurrency, resolveRouting, resolveRunWaiting, resolveTenantToken, resolveWireTenant, retentionKeeps, retiredHandoffName, routeFor, rowTenant, runCompletedEvent, runDetailEtag, runDurableExecution, runFailedEvent, runInStepLogger, runInStepScope, runInWorkflowCtx, runOutsideWorkflowCtx, runSchedules, runStepHandler, runValueFacetsFromRuns, runWaitPrefix, runWaitTargetOf, runWaitToken, sanitizeQueueToken, scheduleRunIdAt, scheduledRunId, scopeBufferedEvent, scopeTenantQuery, settleResultsWithPlainCalls, signTenantToken, singletonAdmissionDenialPatch, singletonAdmissionTags, singletonClaimantIds, sqlComparator, stepConfigOf, stepId, stepNameOf, sub, subEvent, subProcess, summarizeFan, summarizeRunFromStore, summarizeTimeline, tenantGroup, tenantIdsFor, tenantVisible, toEventSubscription, traceIdOfTraceparent, triggerFailedSubscribersOf, triggeredRunsOf, triggeredSubscribersOf, useDurableExecution, warn, withSingletonTracked, withoutSingletonMarkers, workflowName };
|
|
9669
|
+
export { ACCUMULATOR_SEEN_MAX, ANY_WAIT_GROUP, type AccumulatorHost, type AccumulatorStartOptions, type Admission, type AdmissionBackend, type AdmissionItem, type AllOptions, type AllSettledOptions, type AllStepsOptions, type AllStepsSettledOptions, type AnnouncedWorkflow, type AnnouncementEvidence, type AttributeFilter, type AttributeOp, type AttributePredicateOperand, type AttributeValue, type BackoffStrategy, type BlockedDispatch, type BlockedResolution, type BufferedSignalRow, CHILD_EDGE_PREFIXES, CONTROL_FLOW_SIGNAL, CORE_ORIGIN, CURRENT_PROTOCOL_VERSION, type CapabilityRequirement, type CheckpointAggregatingStore, type CheckpointNameKind, type CheckpointQuery, type CheckpointStat, type ChildCallOptions, type ChildWait, CodecStateStore, type CodecStateStoreOptions, type ConcurrencyConfig, ConcurrencyLimitError, type ConcurrencyQuota, type ConsoleCapabilities, ContinueAsNew, type ControlMessage, type ControlPlane, DEFAULT_CONCURRENCY_STATUSES, DEFAULT_PARTITION, DEFAULT_STALLED_AFTER_MS, DURABLE_OPTIONS, DURABLE_OPTIONS_CANONICAL, DURABLE_STEP_CONFIG, DURABLE_STEP_NAME, type Disagreement, type DispatchDiagnostics, type DispatchPlan, DuplicateDurableCopyError, type DurableCopy, type DurableExecution, type DurableExecutionWrapper, type DurableTopology, type DurableWebhook, DurableWorkflow, type DynamicWorkflowCtx, ENGINE_MINTED_TAG_PREFIXES, ENTITY_WORKFLOW, EVENT_BUFFER_SCAN_LIMIT, EVENT_TOKEN_PREFIX, type EngineEvent, type EngineEventType, type EngineListener, type EngineTenancy, Entities, type EntityConfig, type EntityHandler, type EntityHost, type EntityWorkflowHost, EventAccumulators, type EventBatchConfig, type EventSubscription, FAN_SUMMARY_FAILURES, type FanJoin, type FanPage, type FanPageQuery, type FanSummary, type FanWait, FatalError, type FindStalledRunsOptions, GatherError, type GatherItemFailure, type GroupHealth, HANDOFF_SEQ_BASE, type Heartbeat, type HeartbeatSighting, type HeartbeatStatus, type HistoryEvent, InMemoryAdmissionBackend, InMemoryRunQueue, InMemoryStateStore, InMemoryTransport, type InferSearchAttributes, LEGACY_V1_CAPABILITIES, LEGACY_V1_PROTOCOL, LIFECYCLE_COALESCED_TAG_PREFIX, LIFECYCLE_HEAL_WINDOW_MS, LIFECYCLE_ORPHAN_MS, LIFECYCLE_OWED_TAG_PREFIX, LIFECYCLE_PENDING_TAG, LIFECYCLE_REGISTRY_HEARTBEAT_MS, LIFECYCLE_REGISTRY_STALE_MS, LIFECYCLE_REGISTRY_TAG, LIFECYCLE_REGISTRY_TTL_MS, LIFECYCLE_REGISTRY_WORKFLOW, LIFECYCLE_TRACE_TAG_PREFIX, LIFECYCLE_TRIGGERED_TAG_PREFIX, LIFECYCLE_TRIGGER_FAILED_TAG_PREFIX, type LifecycleDelivery, type LifecycleDeliveryState, type LifecycleEventOf, type LifecycleKind, type LifecycleRegistryEntry, type LifecycleSource, type LifecycleSubscriptionLink, type ListStalledRunsOptions, type MetricsCollector, type MetricsSnapshot, type NamedTransport, type NegotiateOptions, type NegotiationOutcome, type NegotiationReason, type NegotiationResult, NestedWorkflowCallError, NonDeterminismError, type OnErrorInput, type OnErrorRoute, type OnEventEntry, type OwnedLeaseReclaim, PARENT_CLOSE_TAG_PREFIX, type ParentClosePolicy, type ParsedRRule, type PartitionSighting, type PayloadCodec, type QueueConfig, QueueController, REMOTE_EVENT, RUN_HISTORY_FIXTURE_VERSION, RUN_VALUE_FACET_LIMIT, RUN_VALUE_FACET_SCAN, RUN_WAIT_TOKEN_PREFIX, type RawWorkerDescriptor, RemoteStepError, RemoteStepTimeout, type RemoteTask, RemoteWorkflowExecutor, RemoteWorkflowTimeout, type RepublishLifecycleResult, type RepublishLifecycleTarget, type RetentionPolicy, type RoutableDispatch, type RoutableResolution, type RoutingResolution, type RunAttributeRow, type RunConsumerOptions, type RunDetail, type RunDetailOptions, type RunDispatch, type RunDispatcher, type RunFacetQuery, type RunFacetRow, RunGateway, type RunListItem, type RunQuery, type RunQueueOptions, type RunReply, type RunReplyResult, type RunRequest, type RunRequestKind, type RunResult, type RunSchedulesOptions, type RunScope, type RunStatus, type RunTenant, type RunValueAxis, type RunValueFacetOptions, type RunValueFacetOrder, type RunValueFacetRow, type RunWaitLink, type RunWaiting, SINGLETON_ACTIVE_STATUSES, SINGLETON_ADMITTED_TAG, SINGLETON_LOCK_CHUNK, SINGLETON_RESERVED_TAGS, SINGLETON_TRACKED_TAG, STATE_STORE, STATE_STORE_CANONICAL, SUMMARY_CHILD_LIMIT, type ScalarAttributeFilter, ScheduleAlreadyExistsError, ScheduleClient, type ScheduleClientOptions, type ScheduleDescription, type ScheduleHost, type ScheduleListQuery, ScheduleNotFoundError, type ScheduleOptions, type ScheduleQuery, type ScheduleRecord, type ScheduleTickEngine, type ScheduledWorkflow, type SchemaIssue, type SchemaValidationCode, SchemaValidationError, type SearchAttributes, type SearchAttributesSchema, type Settled, type SignalOptions, SignalTimeoutError, type SignalWaiter, type SingletonConfig, SingletonQueueFullError, type StalePendingStep, type StalledRunInfo, StandardSchemaV1, type StartOptions, type StartRunMessage, type StateStore, type StepCheckpoint, type StepConfig, type StepDef, type StepDispatchOpts, type StepError, type StepEvent, type StepHandler, type StepInterceptor, type StepInvocation, type StepKind, type StepLogger, type StepOptions, type StepRef, type StepResult, type StepResultSettlement, type StepScope, type StepSettlement, type StepUndo, type StoreTransaction, type SubProcessHandle, TERMINAL_RUN_STATUSES, TRANSPORT, TRANSPORT_CANONICAL, type TenantEvent, type TenantFilter, type TenantRow, type TenantTokenSource, type TenantVerifier, type Transport, type UndoOf, type UpdateResult, type UpdateValidator, VERSION_UNDECLARED_TAG, type VerifiedTenant, WORKFLOW_NAME_KEY, type WaitAnyCondition, type WaitAnyOutcome, type WaitAnyResult, type WaitCondition, type WaitConditionSpec, type WaitForRunOptions, type WireDates, type WorkerAdjust, type WorkerConcurrencyStatus, type WorkerDescriptor, type WorkerHeartbeat, type WorkerLifecycle, type WorkerStatus, type WorkflowAnnouncement, WorkflowBlocked, type WorkflowClass, type WorkflowCommand, type WorkflowCtx, type WorkflowDecision, type WorkflowDirectory, WorkflowEngine, type WorkflowEngineDeps, type WorkflowExecutor, type WorkflowHandler, type WorkflowInputOf, type WorkflowLifecycleEvent, type WorkflowLifecycleLinks, WorkflowNotRegistered, type WorkflowOutputOf, type WorkflowRef, type WorkflowRegistration, type WorkflowRun, type WorkflowStartClient, type WorkflowStepEvent, WorkflowSuspended, type WorkflowTask, acceptingSubscription, accumulatorRunId, aggregateAnnouncements, aggregatesCheckpoints, announcementsOf, anyCheckpointName, applyAttributeQuery, assertConcurrency, assertRoutes, assertSingleDurableCopy, attributeColumnFor, attributeOperand, attributePredicateOperands, axisIsRunColumn, bindWorkflowClass, breakpointToken, bufferedEventReaches, buildWorkflowDirectory, canRoute, capableWorkers, carriesLifecyclePending, checkpointNameKind, checkpointStatsOf, childIdsOf, classifyWaiterToken, clearDurableExecutionWrappers, clearTerminalSingletonAdmission, coalescedSubscribersOf, codeAndDetails, codeOf, collectMetrics, concurrencyTag, controlPlaneDescriptor, countRuns, coveredTokens, createStepLogger, currentStep, currentStepScope, currentWorkflowCtx, debug, describeWorker, descriptorHash, detailsOf, durableCopies, error, etagMatches, eventMatchOf, eventMatches, eventNameOf, eventPrefix, eventToken, extendEtag, facetOrigin, fanPageBounds, fanPageEtag, findStalledRuns, foldedCount, getRunsByIds, grantsClientTenant, handoffHandlerId, handoffName, hasDurableExecutionWrappers, heartbeatStatus, hmacTenantVerifier, indexWaitersByRun, info, inheritTenant, isAnyCheckpoint, isAnyMember, isEngineMintedTag, isEventToken, isFailedMember, isLegacyDescriptor, isLifecycleTag, isNonEmptyRunScope, isRemoteEvent, isWorkflowControlFlowSignal, legacySingletonHolders, lifecycleDeliveriesOf, lifecycleEventName, lifecycleEventOf, lifecycleKindOf, lifecycleRegistryNamespace, lifecycleRegistryRunId, lifecycleRegistrySubscriptions, lifecycleRunId, lifecycleSourceOf, lifecycleTraceparentOf, listSignalWaitersOfRuns, liveHandoff, log, markRemoteEvent, matchesAttributes, matchesTenantPredicates, mergeRunFacetRows, mergeRunValueFacetRows, missingCapabilities, negotiate, nextCronFireMs, nextRRuleFireMs, normalizeAttributeRows, normalizeDescriptor, observedAnnouncements, onErrorRunId, owedSubscribersOf, pageFan, pageFanFromStore, parentRunIdOf, parseDuration, parseLifecycleEvent, parseRRule, parseWebhookToken, partitionOfToken, planDispatch, poolNamespace, prevCronFireMs, prevRRuleFireMs, queryCheckpointsOf, readBufferedEvent, readRunsByIds, readSearchAttributes, requiredCapabilities, resolveConcurrency, resolveRouting, resolveRunWaiting, resolveTenantToken, resolveWireTenant, retentionKeeps, retiredHandoffName, routeFor, rowTenant, runCompletedEvent, runDetailEtag, runDurableExecution, runFailedEvent, runInStepLogger, runInStepScope, runInWorkflowCtx, runOutsideWorkflowCtx, runSchedules, runStepHandler, runValueFacetsFromRuns, runWaitPrefix, runWaitTargetOf, runWaitToken, sanitizeQueueToken, scheduleRunIdAt, scheduledRunId, scopeBufferedEvent, scopeTenantQuery, sealDurableCopies, settleResultsWithPlainCalls, signTenantToken, singletonAdmissionDenialPatch, singletonAdmissionTags, singletonClaimantIds, sqlComparator, stepConfigOf, stepId, stepNameOf, sub, subEvent, subProcess, summarizeFan, summarizeRunFromStore, summarizeTimeline, tenantGroup, tenantIdsFor, tenantVisible, toEventSubscription, traceIdOfTraceparent, triggerFailedSubscribersOf, triggeredRunsOf, triggeredSubscribersOf, useDurableExecution, verifyWireTenant, warn, withSingletonTracked, withoutSingletonMarkers, workflowName };
|
package/dist/index.d.ts
CHANGED
|
@@ -2671,6 +2671,14 @@ interface StartRunMessage {
|
|
|
2671
2671
|
tags?: string[] | undefined;
|
|
2672
2672
|
/** Typed, queryable run data to stamp on the run (same as {@link StartOptions.searchAttributes}). */
|
|
2673
2673
|
searchAttributes?: SearchAttributes | undefined;
|
|
2674
|
+
/**
|
|
2675
|
+
* The customer (data tenant) the run belongs to, as the tenant process sees it. Only a claim: the
|
|
2676
|
+
* control plane keeps it when the process's verified token grants `tenancy:*` or
|
|
2677
|
+
* `tenancy:<tenantId>` in its `capabilities`, else the run gets no customer tenant.
|
|
2678
|
+
*/
|
|
2679
|
+
tenantId?: string | undefined;
|
|
2680
|
+
/** The kind of {@link tenantId} (`organization`, `clinic`, …). */
|
|
2681
|
+
tenantKind?: string | undefined;
|
|
2674
2682
|
}
|
|
2675
2683
|
/**
|
|
2676
2684
|
* A tenant worker → control plane read/control request over the shared transport. Enqueued on
|
|
@@ -4083,6 +4091,36 @@ declare const CONTROL_FLOW_SIGNAL: unique symbol;
|
|
|
4083
4091
|
*/
|
|
4084
4092
|
declare function isWorkflowControlFlowSignal(error: unknown): boolean;
|
|
4085
4093
|
|
|
4094
|
+
/**
|
|
4095
|
+
* One loaded copy of this package: its version and the real path of its package root. Two copies are
|
|
4096
|
+
* the same when their roots are, so the `src` and `dist` builds of one checkout, the ESM and CJS
|
|
4097
|
+
* builds of one install, or one module evaluated twice (test runners reload modules) count once.
|
|
4098
|
+
*/
|
|
4099
|
+
interface DurableCopy {
|
|
4100
|
+
version: string;
|
|
4101
|
+
root: string;
|
|
4102
|
+
}
|
|
4103
|
+
/** What every loaded copy writes to, shared through `globalThis` so copies can see each other. */
|
|
4104
|
+
interface DurableCopyRegistry {
|
|
4105
|
+
copies: Map<string, DurableCopy>;
|
|
4106
|
+
/** Set once a module booted: a copy that loads after that cannot be caught at boot any more. */
|
|
4107
|
+
booted: boolean;
|
|
4108
|
+
}
|
|
4109
|
+
/** Thrown at boot when two different installs of `@dudousxd/nestjs-durable-core` are loaded in one process. */
|
|
4110
|
+
declare class DuplicateDurableCopyError extends Error {
|
|
4111
|
+
readonly copies: DurableCopy[];
|
|
4112
|
+
constructor(copies: DurableCopy[]);
|
|
4113
|
+
}
|
|
4114
|
+
/** Every distinct copy registered so far. */
|
|
4115
|
+
declare function durableCopies(registry?: DurableCopyRegistry): DurableCopy[];
|
|
4116
|
+
/** Throws {@link DuplicateDurableCopyError} when more than one distinct copy is registered. */
|
|
4117
|
+
declare function assertSingleDurableCopy(registry?: DurableCopyRegistry): void;
|
|
4118
|
+
/**
|
|
4119
|
+
* Called on the boot path (`DurableModule.forRoot` / `forRootAsync`): check now, and make any
|
|
4120
|
+
* distinct copy that loads later fail on load. Safe to call any number of times.
|
|
4121
|
+
*/
|
|
4122
|
+
declare function sealDurableCopies(registry?: DurableCopyRegistry): void;
|
|
4123
|
+
|
|
4086
4124
|
/**
|
|
4087
4125
|
* A start-time concurrency quota for ONE start: at most `limit` runs sharing `key` may be in flight
|
|
4088
4126
|
* (in `countStatuses`) at once; a start that would exceed it is rejected with
|
|
@@ -4262,6 +4300,12 @@ interface EngineTenancy {
|
|
|
4262
4300
|
filter(): TenantFilter;
|
|
4263
4301
|
/** Run `fn` with `tenant` restored as the ambient context tenant. */
|
|
4264
4302
|
run<T>(tenant: RunTenant, fn: () => T): T;
|
|
4303
|
+
/**
|
|
4304
|
+
* Run `fn` as durable's own work (a workflow turn, a recovery, a worker's step), where no request
|
|
4305
|
+
* asks for a tenant: a host whose tenancy requires one (`required: true`) must not reject a
|
|
4306
|
+
* missing tenant inside it. Optional: without it, `fn` runs as is.
|
|
4307
|
+
*/
|
|
4308
|
+
system?<T>(fn: () => T): T;
|
|
4265
4309
|
}
|
|
4266
4310
|
/** A row that may carry a tenant (a run, a schedule). */
|
|
4267
4311
|
interface TenantRow {
|
|
@@ -5215,9 +5259,10 @@ interface VerifiedTenant {
|
|
|
5215
5259
|
/** The tenant the token authenticates as. The responder trusts THIS, never the request body. */
|
|
5216
5260
|
tenant: string;
|
|
5217
5261
|
/**
|
|
5218
|
-
* Capabilities the token grants, if the issuer scopes them.
|
|
5219
|
-
*
|
|
5220
|
-
* call every verb, scoped to
|
|
5262
|
+
* Capabilities the token grants, if the issuer scopes them. `tenancy:*` or `tenancy:<id>` lets the
|
|
5263
|
+
* process claim that customer tenant for the runs it starts (see `StartRunMessage.tenantId`). The
|
|
5264
|
+
* run-request responder does not enforce them: a verified tenant can call every verb, scoped to
|
|
5265
|
+
* its own namespace.
|
|
5221
5266
|
*/
|
|
5222
5267
|
capabilities?: string[] | undefined;
|
|
5223
5268
|
}
|
|
@@ -5267,6 +5312,17 @@ declare function signTenantToken(tenant: string, secret: string, opts?: {
|
|
|
5267
5312
|
* responder does not enforce it yet, see {@link VerifiedTenant.capabilities}).
|
|
5268
5313
|
*/
|
|
5269
5314
|
declare function hmacTenantVerifier(secret: string | string[], capabilities?: string[]): TenantVerifier;
|
|
5315
|
+
/**
|
|
5316
|
+
* Verify a wire message's `tenant`: with a verifier, the {@link VerifiedTenant} it derives (`null` on
|
|
5317
|
+
* reject); without one, the wire value trusted verbatim, with no capabilities.
|
|
5318
|
+
*/
|
|
5319
|
+
declare function verifyWireTenant(wireTenant: string, verifyTenant: TenantVerifier | undefined): Promise<VerifiedTenant | null>;
|
|
5320
|
+
/**
|
|
5321
|
+
* Whether a verified tenant process may claim the customer `tenantId` for a run it starts: its
|
|
5322
|
+
* `capabilities` hold `tenancy:*` (any customer) or `tenancy:<tenantId>`. An unverified process (no
|
|
5323
|
+
* verifier) holds none, so it never may.
|
|
5324
|
+
*/
|
|
5325
|
+
declare function grantsClientTenant(verified: VerifiedTenant | null, tenantId: string): boolean;
|
|
5270
5326
|
/**
|
|
5271
5327
|
* Resolve the tenant a wire message is ALLOWED to act as. With a verifier, the wire `tenant` is the
|
|
5272
5328
|
* signed token: it is verified and the real tenant derived from it (`null` on reject). Without one,
|
|
@@ -6561,6 +6617,12 @@ declare class WorkflowEngine {
|
|
|
6561
6617
|
* tenant reads as null (see {@link WorkflowEngineDeps.tenancy}).
|
|
6562
6618
|
*/
|
|
6563
6619
|
getRun(runId: string): Promise<WorkflowRun | null>;
|
|
6620
|
+
/**
|
|
6621
|
+
* The runs matching `query`, narrowed to the ones the caller may see (with tenancy on, another
|
|
6622
|
+
* tenant's runs are left out, like {@link getRun}). Pair it with `workflow` / `statuses` to bound
|
|
6623
|
+
* the scan on a large store. `overlap: 'skip'` schedules use it to find their in-flight runs.
|
|
6624
|
+
*/
|
|
6625
|
+
listRuns(query: RunQuery): Promise<WorkflowRun[]>;
|
|
6564
6626
|
/** A run's full checkpoint timeline, ordered by seq (what the testing kit's `captureHistory`
|
|
6565
6627
|
* reads, next to {@link getRun}). Empty for a run the caller may not see. */
|
|
6566
6628
|
listCheckpoints(runId: string): Promise<StepCheckpoint[]>;
|
|
@@ -8951,9 +9013,11 @@ interface ScheduledWorkflow<W extends WorkflowRef = WorkflowRef> {
|
|
|
8951
9013
|
/** Temporarily stop firing this schedule (kept registered). Defaults to false. */
|
|
8952
9014
|
paused?: boolean;
|
|
8953
9015
|
/**
|
|
8954
|
-
* What to do when
|
|
8955
|
-
* `'allow'` (default) starts the new window anyway; `'skip'` skips
|
|
8956
|
-
*
|
|
9016
|
+
* What to do when an earlier window's run hasn't finished yet (interval and cron schedules alike):
|
|
9017
|
+
* `'allow'` (default) starts the new window anyway; `'skip'` skips every window while any earlier
|
|
9018
|
+
* run of this schedule is still in flight (pending, running, suspended, blocked or cancelling), so a
|
|
9019
|
+
* slow run can't pile up overlapping executions. With `backfill`, missed windows start one at a
|
|
9020
|
+
* time.
|
|
8957
9021
|
*/
|
|
8958
9022
|
overlap?: 'allow' | 'skip';
|
|
8959
9023
|
/**
|
|
@@ -9027,7 +9091,13 @@ declare function scheduleRunIdAt(s: ScheduledWorkflow, nowMs: number): string;
|
|
|
9027
9091
|
* has seen a window's run exist, later calls in that window skip it without a store read. A
|
|
9028
9092
|
* jittered window is deferred to a later call, never slept on.
|
|
9029
9093
|
*/
|
|
9030
|
-
declare function runSchedules(engine:
|
|
9094
|
+
declare function runSchedules(engine: ScheduleTickEngine, schedules: readonly ScheduledWorkflow[], nowMs: number, opts?: RunSchedulesOptions): Promise<string[]>;
|
|
9095
|
+
/**
|
|
9096
|
+
* What {@link runSchedules} needs from the engine. `listRuns` is what lets `overlap: 'skip'` find an
|
|
9097
|
+
* in-flight run this process never saw (started before a restart, or by another instance); a driver
|
|
9098
|
+
* without it only sees the runs it observed itself plus the previous window.
|
|
9099
|
+
*/
|
|
9100
|
+
type ScheduleTickEngine = Pick<WorkflowEngine, 'start' | 'getRun'> & Partial<Pick<WorkflowEngine, 'isDraining' | 'listRuns'>>;
|
|
9031
9101
|
|
|
9032
9102
|
/**
|
|
9033
9103
|
* A {@link StepLogger} that appends to `events`, stamping each line with `now()`. Shared by the
|
|
@@ -9596,4 +9666,4 @@ declare function prevRRuleFireMs(rule: ParsedRRule, atMs: number): number | null
|
|
|
9596
9666
|
*/
|
|
9597
9667
|
declare function settleResultsWithPlainCalls(store: Pick<StateStore, 'getRun' | 'getCheckpoint'> & Partial<Pick<StateStore, 'getRuns' | 'getCheckpointsForSettle' | 'getCheckpoints' | 'settleCheckpointsIfPending'>>, results: StepResultSettlement[]): Promise<(StepCheckpoint | null)[]>;
|
|
9598
9668
|
|
|
9599
|
-
export { ACCUMULATOR_SEEN_MAX, ANY_WAIT_GROUP, type AccumulatorHost, type AccumulatorStartOptions, type Admission, type AdmissionBackend, type AdmissionItem, type AllOptions, type AllSettledOptions, type AllStepsOptions, type AllStepsSettledOptions, type AnnouncedWorkflow, type AnnouncementEvidence, type AttributeFilter, type AttributeOp, type AttributePredicateOperand, type AttributeValue, type BackoffStrategy, type BlockedDispatch, type BlockedResolution, type BufferedSignalRow, CHILD_EDGE_PREFIXES, CONTROL_FLOW_SIGNAL, CORE_ORIGIN, CURRENT_PROTOCOL_VERSION, type CapabilityRequirement, type CheckpointAggregatingStore, type CheckpointNameKind, type CheckpointQuery, type CheckpointStat, type ChildCallOptions, type ChildWait, CodecStateStore, type CodecStateStoreOptions, type ConcurrencyConfig, ConcurrencyLimitError, type ConcurrencyQuota, type ConsoleCapabilities, ContinueAsNew, type ControlMessage, type ControlPlane, DEFAULT_CONCURRENCY_STATUSES, DEFAULT_PARTITION, DEFAULT_STALLED_AFTER_MS, DURABLE_OPTIONS, DURABLE_OPTIONS_CANONICAL, DURABLE_STEP_CONFIG, DURABLE_STEP_NAME, type Disagreement, type DispatchDiagnostics, type DispatchPlan, type DurableExecution, type DurableExecutionWrapper, type DurableTopology, type DurableWebhook, DurableWorkflow, type DynamicWorkflowCtx, ENGINE_MINTED_TAG_PREFIXES, ENTITY_WORKFLOW, EVENT_BUFFER_SCAN_LIMIT, EVENT_TOKEN_PREFIX, type EngineEvent, type EngineEventType, type EngineListener, type EngineTenancy, Entities, type EntityConfig, type EntityHandler, type EntityHost, type EntityWorkflowHost, EventAccumulators, type EventBatchConfig, type EventSubscription, FAN_SUMMARY_FAILURES, type FanJoin, type FanPage, type FanPageQuery, type FanSummary, type FanWait, FatalError, type FindStalledRunsOptions, GatherError, type GatherItemFailure, type GroupHealth, HANDOFF_SEQ_BASE, type Heartbeat, type HeartbeatSighting, type HeartbeatStatus, type HistoryEvent, InMemoryAdmissionBackend, InMemoryRunQueue, InMemoryStateStore, InMemoryTransport, type InferSearchAttributes, LEGACY_V1_CAPABILITIES, LEGACY_V1_PROTOCOL, LIFECYCLE_COALESCED_TAG_PREFIX, LIFECYCLE_HEAL_WINDOW_MS, LIFECYCLE_ORPHAN_MS, LIFECYCLE_OWED_TAG_PREFIX, LIFECYCLE_PENDING_TAG, LIFECYCLE_REGISTRY_HEARTBEAT_MS, LIFECYCLE_REGISTRY_STALE_MS, LIFECYCLE_REGISTRY_TAG, LIFECYCLE_REGISTRY_TTL_MS, LIFECYCLE_REGISTRY_WORKFLOW, LIFECYCLE_TRACE_TAG_PREFIX, LIFECYCLE_TRIGGERED_TAG_PREFIX, LIFECYCLE_TRIGGER_FAILED_TAG_PREFIX, type LifecycleDelivery, type LifecycleDeliveryState, type LifecycleEventOf, type LifecycleKind, type LifecycleRegistryEntry, type LifecycleSource, type LifecycleSubscriptionLink, type ListStalledRunsOptions, type MetricsCollector, type MetricsSnapshot, type NamedTransport, type NegotiateOptions, type NegotiationOutcome, type NegotiationReason, type NegotiationResult, NestedWorkflowCallError, NonDeterminismError, type OnErrorInput, type OnErrorRoute, type OnEventEntry, type OwnedLeaseReclaim, PARENT_CLOSE_TAG_PREFIX, type ParentClosePolicy, type ParsedRRule, type PartitionSighting, type PayloadCodec, type QueueConfig, QueueController, REMOTE_EVENT, RUN_HISTORY_FIXTURE_VERSION, RUN_VALUE_FACET_LIMIT, RUN_VALUE_FACET_SCAN, RUN_WAIT_TOKEN_PREFIX, type RawWorkerDescriptor, RemoteStepError, RemoteStepTimeout, type RemoteTask, RemoteWorkflowExecutor, RemoteWorkflowTimeout, type RepublishLifecycleResult, type RepublishLifecycleTarget, type RetentionPolicy, type RoutableDispatch, type RoutableResolution, type RoutingResolution, type RunAttributeRow, type RunConsumerOptions, type RunDetail, type RunDetailOptions, type RunDispatch, type RunDispatcher, type RunFacetQuery, type RunFacetRow, RunGateway, type RunListItem, type RunQuery, type RunQueueOptions, type RunReply, type RunReplyResult, type RunRequest, type RunRequestKind, type RunResult, type RunSchedulesOptions, type RunScope, type RunStatus, type RunTenant, type RunValueAxis, type RunValueFacetOptions, type RunValueFacetOrder, type RunValueFacetRow, type RunWaitLink, type RunWaiting, SINGLETON_ACTIVE_STATUSES, SINGLETON_ADMITTED_TAG, SINGLETON_LOCK_CHUNK, SINGLETON_RESERVED_TAGS, SINGLETON_TRACKED_TAG, STATE_STORE, STATE_STORE_CANONICAL, SUMMARY_CHILD_LIMIT, type ScalarAttributeFilter, ScheduleAlreadyExistsError, ScheduleClient, type ScheduleClientOptions, type ScheduleDescription, type ScheduleHost, type ScheduleListQuery, ScheduleNotFoundError, type ScheduleOptions, type ScheduleQuery, type ScheduleRecord, type ScheduledWorkflow, type SchemaIssue, type SchemaValidationCode, SchemaValidationError, type SearchAttributes, type SearchAttributesSchema, type Settled, type SignalOptions, SignalTimeoutError, type SignalWaiter, type SingletonConfig, SingletonQueueFullError, type StalePendingStep, type StalledRunInfo, StandardSchemaV1, type StartOptions, type StartRunMessage, type StateStore, type StepCheckpoint, type StepConfig, type StepDef, type StepDispatchOpts, type StepError, type StepEvent, type StepHandler, type StepInterceptor, type StepInvocation, type StepKind, type StepLogger, type StepOptions, type StepRef, type StepResult, type StepResultSettlement, type StepScope, type StepSettlement, type StepUndo, type StoreTransaction, type SubProcessHandle, TERMINAL_RUN_STATUSES, TRANSPORT, TRANSPORT_CANONICAL, type TenantEvent, type TenantFilter, type TenantRow, type TenantTokenSource, type TenantVerifier, type Transport, type UndoOf, type UpdateResult, type UpdateValidator, VERSION_UNDECLARED_TAG, type VerifiedTenant, WORKFLOW_NAME_KEY, type WaitAnyCondition, type WaitAnyOutcome, type WaitAnyResult, type WaitCondition, type WaitConditionSpec, type WaitForRunOptions, type WireDates, type WorkerAdjust, type WorkerConcurrencyStatus, type WorkerDescriptor, type WorkerHeartbeat, type WorkerLifecycle, type WorkerStatus, type WorkflowAnnouncement, WorkflowBlocked, type WorkflowClass, type WorkflowCommand, type WorkflowCtx, type WorkflowDecision, type WorkflowDirectory, WorkflowEngine, type WorkflowEngineDeps, type WorkflowExecutor, type WorkflowHandler, type WorkflowInputOf, type WorkflowLifecycleEvent, type WorkflowLifecycleLinks, WorkflowNotRegistered, type WorkflowOutputOf, type WorkflowRef, type WorkflowRegistration, type WorkflowRun, type WorkflowStartClient, type WorkflowStepEvent, WorkflowSuspended, type WorkflowTask, acceptingSubscription, accumulatorRunId, aggregateAnnouncements, aggregatesCheckpoints, announcementsOf, anyCheckpointName, applyAttributeQuery, assertConcurrency, assertRoutes, attributeColumnFor, attributeOperand, attributePredicateOperands, axisIsRunColumn, bindWorkflowClass, breakpointToken, bufferedEventReaches, buildWorkflowDirectory, canRoute, capableWorkers, carriesLifecyclePending, checkpointNameKind, checkpointStatsOf, childIdsOf, classifyWaiterToken, clearDurableExecutionWrappers, clearTerminalSingletonAdmission, coalescedSubscribersOf, codeAndDetails, codeOf, collectMetrics, concurrencyTag, controlPlaneDescriptor, countRuns, coveredTokens, createStepLogger, currentStep, currentStepScope, currentWorkflowCtx, debug, describeWorker, descriptorHash, detailsOf, error, etagMatches, eventMatchOf, eventMatches, eventNameOf, eventPrefix, eventToken, extendEtag, facetOrigin, fanPageBounds, fanPageEtag, findStalledRuns, foldedCount, getRunsByIds, handoffHandlerId, handoffName, hasDurableExecutionWrappers, heartbeatStatus, hmacTenantVerifier, indexWaitersByRun, info, inheritTenant, isAnyCheckpoint, isAnyMember, isEngineMintedTag, isEventToken, isFailedMember, isLegacyDescriptor, isLifecycleTag, isNonEmptyRunScope, isRemoteEvent, isWorkflowControlFlowSignal, legacySingletonHolders, lifecycleDeliveriesOf, lifecycleEventName, lifecycleEventOf, lifecycleKindOf, lifecycleRegistryNamespace, lifecycleRegistryRunId, lifecycleRegistrySubscriptions, lifecycleRunId, lifecycleSourceOf, lifecycleTraceparentOf, listSignalWaitersOfRuns, liveHandoff, log, markRemoteEvent, matchesAttributes, matchesTenantPredicates, mergeRunFacetRows, mergeRunValueFacetRows, missingCapabilities, negotiate, nextCronFireMs, nextRRuleFireMs, normalizeAttributeRows, normalizeDescriptor, observedAnnouncements, onErrorRunId, owedSubscribersOf, pageFan, pageFanFromStore, parentRunIdOf, parseDuration, parseLifecycleEvent, parseRRule, parseWebhookToken, partitionOfToken, planDispatch, poolNamespace, prevCronFireMs, prevRRuleFireMs, queryCheckpointsOf, readBufferedEvent, readRunsByIds, readSearchAttributes, requiredCapabilities, resolveConcurrency, resolveRouting, resolveRunWaiting, resolveTenantToken, resolveWireTenant, retentionKeeps, retiredHandoffName, routeFor, rowTenant, runCompletedEvent, runDetailEtag, runDurableExecution, runFailedEvent, runInStepLogger, runInStepScope, runInWorkflowCtx, runOutsideWorkflowCtx, runSchedules, runStepHandler, runValueFacetsFromRuns, runWaitPrefix, runWaitTargetOf, runWaitToken, sanitizeQueueToken, scheduleRunIdAt, scheduledRunId, scopeBufferedEvent, scopeTenantQuery, settleResultsWithPlainCalls, signTenantToken, singletonAdmissionDenialPatch, singletonAdmissionTags, singletonClaimantIds, sqlComparator, stepConfigOf, stepId, stepNameOf, sub, subEvent, subProcess, summarizeFan, summarizeRunFromStore, summarizeTimeline, tenantGroup, tenantIdsFor, tenantVisible, toEventSubscription, traceIdOfTraceparent, triggerFailedSubscribersOf, triggeredRunsOf, triggeredSubscribersOf, useDurableExecution, warn, withSingletonTracked, withoutSingletonMarkers, workflowName };
|
|
9669
|
+
export { ACCUMULATOR_SEEN_MAX, ANY_WAIT_GROUP, type AccumulatorHost, type AccumulatorStartOptions, type Admission, type AdmissionBackend, type AdmissionItem, type AllOptions, type AllSettledOptions, type AllStepsOptions, type AllStepsSettledOptions, type AnnouncedWorkflow, type AnnouncementEvidence, type AttributeFilter, type AttributeOp, type AttributePredicateOperand, type AttributeValue, type BackoffStrategy, type BlockedDispatch, type BlockedResolution, type BufferedSignalRow, CHILD_EDGE_PREFIXES, CONTROL_FLOW_SIGNAL, CORE_ORIGIN, CURRENT_PROTOCOL_VERSION, type CapabilityRequirement, type CheckpointAggregatingStore, type CheckpointNameKind, type CheckpointQuery, type CheckpointStat, type ChildCallOptions, type ChildWait, CodecStateStore, type CodecStateStoreOptions, type ConcurrencyConfig, ConcurrencyLimitError, type ConcurrencyQuota, type ConsoleCapabilities, ContinueAsNew, type ControlMessage, type ControlPlane, DEFAULT_CONCURRENCY_STATUSES, DEFAULT_PARTITION, DEFAULT_STALLED_AFTER_MS, DURABLE_OPTIONS, DURABLE_OPTIONS_CANONICAL, DURABLE_STEP_CONFIG, DURABLE_STEP_NAME, type Disagreement, type DispatchDiagnostics, type DispatchPlan, DuplicateDurableCopyError, type DurableCopy, type DurableExecution, type DurableExecutionWrapper, type DurableTopology, type DurableWebhook, DurableWorkflow, type DynamicWorkflowCtx, ENGINE_MINTED_TAG_PREFIXES, ENTITY_WORKFLOW, EVENT_BUFFER_SCAN_LIMIT, EVENT_TOKEN_PREFIX, type EngineEvent, type EngineEventType, type EngineListener, type EngineTenancy, Entities, type EntityConfig, type EntityHandler, type EntityHost, type EntityWorkflowHost, EventAccumulators, type EventBatchConfig, type EventSubscription, FAN_SUMMARY_FAILURES, type FanJoin, type FanPage, type FanPageQuery, type FanSummary, type FanWait, FatalError, type FindStalledRunsOptions, GatherError, type GatherItemFailure, type GroupHealth, HANDOFF_SEQ_BASE, type Heartbeat, type HeartbeatSighting, type HeartbeatStatus, type HistoryEvent, InMemoryAdmissionBackend, InMemoryRunQueue, InMemoryStateStore, InMemoryTransport, type InferSearchAttributes, LEGACY_V1_CAPABILITIES, LEGACY_V1_PROTOCOL, LIFECYCLE_COALESCED_TAG_PREFIX, LIFECYCLE_HEAL_WINDOW_MS, LIFECYCLE_ORPHAN_MS, LIFECYCLE_OWED_TAG_PREFIX, LIFECYCLE_PENDING_TAG, LIFECYCLE_REGISTRY_HEARTBEAT_MS, LIFECYCLE_REGISTRY_STALE_MS, LIFECYCLE_REGISTRY_TAG, LIFECYCLE_REGISTRY_TTL_MS, LIFECYCLE_REGISTRY_WORKFLOW, LIFECYCLE_TRACE_TAG_PREFIX, LIFECYCLE_TRIGGERED_TAG_PREFIX, LIFECYCLE_TRIGGER_FAILED_TAG_PREFIX, type LifecycleDelivery, type LifecycleDeliveryState, type LifecycleEventOf, type LifecycleKind, type LifecycleRegistryEntry, type LifecycleSource, type LifecycleSubscriptionLink, type ListStalledRunsOptions, type MetricsCollector, type MetricsSnapshot, type NamedTransport, type NegotiateOptions, type NegotiationOutcome, type NegotiationReason, type NegotiationResult, NestedWorkflowCallError, NonDeterminismError, type OnErrorInput, type OnErrorRoute, type OnEventEntry, type OwnedLeaseReclaim, PARENT_CLOSE_TAG_PREFIX, type ParentClosePolicy, type ParsedRRule, type PartitionSighting, type PayloadCodec, type QueueConfig, QueueController, REMOTE_EVENT, RUN_HISTORY_FIXTURE_VERSION, RUN_VALUE_FACET_LIMIT, RUN_VALUE_FACET_SCAN, RUN_WAIT_TOKEN_PREFIX, type RawWorkerDescriptor, RemoteStepError, RemoteStepTimeout, type RemoteTask, RemoteWorkflowExecutor, RemoteWorkflowTimeout, type RepublishLifecycleResult, type RepublishLifecycleTarget, type RetentionPolicy, type RoutableDispatch, type RoutableResolution, type RoutingResolution, type RunAttributeRow, type RunConsumerOptions, type RunDetail, type RunDetailOptions, type RunDispatch, type RunDispatcher, type RunFacetQuery, type RunFacetRow, RunGateway, type RunListItem, type RunQuery, type RunQueueOptions, type RunReply, type RunReplyResult, type RunRequest, type RunRequestKind, type RunResult, type RunSchedulesOptions, type RunScope, type RunStatus, type RunTenant, type RunValueAxis, type RunValueFacetOptions, type RunValueFacetOrder, type RunValueFacetRow, type RunWaitLink, type RunWaiting, SINGLETON_ACTIVE_STATUSES, SINGLETON_ADMITTED_TAG, SINGLETON_LOCK_CHUNK, SINGLETON_RESERVED_TAGS, SINGLETON_TRACKED_TAG, STATE_STORE, STATE_STORE_CANONICAL, SUMMARY_CHILD_LIMIT, type ScalarAttributeFilter, ScheduleAlreadyExistsError, ScheduleClient, type ScheduleClientOptions, type ScheduleDescription, type ScheduleHost, type ScheduleListQuery, ScheduleNotFoundError, type ScheduleOptions, type ScheduleQuery, type ScheduleRecord, type ScheduleTickEngine, type ScheduledWorkflow, type SchemaIssue, type SchemaValidationCode, SchemaValidationError, type SearchAttributes, type SearchAttributesSchema, type Settled, type SignalOptions, SignalTimeoutError, type SignalWaiter, type SingletonConfig, SingletonQueueFullError, type StalePendingStep, type StalledRunInfo, StandardSchemaV1, type StartOptions, type StartRunMessage, type StateStore, type StepCheckpoint, type StepConfig, type StepDef, type StepDispatchOpts, type StepError, type StepEvent, type StepHandler, type StepInterceptor, type StepInvocation, type StepKind, type StepLogger, type StepOptions, type StepRef, type StepResult, type StepResultSettlement, type StepScope, type StepSettlement, type StepUndo, type StoreTransaction, type SubProcessHandle, TERMINAL_RUN_STATUSES, TRANSPORT, TRANSPORT_CANONICAL, type TenantEvent, type TenantFilter, type TenantRow, type TenantTokenSource, type TenantVerifier, type Transport, type UndoOf, type UpdateResult, type UpdateValidator, VERSION_UNDECLARED_TAG, type VerifiedTenant, WORKFLOW_NAME_KEY, type WaitAnyCondition, type WaitAnyOutcome, type WaitAnyResult, type WaitCondition, type WaitConditionSpec, type WaitForRunOptions, type WireDates, type WorkerAdjust, type WorkerConcurrencyStatus, type WorkerDescriptor, type WorkerHeartbeat, type WorkerLifecycle, type WorkerStatus, type WorkflowAnnouncement, WorkflowBlocked, type WorkflowClass, type WorkflowCommand, type WorkflowCtx, type WorkflowDecision, type WorkflowDirectory, WorkflowEngine, type WorkflowEngineDeps, type WorkflowExecutor, type WorkflowHandler, type WorkflowInputOf, type WorkflowLifecycleEvent, type WorkflowLifecycleLinks, WorkflowNotRegistered, type WorkflowOutputOf, type WorkflowRef, type WorkflowRegistration, type WorkflowRun, type WorkflowStartClient, type WorkflowStepEvent, WorkflowSuspended, type WorkflowTask, acceptingSubscription, accumulatorRunId, aggregateAnnouncements, aggregatesCheckpoints, announcementsOf, anyCheckpointName, applyAttributeQuery, assertConcurrency, assertRoutes, assertSingleDurableCopy, attributeColumnFor, attributeOperand, attributePredicateOperands, axisIsRunColumn, bindWorkflowClass, breakpointToken, bufferedEventReaches, buildWorkflowDirectory, canRoute, capableWorkers, carriesLifecyclePending, checkpointNameKind, checkpointStatsOf, childIdsOf, classifyWaiterToken, clearDurableExecutionWrappers, clearTerminalSingletonAdmission, coalescedSubscribersOf, codeAndDetails, codeOf, collectMetrics, concurrencyTag, controlPlaneDescriptor, countRuns, coveredTokens, createStepLogger, currentStep, currentStepScope, currentWorkflowCtx, debug, describeWorker, descriptorHash, detailsOf, durableCopies, error, etagMatches, eventMatchOf, eventMatches, eventNameOf, eventPrefix, eventToken, extendEtag, facetOrigin, fanPageBounds, fanPageEtag, findStalledRuns, foldedCount, getRunsByIds, grantsClientTenant, handoffHandlerId, handoffName, hasDurableExecutionWrappers, heartbeatStatus, hmacTenantVerifier, indexWaitersByRun, info, inheritTenant, isAnyCheckpoint, isAnyMember, isEngineMintedTag, isEventToken, isFailedMember, isLegacyDescriptor, isLifecycleTag, isNonEmptyRunScope, isRemoteEvent, isWorkflowControlFlowSignal, legacySingletonHolders, lifecycleDeliveriesOf, lifecycleEventName, lifecycleEventOf, lifecycleKindOf, lifecycleRegistryNamespace, lifecycleRegistryRunId, lifecycleRegistrySubscriptions, lifecycleRunId, lifecycleSourceOf, lifecycleTraceparentOf, listSignalWaitersOfRuns, liveHandoff, log, markRemoteEvent, matchesAttributes, matchesTenantPredicates, mergeRunFacetRows, mergeRunValueFacetRows, missingCapabilities, negotiate, nextCronFireMs, nextRRuleFireMs, normalizeAttributeRows, normalizeDescriptor, observedAnnouncements, onErrorRunId, owedSubscribersOf, pageFan, pageFanFromStore, parentRunIdOf, parseDuration, parseLifecycleEvent, parseRRule, parseWebhookToken, partitionOfToken, planDispatch, poolNamespace, prevCronFireMs, prevRRuleFireMs, queryCheckpointsOf, readBufferedEvent, readRunsByIds, readSearchAttributes, requiredCapabilities, resolveConcurrency, resolveRouting, resolveRunWaiting, resolveTenantToken, resolveWireTenant, retentionKeeps, retiredHandoffName, routeFor, rowTenant, runCompletedEvent, runDetailEtag, runDurableExecution, runFailedEvent, runInStepLogger, runInStepScope, runInWorkflowCtx, runOutsideWorkflowCtx, runSchedules, runStepHandler, runValueFacetsFromRuns, runWaitPrefix, runWaitTargetOf, runWaitToken, sanitizeQueueToken, scheduleRunIdAt, scheduledRunId, scopeBufferedEvent, scopeTenantQuery, sealDurableCopies, settleResultsWithPlainCalls, signTenantToken, singletonAdmissionDenialPatch, singletonAdmissionTags, singletonClaimantIds, sqlComparator, stepConfigOf, stepId, stepNameOf, sub, subEvent, subProcess, summarizeFan, summarizeRunFromStore, summarizeTimeline, tenantGroup, tenantIdsFor, tenantVisible, toEventSubscription, traceIdOfTraceparent, triggerFailedSubscribersOf, triggeredRunsOf, triggeredSubscribersOf, useDurableExecution, verifyWireTenant, warn, withSingletonTracked, withoutSingletonMarkers, workflowName };
|