Versions in this module Expand all Collapse all v0 v0.2.0 Aug 10, 2026 Changes in this version + const DefaultCatchUpLimit + const DefaultCompactionThreshold + const DefaultGCOffset + const DefaultMaxCompactedEvents + const DefaultMaxVersionAge + const DefaultMaxWasmStringLen + const DefaultMemoryLimitPages + const DefaultMinVersionsToKeep + const DefaultOutBufSize + const DefaultScheduleTimezone + const DefaultTenantUUID + const DefaultWasmtimeExecutionTimeout + const DefaultWasmtimeInstancesLimit + const DefaultWasmtimeMemoryLimitBytes + const DefaultWasmtimeTableElementsLimit + const EventCodeAcquireLock + const EventCodeAwaitAllChildren + const EventCodeAwaitChild + const EventCodeAwaitPromise + const EventCodeAwaitSignals + const EventCodeCall + const EventCodeChildWorkflow + const EventCodeContinueAsNew + const EventCodeCreatePromise + const EventCodeDefer + const EventCodeDeleteCron + const EventCodeDurableLog + const EventCodeDurableScheduleInvoke + const EventCodeDurableSend + const EventCodeFetch + const EventCodeHeartbeat + const EventCodeListCrons + const EventCodePluginCall + const EventCodePluginCallStreamChunk + const EventCodePromiseRejected + const EventCodePromiseResolved + const EventCodeReleaseLock + const EventCodeRunDetached + const EventCodeScheduleCron + const EventCodeScopeAcquired + const EventCodeSideEffect + const EventCodeSignalReceived + const EventCodeSleep + const EventCodeStateMutation + const EventCodeUpdateHandler + const MaxRetryAttempts + const MisfireCatchUp + const MisfireSkip + const OverlapAllow + const OverlapSkip + const PendingSentinel + var DebugTiming = os.Getenv("CLEAT_DEBUG_TIMING") == "1" + var ErrAdminOpNotImplemented = errors.New("not implemented") + var ErrCrossTenantClaimUnsupported = errors.New("cross-tenant claim not supported by this store's topology") + var ErrFenceLost = errors.New("fence lost: workflow reassigned to another worker (generation mismatch)") + var ErrSuspended = fmt.Errorf("workflow suspended") + var ErrWasmtimeCGOUnavailable = errors.New("wasmtime backend requires CGO (binary built with CGO_ENABLED=0)") + var ErrWorkflowDefOwnedByAnotherTenant = errors.New("workflow definition is owned by another tenant") + var MaxWasmStringLen uint32 = 1048576 + var OutBufSize uint32 = 1048576 + var WasmtimeLanguages = []string + func CatchUpLimitOrDefault(n int) int + func CompactWorkflowHistory(ctx context.Context, store WorkflowStore, workflowID string, threshold int, ...) error + func DeferralsFromHistory(history []EventRecord) map[string]string + func DurableCallIdempotencyKey(workflowID, runID string, step int) string + func ForceComplete(ctx context.Context, store WorkflowStore, workflowID string, generation int64, ...) error + func ForceFail(ctx context.Context, store WorkflowStore, workflowID string, generation int64, ...) error + func FormatRLSBypass(reasons []RLSBypassReason) string + func FreshCallCount() int64 + func FreshStepCount() int64 + func LoadRedactPatterns(path string) error + func LoadScheduleLocation(name string) (*time.Location, bool) + func LogStaleAlerts(alerts []StaleVersionAlert) + func MSSQLConnectionString(host string, port int, user, password, database string) string + func MisfirePolicyOrDefault(p string) string + func NewWasmtimeBackend(ctx context.Context, opts ...WasmtimeOption) (*wasmtimeBackend, error) + func NextCronTime(cronExpr string, from time.Time) time.Time + func NextCronTimeIn(expr string, from time.Time, loc *time.Location) time.Time + func OverlapPolicyOrDefault(p string) string + func ReReplay(ctx context.Context, store WorkflowStore, workflowID string, generation int64, ...) error + func Redact(raw string) string + func RedactMap(m map[string]any) + func RedactOnRead(data string) string + func RegisterVersionHandler(mux *http.ServeMux, resolve VersionStoreResolver) + func ReplayStepCount() int64 + func ResetPatterns() + func ResolveChildVersion(ctx context.Context, db *sql.DB, childName string, parentVersion int, ...) (int, error) + func ResolvePlugins(ctx context.Context, db *sql.DB, pluginDepsJSON string) (map[string]string, error) + func RunsOnWasmtime(lang string) bool + func UpdateNowMs() + func ValidateCronExpr(expr string) error + func ValidateMisfirePolicy(p string) error + func ValidateOverlapPolicy(p string) error + func ValidateTimezone(name string) error + func ValidateVersionCompatibility(oldDef, newDef *WorkflowDef) error + type AWSSecretsManagerProvider struct + func NewAWSSecretsManagerProvider(credentialPath string) *AWSSecretsManagerProvider + func (p *AWSSecretsManagerProvider) GetConnectionString(ctx context.Context) (string, error) + type AdaptiveFlusher struct + func NewAdaptiveFlusher(db *sql.DB, tenantID string, maxWait time.Duration, maxBatch int, ...) *AdaptiveFlusher + func (af *AdaptiveFlusher) Flush(ctx context.Context, workflowID string, rec EventRecord, checksum string, ...) (chan error, bool) + func (af *AdaptiveFlusher) GetRate() float64 + func (af *AdaptiveFlusher) InBatchMode() bool + func (af *AdaptiveFlusher) Run(ctx context.Context) + func (af *AdaptiveFlusher) SetEncryption(encrypt bool, enc *PayloadEncryption) + func (af *AdaptiveFlusher) Stats() (int64, int64, int64) + type AdminActionEvent struct + Action string + Operator string + Reason string + func (e AdminActionEvent) Step() int + func (e AdminActionEvent) Type() EventType + type AmbiguityResolver interface + ResolveCall func(ctx context.Context, service, operation, idempotencyKey string) (response string, resolved bool, err error) + type App struct + func NewApp(ctx context.Context, config AppConfig) (*App, error) + func (a *App) Close() error + func (a *App) Logger() *slog.Logger + func (a *App) Mux() *http.ServeMux + func (a *App) Registry() *PluginRegistry + func (a *App) StreamRegistry() *PluginStreamRegistry + type AppConfig struct + Logger *slog.Logger + Mux *http.ServeMux + PluginConfigs map[string]json.RawMessage + Plugins []plugin.Plugin + Registry *PluginRegistry + Runtime *Runtime + ServiceCaller ServiceCaller + StoreFactory StoreFactory + StreamRegistry *PluginStreamRegistry + type AwaitAllChildrenEvent struct + OutcomesJSON string + RunIDsJSON string + func (e AwaitAllChildrenEvent) Step() int + func (e AwaitAllChildrenEvent) Type() EventType + type AwaitChildEvent struct + Err string + Response string + RunID string + func (e AwaitChildEvent) Step() int + func (e AwaitChildEvent) Type() EventType + type AwaitPromiseEvent struct + PromiseID string + func (e AwaitPromiseEvent) Step() int + func (e AwaitPromiseEvent) Type() EventType + type AwaitSignalsEvent struct + SignalNames string + TimeoutMs int64 + func (e AwaitSignalsEvent) Step() int + func (e AwaitSignalsEvent) Type() EventType + type CacheStats struct + Hits int64 + MaxSize int + Misses int64 + Size int + type CallEvent struct + Err string + Op string + Request string + Response string + Service string + func (e CallEvent) Step() int + func (e CallEvent) Type() EventType + type CallRecord = EventRecord + type CallSemantics int + const AtLeastOnce + const WriteAheadIntent + type ChildWorkflowEvent struct + ChildID string + DefName string + Input string + ParentWorkflowID string + func (e ChildWorkflowEvent) Step() int + func (e ChildWorkflowEvent) Type() EventType + type ChildWorkflowOptions struct + Version int + type ChildWorkflowStore interface + GetChildResult func(ctx context.Context, runID string) (resultJSON string, completed bool, err error) + ResolveVersionByTag func(ctx context.Context, workflowName string, tag string) (int, error) + StartChildWorkflow func(ctx context.Context, parentID, defName, inputJSON string, defVersion int, ...) (string, error) + StartChildWorkflowAtomic func(ctx context.Context, childID, parentID, defName, inputJSON string, ...) (runID string, err error) + type CleatError struct + Code ErrorCode + Err error + Op string + WorkflowID string + func NewAmbiguousError(op, workflowID string, err error) *CleatError + func NewCancelledError(op, workflowID string, err error) *CleatError + func NewPermanentError(op, workflowID string, err error) *CleatError + func NewRetriesExhaustedError(op, workflowID string, err error) *CleatError + func NewTimeoutError(op, workflowID string, err error) *CleatError + func NewTransientError(op, workflowID string, err error) *CleatError + func (e *CleatError) Error() string + func (e *CleatError) Retryable() bool + func (e *CleatError) Unwrap() error + type CloseablePlugin interface + Close func() error + type CompactedChild struct + Input string + Name string + RunID string + type CompactedDefer struct + Description string + ID string + type CompactedEvent struct + ChildInput string + ChildName string + DeferDesc string + DeferID string + DurationMs int64 + ErrNonRetryable bool + Error string + NewInput string + NewVersion int + Op string + ParentClosePolicy string + ParentWorkflowID string + PluginError string + PluginFunc string + PluginInput string + PluginName string + PluginOutput string + PromiseError string + PromiseID string + PromiseName string + PromiseResult string + Request string + Response string + RunID string + Service string + SignalName string + SignalNames string + SignalPayload string + StateKeys string + StreamChunkIndex int + StreamFinish bool + TimeoutMs int64 + TimestampMs int64 + Type int + type CompactionState struct + CompactedStep int + Events []CompactedEvent + OpenChildren []CompactedChild + PendingDefers []CompactedDefer + QueryState map[string]string + Summary *TruncationSummary + Version int + type ConcurrencyKeyInfo struct + AcquiredAt time.Time + ExpiresAt time.Time + KeyHash []byte + KeyText string + WorkflowID string + type ConcurrencyKeyStore interface + AcquireConcurrencyKey func(ctx context.Context, key, workflowID string, ttl time.Duration) (acquired bool, err error) + ReleaseConcurrencyKey func(ctx context.Context, key string) error + type ContinueAsNewEvent struct + NewInput string + func (e ContinueAsNewEvent) Step() int + func (e ContinueAsNewEvent) Type() EventType + type CreatePromiseEvent struct + PromiseID string + PromiseName string + func (e CreatePromiseEvent) Step() int + func (e CreatePromiseEvent) Type() EventType + type CrossSchemaChildStore interface + GetChildResultInSchema func(ctx context.Context, targetSchema, runID string) (resultJSON string, completed bool, err error) + StartChildWorkflowInSchema func(ctx context.Context, targetSchema, parentID, defName, inputJSON string, ...) (string, error) + type CrossTenantCapability struct + Claim bool + ClaimReason string + Schedules bool + SchedulesReason string + type CrossTenantCapabilityChecker interface + CheckCrossTenantCapability func(ctx context.Context) CrossTenantCapability + type CrossTenantClaimer interface + ClaimWorkflowsAcrossTenants func(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + type CrossTenantScheduleReader interface + GetDueSchedulesAcrossTenants func(ctx context.Context) ([]Schedule, error) + type DBCredentialProvider interface + GetConnectionString func(ctx context.Context) (string, error) + func NewDBCredentialProvider(providerName, dbURL, credentialPath string) (DBCredentialProvider, error) + type DBEventStream struct + func NewDBEventStream(db *sql.DB, workflowID string, pageSize int) *DBEventStream + func (s *DBEventStream) Append(rec EventRecord) + func (s *DBEventStream) At(i int) *EventRecord + func (s *DBEventStream) Close() error + func (s *DBEventStream) Len() int + func (s *DBEventStream) Slice(start, end int) []EventRecord + func (s *DBEventStream) Total() (int, error) + type DeferEvent struct + DeferID string + Description string + func (e DeferEvent) Step() int + func (e DeferEvent) Type() EventType + type Dialect string + const DialectMSSQL + const DialectMySQL + const DialectPostgres + type Engine struct + Metrics *prometheus.Metrics + func NewEngine(rt *Runtime, caller ServiceCaller, opts ...EngineOption) *Engine + func (e *Engine) CallerHonoursIdempotencyKeys() bool + func (e *Engine) DB() *sql.DB + func (e *Engine) DispatchUpdate(ctx context.Context, name, payload string) (string, error) + func (e *Engine) EncryptSensitivePayloads() bool + func (e *Engine) Encryption() *PayloadEncryption + func (e *Engine) Execute(ctx context.Context, wasmBytes []byte, entryPoint string, ...) (result string, history []EventRecord, suspended *SuspendResult, ...) + func (e *Engine) ExecuteCompiled(ctx context.Context, compiled wazero.CompiledModule, entryPoint string, ...) (result string, history []EventRecord, suspended *SuspendResult, ...) + func (e *Engine) Replay(ctx context.Context, wasmBytes []byte, entryPoint string, ...) (result string, resultHistory []EventRecord, suspended *SuspendResult, ...) + func (e *Engine) ReplayCompiled(ctx context.Context, compiled wazero.CompiledModule, entryPoint string, ...) (result string, resultHistory []EventRecord, suspended *SuspendResult, ...) + func (e *Engine) RunDefer(ctx context.Context, wasmBytes []byte, deferName string, input json.RawMessage) (string, error) + func (e *Engine) RunDeferCompiled(ctx context.Context, compiled wazero.CompiledModule, deferName string, ...) (string, error) + func (e *Engine) TenantID() string + type EngineOption func(*Engine) + func WithAllowVersionMismatch(allow bool) EngineOption + func WithAmbiguityResolver(r AmbiguityResolver) EngineOption + func WithBackend(language string, backend WasmBackend) EngineOption + func WithBackends(languages []string, backend WasmBackend) EngineOption + func WithCancellationCheckInterval(d time.Duration) EngineOption + func WithChildBindingOverride(override string) EngineOption + func WithChildBindingPolicy(policy string) EngineOption + func WithChildWorkflowStore(cws ChildWorkflowStore) EngineOption + func WithCompactionState(cs *CompactionState) EngineOption + func WithConcurrencyKeyStore(cks ConcurrencyKeyStore) EngineOption + func WithContinueAsNewHandler(...) EngineOption + func WithDB(db *sql.DB) EngineOption + func WithDefName(name string) EngineOption + func WithDefVersion(v int) EngineOption + func WithDefaultWorkflowTimeout(d time.Duration) EngineOption + func WithEncryption(enc *PayloadEncryption, enabled bool) EngineOption + func WithFetcher(f Fetcher) EngineOption + func WithFlusherRegistry(r *TenantFlusherRegistry) EngineOption + func WithGeneration(generation int64) EngineOption + func WithInitialEventCount(n int) EngineOption + func WithLogger(l *slog.Logger) EngineOption + func WithMaxQuotaChildren(n int) EngineOption + func WithMaxQuotaConcurrencyKeys(n int) EngineOption + func WithMaxQuotaEvents(n int) EngineOption + func WithMaxQuotaSchedules(n int) EngineOption + func WithMaxRetryAttempts(n int) EngineOption + func WithNoPerStepFlush(v bool) EngineOption + func WithPeerSchemas(schemas []string) EngineOption + func WithPluginCallGuard(g *PluginCallGuard) EngineOption + func WithPluginCallObserver(o PluginCallObserver) EngineOption + func WithPluginRegistry(pr *PluginRegistry) EngineOption + func WithPluginStreamRegistry(psr *PluginStreamRegistry) EngineOption + func WithPromiseStore(ps PromiseStore) EngineOption + func WithReplayStepCallback(cb ReplayStepCallback) EngineOption + func WithRequireSignalAuth(v bool) EngineOption + func WithSchema(schema string) EngineOption + func WithSignalAuthCheck(fn func(ctx context.Context, targetWorkflowID, callerDefName string) error) EngineOption + func WithSignalStore(ss SignalStore) EngineOption + func WithTenantID(id string) EngineOption + func WithTraceID(id string) EngineOption + func WithUpdateHandler(fn func(name, payload string) (string, error)) EngineOption + func WithVersionValidation(fn func() error) EngineOption + func WithWASMInstanceTimeout(d time.Duration) EngineOption + func WithWasmCumulativeAllocationMax(maxBytes int64, counter *atomic.Int64) EngineOption + func WithWorkerID(id string) EngineOption + func WithWorkflowEventVerifier(fn func(ctx context.Context, workflowID string) error, failOnMismatch bool) EngineOption + func WithWorkflowID(id string) EngineOption + func WithWorkflowState(ws WorkflowState) EngineOption + func WithWorkflowStore(store WorkflowStore) EngineOption + func WithWriteAheadIntentOps(ops ...string) EngineOption + type EnvCredentialProvider struct + func NewEnvCredentialProvider(dbURL string) *EnvCredentialProvider + func (p *EnvCredentialProvider) GetConnectionString(_ context.Context) (string, error) + type ErrorCode int + const ErrAmbiguous + const ErrCancelled + const ErrPermanent + const ErrRetriesExhausted + const ErrTimeout + const ErrTransient + const ErrUnknown + func (c ErrorCode) String() string + type Event interface + Step func() int + Type func() EventType + func EventFromRecord(r EventRecord) Event + func EventsFromRecords(records []EventRecord) []Event + type EventRecord struct + ChildInput string + ChildName string + CreatedAt time.Time + CronExpr string + CronInput string + CronResult string + CronScheduleID string + CronTimezone string + CronWorkflowName string + DeferDescription string + DeferID string + DetachedInput string + DetachedName string + DetachedRunID string + DurationMs int64 + Err string + ErrNonRetryable bool + EventType EventType + FetchBody string + FetchHeaders string + FetchMethod string + FetchResponse string + FetchURL string + Idempotent bool + LockAcquired int + LockKey string + LockTTLMs int64 + LogKV string + LogLevel string + Message string + NewInput string + NewVersion int + Op string + ParentClosePolicy string + ParentWorkflowID string + Pending bool + PluginError string + PluginFunc string + PluginInput string + PluginName string + PluginOutput string + PromiseError string + PromiseID string + PromiseName string + PromiseResult string + Request string + Response string + RunID string + ScopeKey string + Service string + SideEffectResult string + SignalName string + SignalNames string + SignalPayload string + StateDelta int64 + StateKey string + StateKeys string + StateOp string + StateValue string + Step int + StreamChunkIndex int + StreamFinish bool + TimeoutMs int64 + TimestampMs int64 + UpdateError string + UpdateHandlerName string + UpdatePayload string + UpdateResponse string + func EventRecordFromEvent(e Event) EventRecord + func RecordsFromEvents(events []Event) []EventRecord + type EventStream interface + Append func(rec EventRecord) + At func(i int) *EventRecord + Close func() error + Len func() int + Slice func(start, end int) []EventRecord + Total func() (int, error) + func AsEventStream(events []EventRecord) EventStream + type EventType string + const EventTypeAcquireLock + const EventTypeAdminAction + const EventTypeAwaitAllChildren + const EventTypeAwaitAnyChild + const EventTypeAwaitChild + const EventTypeAwaitPromise + const EventTypeAwaitSignals + const EventTypeCall + const EventTypeChildWorkflow + const EventTypeContinueAsNew + const EventTypeCreatePromise + const EventTypeDefer + const EventTypeDeleteCron + const EventTypeDurableLog + const EventTypeDurableScheduleInvoke + const EventTypeDurableSend + const EventTypeFetch + const EventTypeHeartbeat + const EventTypeListCrons + const EventTypePluginCall + const EventTypePluginCallStreamChunk + const EventTypePollChild + const EventTypePromiseRejected + const EventTypePromiseResolved + const EventTypeReleaseLock + const EventTypeRunDetached + const EventTypeScheduleCron + const EventTypeScopeAcquired + const EventTypeSideEffect + const EventTypeSignalReceived + const EventTypeStateMutation + const EventTypeUpdateHandler + type ExecResult struct + Result string + Suspended bool + type ExecutionResult struct + Deferrals map[string]string + History []EventRecord + QueryState map[string]string + Result string + Suspended *SuspendResult + type FaultInjector struct + func NewFaultInjector(db *sql.DB) *FaultInjector + func (fi *FaultInjector) ActiveFaults() []FaultType + func (fi *FaultInjector) Cleanup() + func (fi *FaultInjector) Context(ctx context.Context) context.Context + func (fi *FaultInjector) InjectClockSkew(offset time.Duration) + func (fi *FaultInjector) InjectDiskLatency(min, max time.Duration) + func (fi *FaultInjector) InjectNetworkPartition() + func (fi *FaultInjector) InjectWorkerCrash(workerID string) + func (fi *FaultInjector) IsActive(ft FaultType) bool + func (fi *FaultInjector) Reset() + type FaultType int + const FaultClockSkew + const FaultDiskFull + const FaultDiskSlow + const FaultNetworkPartition + const FaultWorkerCrash + func (ft FaultType) String() string + type Fetcher interface + Fetch func(ctx context.Context, method, url, headersJSON, body string) (responseJSON string, err error) + type FlusherConfig struct + EnterThreshold float64 + ExitThreshold float64 + MaxBatch int + MaxWait time.Duration + type GCOptions struct + DryRun bool + MaxVersionAge time.Duration + MinVersionsToKeep int + Now time.Time + func DefaultGCOptions() GCOptions + type GCResult struct + Errors []error + VersionsRemoved int + VersionsSkipped int + func GarbageCollectVersions(ctx context.Context, store WorkflowStore, opts GCOptions) (*GCResult, error) + func PurgeVersions(ctx context.Context, store WorkflowStore, workflowName string, ...) (*GCResult, error) + type GuestCallErrorCode struct + Code byte + Name string + Retryable bool + func GuestCallErrorCodes() []GuestCallErrorCode + type HeartbeatEvent struct + func (e HeartbeatEvent) Step() int + func (e HeartbeatEvent) Type() EventType + type HostHandler interface + AcquireLock func(ctx context.Context, m api.Module, key string, ttlMs int64) int64 + AwaitAllChildren func(ctx context.Context, m api.Module, runIDsJSON string, ...) int64 + AwaitAnyChild func(ctx context.Context, m api.Module, runIDsJSON string, ...) int64 + AwaitChild func(ctx context.Context, m api.Module, runID string, ...) int64 + AwaitPromise func(ctx context.Context, m api.Module, promiseID string, timeoutMs int64, ...) int64 + ChildWorkflow func(ctx context.Context, m api.Module, name, inputJSON string, ...) int64 + ChildWorkflowInSchema func(ctx context.Context, m api.Module, targetSchema, name, inputJSON string, ...) int64 + ChildWorkflowWithOptions func(ctx context.Context, m api.Module, name, inputJSON string, version int64, ...) int64 + ContinueAsNew func(ctx context.Context, m api.Module, newInputJSON string) int64 + ContinueAsNewWithVersion func(ctx context.Context, m api.Module, newInputJSON string, newVersion int) int64 + CreatePromise func(ctx context.Context, m api.Module, name string, ...) int64 + DeleteCron func(ctx context.Context, m api.Module, scheduleID string) int64 + DeleteState func(ctx context.Context, m api.Module, key string) int64 + DurableAwaitSignals func(ctx context.Context, m api.Module, signalNames string, timeoutMs int64, ...) int64 + DurableCall func(ctx context.Context, m api.Module, service, operation, requestJSON string, ...) int64 + DurableCallWithHeartbeat func(ctx context.Context, m api.Module, service, operation, requestJSON string, ...) int64 + DurableCallWithRetry func(ctx context.Context, m api.Module, service, operation, requestJSON string, ...) int64 + DurableDefer func(ctx context.Context, m api.Module, description string, ...) int64 + DurableLog func(ctx context.Context, m api.Module, message string) int64 + DurableScheduleInvoke func(ctx context.Context, m api.Module, service, operation, requestJSON string, ...) int64 + DurableSend func(ctx context.Context, m api.Module, service, operation, requestJSON string) int64 + DurableSleep func(ctx context.Context, m api.Module, durationMs int64) int64 + Fetch func(ctx context.Context, m api.Module, method, url, headersJSON, body string, ...) int64 + GetScope func(ctx context.Context, m api.Module, ...) int64 + GetState func(ctx context.Context, m api.Module, key string, valuePtr, valueMaxLen uint32) int64 + HasState func(ctx context.Context, m api.Module, key string) int64 + IncrState func(ctx context.Context, m api.Module, key string, delta int64) int64 + JsonParse func(ctx context.Context, m api.Module, input string, outPtr, outMaxLen uint32) int64 + JsonStringify func(ctx context.Context, m api.Module, input string, outPtr, outMaxLen uint32) int64 + ListCrons func(ctx context.Context, m api.Module, outPtr, outMaxLen uint32) int64 + ListState func(ctx context.Context, m api.Module, prefix string, keysPtr, keysMaxLen uint32) int64 + MinVersion func(ctx context.Context) int64 + Now func(ctx context.Context) int64 + PluginCall func(ctx context.Context, m api.Module, pluginName, functionName, inputJSON string, ...) int64 + PluginCallStreaming func(ctx context.Context, m api.Module, pluginName, functionName, inputJSON string, ...) int64 + PollCancellation func(ctx context.Context, m api.Module, reasonPtr, reasonMaxLen uint32) int64 + PollChild func(ctx context.Context, m api.Module, runID string, ...) int64 + PollSignal func(ctx context.Context, m api.Module, signalName string, ...) int64 + Random func(ctx context.Context) int64 + RegisterQueryHandler func(ctx context.Context, m api.Module, name string) int64 + RegisterUpdateHandler func(ctx context.Context, m api.Module, name string) int64 + RejectPromise func(ctx context.Context, m api.Module, promiseID, errMsg string) int64 + ReleaseLock func(ctx context.Context, m api.Module, key string) int64 + ReplyToSignal func(ctx context.Context, m api.Module, correlationID, response string) int64 + ResolvePromise func(ctx context.Context, m api.Module, promiseID, value string) int64 + RunDetached func(ctx context.Context, m api.Module, name, inputJSON string) int64 + RunID func(ctx context.Context, m api.Module, idPtr, idMaxLen uint32) int64 + ScheduleCron func(ctx context.Context, m api.Module, ...) int64 + SendSignalAndWait func(ctx context.Context, m api.Module, targetRunID, signalName, payload string, ...) int64 + SetQueryState func(ctx context.Context, m api.Module, key, value string) int64 + SetScope func(ctx context.Context, m api.Module, objectType, instanceKey string, ...) int64 + SetState func(ctx context.Context, m api.Module, key, value string) int64 + SideEffect func(ctx context.Context, m api.Module, computedResult string, ...) int64 + SignalWorkflow func(ctx context.Context, m api.Module, targetRunID, signalName, payload string) int64 + UUID func(ctx context.Context, m api.Module, seed string, uuidPtr, uuidMaxLen uint32) int64 + Version func(ctx context.Context) int64 + WorkflowID func(ctx context.Context, m api.Module, idPtr, idMaxLen uint32) int64 + type IdempotentCaller interface + CallWithIdempotencyKey func(ctx context.Context, service, operation, requestJSON, idempotencyKey string) (responseJSON string, err error) + type MSSQLStore struct + func NewMSSQLStore(db *sql.DB, taskQueues ...string) *MSSQLStore + func (s *MSSQLStore) AcquireConcurrencyKey(ctx context.Context, key, workflowID string, ttl time.Duration) (bool, error) + func (s *MSSQLStore) AdminForceComplete(ctx context.Context, workflowID string, generation int64, result string, ...) error + func (s *MSSQLStore) AdminForceFail(ctx context.Context, workflowID string, generation int64, ...) error + func (s *MSSQLStore) AdminReReplay(ctx context.Context, workflowID string, generation int64, operator string) error + func (s *MSSQLStore) AppendEventHistory(ctx context.Context, workflowID string, rec EventRecord) error + func (s *MSSQLStore) AppendEventHistoryBatch(ctx context.Context, workflowID string, recs []EventRecord) error + func (s *MSSQLStore) BatchHeartbeat(ctx context.Context, workerID string) (int64, error) + func (s *MSSQLStore) CheckCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *MSSQLStore) CheckCrossTenantCapability(ctx context.Context) CrossTenantCapability + func (s *MSSQLStore) ClaimDueSchedule(ctx context.Context, name string, expectedNextRun, newNextRun time.Time, ...) (bool, error) + func (s *MSSQLStore) ClaimStickyWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *MSSQLStore) ClaimWorkflow(ctx context.Context, workerID string) (*WorkflowInstance, error) + func (s *MSSQLStore) ClaimWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *MSSQLStore) ClaimWorkflowsAcrossTenants(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *MSSQLStore) CleanupMemorySamples(ctx context.Context, maxSamplesPerDef int) (int64, error) + func (s *MSSQLStore) ClearStickyWorker(ctx context.Context, workflowID string) error + func (s *MSSQLStore) CompactHistory(ctx context.Context, workflowID string, compactionState []byte, ...) error + func (s *MSSQLStore) CompleteCallIntent(ctx context.Context, workflowID string, rec EventRecord, payload []byte, ...) error + func (s *MSSQLStore) CompleteUpdateRequest(ctx context.Context, workflowID, updateName, result, errMsg string) error + func (s *MSSQLStore) CompleteWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MSSQLStore) ContinueAsNew(ctx context.Context, currentRunID, workerID string, generation int64, ...) (string, error) + func (s *MSSQLStore) CountActiveInstances(ctx context.Context, name string, version int) (int, error) + func (s *MSSQLStore) CountEventHistory(ctx context.Context, workflowID string) (int, error) + func (s *MSSQLStore) CreatePromise(ctx context.Context, workflowID, promiseName, promiseID string) error + func (s *MSSQLStore) CreateSchedule(ctx context.Context, sch Schedule) error + func (s *MSSQLStore) CreateUpdateRequest(ctx context.Context, workflowID, updateName, payload, promiseID string) error + func (s *MSSQLStore) DeleteCompletedWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *MSSQLStore) DeleteDeadLetteredWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *MSSQLStore) DeleteExpiredEvents(ctx context.Context, olderThan time.Time) (int64, error) + func (s *MSSQLStore) DeleteSchedule(ctx context.Context, name string) error + func (s *MSSQLStore) DeliverSignal(ctx context.Context, workflowID, signalName, payload string) error + func (s *MSSQLStore) DeployWorkflowDef(ctx context.Context, def *WorkflowDef) error + func (s *MSSQLStore) FailWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MSSQLStore) FinalizeWorkflowSegment(ctx context.Context, runID, workerID string, generation int64, ...) error + func (s *MSSQLStore) GetActiveInstanceCountsByVersion(ctx context.Context) (map[string]int, error) + func (s *MSSQLStore) GetAllowedSignalCallers(ctx context.Context, workflowID string) ([]string, error) + func (s *MSSQLStore) GetChildCount(ctx context.Context, parentWorkflowID string) (int, error) + func (s *MSSQLStore) GetChildResult(ctx context.Context, runID string) (string, bool, error) + func (s *MSSQLStore) GetCompactionCandidates(ctx context.Context, threshold int, limit int) ([]string, error) + func (s *MSSQLStore) GetConcurrencyKeyCount(ctx context.Context, workflowID string) (int, error) + func (s *MSSQLStore) GetDueSchedules(ctx context.Context) ([]Schedule, error) + func (s *MSSQLStore) GetDueSchedulesAcrossTenants(ctx context.Context) ([]Schedule, error) + func (s *MSSQLStore) GetEventCount(ctx context.Context, workflowID string) (int, error) + func (s *MSSQLStore) GetPendingUpdateRequests(ctx context.Context, workflowID string) ([]UpdateRequestInfo, error) + func (s *MSSQLStore) GetPromise(ctx context.Context, workflowID, promiseID string) (string, string, string, error) + func (s *MSSQLStore) GetQueryState(ctx context.Context, workflowID, key string) (string, error) + func (s *MSSQLStore) GetRoutingRules(ctx context.Context, workflowName string) ([]RoutingRule, error) + func (s *MSSQLStore) GetWASMLength(ctx context.Context, defName string, defVersion int) (int64, error) + func (s *MSSQLStore) GetWorkflowByID(ctx context.Context, id string) (*WorkflowInstance, error) + func (s *MSSQLStore) GetWorkflowDef(ctx context.Context, name string, version int) (*WorkflowDef, error) + func (s *MSSQLStore) GetWorkflowTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *MSSQLStore) GetWorkflowTags(ctx context.Context, workflowName string) (map[string]int, error) + func (s *MSSQLStore) Heartbeat(ctx context.Context, workflowID, workerID string, generation int64) (bool, error) + func (s *MSSQLStore) ListPromises(ctx context.Context, workflowID string) ([]PromiseInfo, error) + func (s *MSSQLStore) ListSchedules(ctx context.Context) ([]Schedule, error) + func (s *MSSQLStore) ListVersions(ctx context.Context, defName string) ([]int, error) + func (s *MSSQLStore) ListWorkflowDefs(ctx context.Context, name string) ([]WorkflowDef, error) + func (s *MSSQLStore) ListWorkflows(ctx context.Context, filter WorkflowFilter) ([]WorkflowInstance, error) + func (s *MSSQLStore) LoadCompactionState(ctx context.Context, workflowID string) (*CompactionState, error) + func (s *MSSQLStore) LoadDAGSpec(ctx context.Context, defName string, defVersion int) (json.RawMessage, error) + func (s *MSSQLStore) LoadEventHistory(ctx context.Context, workflowID string) ([]EventRecord, error) + func (s *MSSQLStore) LoadEventHistoryPaginated(ctx context.Context, workflowID string, offset, limit int) ([]EventRecord, error) + func (s *MSSQLStore) LoadMemoryEstimates(ctx context.Context) (map[string]float64, error) + func (s *MSSQLStore) LoadMemoryStats(ctx context.Context) ([]WorkflowMemoryStats, error) + func (s *MSSQLStore) LoadWASM(ctx context.Context, defName string, defVersion int) ([]byte, error) + func (s *MSSQLStore) LoadWorkflowConfig(ctx context.Context, defName string, defVersion int) (int, error) + func (s *MSSQLStore) MarkVersionDeprecated(ctx context.Context, name string, version int, deprecated bool) error + func (s *MSSQLStore) MoveToDeadLetterQueue(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MSSQLStore) PickVersionByRouting(ctx context.Context, workflowName string) (int, error) + func (s *MSSQLStore) PollAndClaimSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *MSSQLStore) PollCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *MSSQLStore) PollSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *MSSQLStore) PurgeWorkflowDef(ctx context.Context, name string, version int) error + func (s *MSSQLStore) QueueDepth(ctx context.Context) (int64, error) + func (s *MSSQLStore) ReapExpiredConcurrencyKeys(ctx context.Context) (int64, error) + func (s *MSSQLStore) ReapStaleInstances(ctx context.Context, timeout time.Duration) (int, error) + func (s *MSSQLStore) RecordWorkflowMemorySample(ctx context.Context, defName string, sampleBytes int64) error + func (s *MSSQLStore) RejectPromise(ctx context.Context, workflowID, promiseID, errMsg string) error + func (s *MSSQLStore) ReleaseConcurrencyKey(ctx context.Context, key string) error + func (s *MSSQLStore) ReleaseWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MSSQLStore) ReleaseWorkflowConcurrencyKeys(ctx context.Context, workflowID string) error + func (s *MSSQLStore) RemoveRoutingRule(ctx context.Context, ruleID string) error + func (s *MSSQLStore) RemoveWorkflowTag(ctx context.Context, workflowName string, tag string) error + func (s *MSSQLStore) RequestCancellation(ctx context.Context, workflowID, reason string) error + func (s *MSSQLStore) ResolveCallIntent(ctx context.Context, workflowID string, rec EventRecord, payload []byte, ...) error + func (s *MSSQLStore) ResolveLatestVersion(ctx context.Context, defName string) (int, error) + func (s *MSSQLStore) ResolvePromise(ctx context.Context, workflowID, promiseID, result string) error + func (s *MSSQLStore) ResolveTenantFromAPIKey(ctx context.Context, keyHash []byte) (uuid.UUID, error) + func (s *MSSQLStore) ResolveVersionByTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *MSSQLStore) RetryWorkflow(ctx context.Context, workflowID string) error + func (s *MSSQLStore) SetRoutingRule(ctx context.Context, workflowName string, targetVersion int, weight float64) error + func (s *MSSQLStore) SetScheduleEnabled(ctx context.Context, name string, enabled bool) error + func (s *MSSQLStore) SetWorkflowTag(ctx context.Context, workflowName string, version int, tag string) error + func (s *MSSQLStore) StartChildWorkflow(ctx context.Context, parentID, defName, inputJSON string, defVersion int, ...) (string, error) + func (s *MSSQLStore) StartChildWorkflowAtomic(ctx context.Context, childID, parentID, defName, inputJSON string, ...) (string, error) + func (s *MSSQLStore) StartNewRun(ctx context.Context, runID, defName string, defVersion int, ...) (string, bool, error) + func (s *MSSQLStore) StreamEventHistory(ctx context.Context, workflowID string, pageSize int) (<-chan EventRecord, <-chan error) + func (s *MSSQLStore) TerminateWorkflow(ctx context.Context, workflowID, reason string) error + func (s *MSSQLStore) TraceWorkflow(ctx context.Context, workflowID, traceID string) error + func (s *MSSQLStore) UpdateScheduleNextRun(ctx context.Context, name string, nextRun time.Time) error + func (s *MSSQLStore) UpdateStickyWorker(ctx context.Context, workflowID, workerID string) error + func (s *MSSQLStore) ValidateVersion(ctx context.Context, defName string, defVersion int) (bool, error) + func (s *MSSQLStore) VerifyWorkflowEvents(ctx context.Context, workflowID string) error + func (s *MSSQLStore) WithEncryption(enc *PayloadEncryption, enabled bool) *MSSQLStore + func (s *MSSQLStore) WithIdempotencyKeyTTL(ttl time.Duration) *MSSQLStore + func (s *MSSQLStore) WithLogger(l *slog.Logger) *MSSQLStore + func (s *MSSQLStore) WithReadRedactionDisabled(disabled bool) *MSSQLStore + func (s *MSSQLStore) WithTenant(tenantID string) *MSSQLStore + func (s *MSSQLStore) WriteCallIntent(ctx context.Context, workflowID string, rec EventRecord, workerID string, ...) error + type MSSQLStoreFactory struct + func NewMSSQLStoreFactory(connStr string, idempotencyKeyTTL ...time.Duration) *MSSQLStoreFactory + func (f *MSSQLStoreFactory) Close() error + func (f *MSSQLStoreFactory) Dialect() Dialect + func (f *MSSQLStoreFactory) DriverName() string + func (f *MSSQLStoreFactory) OpenStore(ctx context.Context, tenantID string, taskQueues ...string) (WorkflowStore, io.Closer, error) + func (f *MSSQLStoreFactory) WithLogger(l *slog.Logger) *MSSQLStoreFactory + func (f *MSSQLStoreFactory) WithTenantPoolMaxConns(n int) *MSSQLStoreFactory + type MySQLStore struct + func NewMySQLStore(db *sql.DB, taskQueues ...string) *MySQLStore + func (s *MySQLStore) AcquireConcurrencyKey(ctx context.Context, key, workflowID string, ttl time.Duration) (bool, error) + func (s *MySQLStore) AdminForceComplete(ctx context.Context, workflowID string, generation int64, result string, ...) error + func (s *MySQLStore) AdminForceFail(ctx context.Context, workflowID string, generation int64, ...) error + func (s *MySQLStore) AdminReReplay(ctx context.Context, workflowID string, generation int64, operator string) error + func (s *MySQLStore) AppendEventHistory(ctx context.Context, workflowID string, rec EventRecord) error + func (s *MySQLStore) AppendEventHistoryBatch(ctx context.Context, workflowID string, recs []EventRecord) error + func (s *MySQLStore) BatchHeartbeat(ctx context.Context, workerID string) (int64, error) + func (s *MySQLStore) CheckCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *MySQLStore) CheckCrossTenantCapability(ctx context.Context) CrossTenantCapability + func (s *MySQLStore) ClaimDueSchedule(ctx context.Context, name string, expectedNextRun, newNextRun time.Time, ...) (bool, error) + func (s *MySQLStore) ClaimStickyWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *MySQLStore) ClaimWorkflow(ctx context.Context, workerID string) (*WorkflowInstance, error) + func (s *MySQLStore) ClaimWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *MySQLStore) ClaimWorkflowsAcrossTenants(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *MySQLStore) CleanupMemorySamples(ctx context.Context, maxSamplesPerDef int) (int64, error) + func (s *MySQLStore) ClearStickyWorker(ctx context.Context, workflowID string) error + func (s *MySQLStore) CompactHistory(ctx context.Context, workflowID string, compactionState []byte, ...) error + func (s *MySQLStore) CompleteCallIntent(ctx context.Context, workflowID string, rec EventRecord, payload []byte, ...) error + func (s *MySQLStore) CompleteUpdateRequest(ctx context.Context, workflowID, updateName, result, errMsg string) error + func (s *MySQLStore) CompleteWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MySQLStore) ContinueAsNew(ctx context.Context, currentRunID, workerID string, generation int64, ...) (string, error) + func (s *MySQLStore) CountActiveInstances(ctx context.Context, name string, version int) (int, error) + func (s *MySQLStore) CountEventHistory(ctx context.Context, workflowID string) (int, error) + func (s *MySQLStore) CreatePromise(ctx context.Context, workflowID, promiseName, promiseID string) error + func (s *MySQLStore) CreateSchedule(ctx context.Context, sch Schedule) error + func (s *MySQLStore) CreateUpdateRequest(ctx context.Context, workflowID, updateName, payload, promiseID string) error + func (s *MySQLStore) DeleteCompletedWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *MySQLStore) DeleteDeadLetteredWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *MySQLStore) DeleteExpiredEvents(ctx context.Context, olderThan time.Time) (int64, error) + func (s *MySQLStore) DeleteSchedule(ctx context.Context, name string) error + func (s *MySQLStore) DeliverSignal(ctx context.Context, workflowID, signalName, payload string) error + func (s *MySQLStore) DeployWorkflowDef(ctx context.Context, def *WorkflowDef) error + func (s *MySQLStore) FailWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MySQLStore) FinalizeWorkflowSegment(ctx context.Context, runID, workerID string, generation int64, ...) error + func (s *MySQLStore) GetActiveInstanceCountsByVersion(ctx context.Context) (map[string]int, error) + func (s *MySQLStore) GetAllowedSignalCallers(ctx context.Context, workflowID string) ([]string, error) + func (s *MySQLStore) GetChildCount(ctx context.Context, parentWorkflowID string) (int, error) + func (s *MySQLStore) GetChildResult(ctx context.Context, runID string) (string, bool, error) + func (s *MySQLStore) GetCompactionCandidates(ctx context.Context, threshold int, limit int) ([]string, error) + func (s *MySQLStore) GetConcurrencyKeyCount(ctx context.Context, workflowID string) (int, error) + func (s *MySQLStore) GetDueSchedules(ctx context.Context) ([]Schedule, error) + func (s *MySQLStore) GetDueSchedulesAcrossTenants(ctx context.Context) ([]Schedule, error) + func (s *MySQLStore) GetEventCount(ctx context.Context, workflowID string) (int, error) + func (s *MySQLStore) GetPendingUpdateRequests(ctx context.Context, workflowID string) ([]UpdateRequestInfo, error) + func (s *MySQLStore) GetPromise(ctx context.Context, workflowID, promiseID string) (status string, result string, errMsg string, err error) + func (s *MySQLStore) GetQueryState(ctx context.Context, workflowID, key string) (string, error) + func (s *MySQLStore) GetRoutingRules(ctx context.Context, workflowName string) ([]RoutingRule, error) + func (s *MySQLStore) GetWASMLength(ctx context.Context, defName string, defVersion int) (int64, error) + func (s *MySQLStore) GetWorkflowByID(ctx context.Context, id string) (*WorkflowInstance, error) + func (s *MySQLStore) GetWorkflowDef(ctx context.Context, name string, version int) (*WorkflowDef, error) + func (s *MySQLStore) GetWorkflowTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *MySQLStore) GetWorkflowTags(ctx context.Context, workflowName string) (map[string]int, error) + func (s *MySQLStore) Heartbeat(ctx context.Context, workflowID, workerID string, generation int64) (bool, error) + func (s *MySQLStore) ListPromises(ctx context.Context, workflowID string) ([]PromiseInfo, error) + func (s *MySQLStore) ListSchedules(ctx context.Context) ([]Schedule, error) + func (s *MySQLStore) ListVersions(ctx context.Context, defName string) ([]int, error) + func (s *MySQLStore) ListWorkflowDefs(ctx context.Context, name string) ([]WorkflowDef, error) + func (s *MySQLStore) ListWorkflows(ctx context.Context, filter WorkflowFilter) ([]WorkflowInstance, error) + func (s *MySQLStore) LoadCompactionState(ctx context.Context, workflowID string) (*CompactionState, error) + func (s *MySQLStore) LoadDAGSpec(ctx context.Context, defName string, defVersion int) (json.RawMessage, error) + func (s *MySQLStore) LoadEventHistory(ctx context.Context, workflowID string) ([]EventRecord, error) + func (s *MySQLStore) LoadEventHistoryPaginated(ctx context.Context, workflowID string, offset, limit int) ([]EventRecord, error) + func (s *MySQLStore) LoadMemoryEstimates(ctx context.Context) (map[string]float64, error) + func (s *MySQLStore) LoadMemoryStats(ctx context.Context) ([]WorkflowMemoryStats, error) + func (s *MySQLStore) LoadWASM(ctx context.Context, defName string, defVersion int) ([]byte, error) + func (s *MySQLStore) LoadWorkflowConfig(ctx context.Context, defName string, defVersion int) (int, error) + func (s *MySQLStore) MarkVersionDeprecated(ctx context.Context, name string, version int, deprecated bool) error + func (s *MySQLStore) MoveToDeadLetterQueue(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MySQLStore) PickVersionByRouting(ctx context.Context, workflowName string) (int, error) + func (s *MySQLStore) PollAndClaimSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *MySQLStore) PollCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *MySQLStore) PollSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *MySQLStore) PurgeWorkflowDef(ctx context.Context, name string, version int) error + func (s *MySQLStore) QueueDepth(ctx context.Context) (int64, error) + func (s *MySQLStore) ReapExpiredConcurrencyKeys(ctx context.Context) (int64, error) + func (s *MySQLStore) ReapStaleInstances(ctx context.Context, timeout time.Duration) (int, error) + func (s *MySQLStore) RecordWorkflowMemorySample(ctx context.Context, defName string, sampleBytes int64) error + func (s *MySQLStore) RejectPromise(ctx context.Context, workflowID, promiseID, errMsg string) error + func (s *MySQLStore) ReleaseConcurrencyKey(ctx context.Context, key string) error + func (s *MySQLStore) ReleaseWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *MySQLStore) ReleaseWorkflowConcurrencyKeys(ctx context.Context, workflowID string) error + func (s *MySQLStore) RemoveRoutingRule(ctx context.Context, ruleID string) error + func (s *MySQLStore) RemoveWorkflowTag(ctx context.Context, workflowName string, tag string) error + func (s *MySQLStore) RequestCancellation(ctx context.Context, workflowID, reason string) error + func (s *MySQLStore) ResolveCallIntent(ctx context.Context, workflowID string, rec EventRecord, payload []byte, ...) error + func (s *MySQLStore) ResolveLatestVersion(ctx context.Context, defName string) (int, error) + func (s *MySQLStore) ResolvePromise(ctx context.Context, workflowID, promiseID, result string) error + func (s *MySQLStore) ResolveTenantFromAPIKey(ctx context.Context, keyHash []byte) (uuid.UUID, error) + func (s *MySQLStore) ResolveVersionByTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *MySQLStore) RetryWorkflow(ctx context.Context, workflowID string) error + func (s *MySQLStore) SetRoutingRule(ctx context.Context, workflowName string, targetVersion int, weight float64) error + func (s *MySQLStore) SetScheduleEnabled(ctx context.Context, name string, enabled bool) error + func (s *MySQLStore) SetWorkflowTag(ctx context.Context, workflowName string, version int, tag string) error + func (s *MySQLStore) StartChildWorkflow(ctx context.Context, parentID, defName, inputJSON string, defVersion int, ...) (string, error) + func (s *MySQLStore) StartChildWorkflowAtomic(ctx context.Context, childID, parentID, defName, inputJSON string, ...) (string, error) + func (s *MySQLStore) StartNewRun(ctx context.Context, runID, defName string, defVersion int, ...) (string, bool, error) + func (s *MySQLStore) StreamEventHistory(ctx context.Context, workflowID string, pageSize int) (<-chan EventRecord, <-chan error) + func (s *MySQLStore) TerminateWorkflow(ctx context.Context, workflowID, reason string) error + func (s *MySQLStore) TraceWorkflow(ctx context.Context, workflowID, traceID string) error + func (s *MySQLStore) UpdateScheduleNextRun(ctx context.Context, name string, nextRun time.Time) error + func (s *MySQLStore) UpdateStickyWorker(ctx context.Context, workflowID, workerID string) error + func (s *MySQLStore) ValidateVersion(ctx context.Context, defName string, defVersion int) (bool, error) + func (s *MySQLStore) VerifyWorkflowEvents(ctx context.Context, workflowID string) error + func (s *MySQLStore) WithEncryption(enc *PayloadEncryption, enabled bool) *MySQLStore + func (s *MySQLStore) WithIdempotencyKeyTTL(ttl time.Duration) *MySQLStore + func (s *MySQLStore) WithLogger(l *slog.Logger) *MySQLStore + func (s *MySQLStore) WithReadRedactionDisabled(disabled bool) *MySQLStore + func (s *MySQLStore) WithTenant(tenantID string) *MySQLStore + func (s *MySQLStore) WriteCallIntent(ctx context.Context, workflowID string, rec EventRecord, workerID string, ...) error + type MySQLStoreFactory struct + func NewMySQLStoreFactory(masterDB *sql.DB, baseDSN string, idempotencyKeyTTL ...time.Duration) *MySQLStoreFactory + func (f *MySQLStoreFactory) Close() error + func (f *MySQLStoreFactory) CreateTenantDatabase(ctx context.Context, tenantID string) (*sql.DB, error) + func (f *MySQLStoreFactory) Dialect() Dialect + func (f *MySQLStoreFactory) DriverName() string + func (f *MySQLStoreFactory) DropTenantDatabase(tenantID string) error + func (f *MySQLStoreFactory) OpenStore(ctx context.Context, tenantID string, taskQueues ...string) (WorkflowStore, io.Closer, error) + func (f *MySQLStoreFactory) TenantDB(ctx context.Context, tenantID string) (*sql.DB, error) + func (f *MySQLStoreFactory) WithLogger(l *slog.Logger) *MySQLStoreFactory + func (f *MySQLStoreFactory) WithTenantPoolMaxConns(n int) *MySQLStoreFactory + type PayloadEncryption struct + func NewPayloadEncryption(keyBase64 string) (*PayloadEncryption, error) + func (pe *PayloadEncryption) Decrypt(data []byte) ([]byte, error) + func (pe *PayloadEncryption) DecryptBase64(encoded string) ([]byte, error) + func (pe *PayloadEncryption) DecryptJSON(jsonValue []byte) ([]byte, error) + func (pe *PayloadEncryption) DecryptString(encoded string) (string, error) + func (pe *PayloadEncryption) Encrypt(plaintext []byte) ([]byte, error) + func (pe *PayloadEncryption) EncryptJSON(jsonBytes []byte) ([]byte, error) + func (pe *PayloadEncryption) EncryptString(plaintext string) (string, error) + type PluginCallEvent struct + Err string + FuncName string + Idempotent bool + Input string + Output string + PluginName string + func (e PluginCallEvent) Step() int + func (e PluginCallEvent) Type() EventType + type PluginCallGuard struct + func NewPluginCallGuard() *PluginCallGuard + func (g *PluginCallGuard) Allow(callerName string, targets []string) + func (g *PluginCallGuard) Check(callerName, targetName string) error + type PluginCallObserver func(pluginName, functionName string, d time.Duration, err error) + type PluginCallStreamChunkEvent struct + ChunkIndex int + Finish bool + FuncName string + Input string + Output string + PluginName string + func (e PluginCallStreamChunkEvent) Step() int + func (e PluginCallStreamChunkEvent) Type() EventType + type PluginConstraint struct + Constraint string + Name string + type PluginDef struct + Config json.RawMessage + CreatedAt time.Time + Deprecated bool + Name string + Version string + WASMBytes []byte + type PluginLoader struct + func NewPluginLoader(db *sql.DB, rt *Runtime, maxSize ...int) *PluginLoader + func (l *PluginLoader) DeployPlugin(ctx context.Context, name string, version string, wasmBytes []byte, ...) error + func (l *PluginLoader) DeployPluginWithCapabilities(ctx context.Context, name string, version string, wasmBytes []byte, ...) error + func (l *PluginLoader) DeprecatePlugin(ctx context.Context, name string, version string) error + func (l *PluginLoader) ListPluginVersions(ctx context.Context, name string) ([]PluginDef, error) + func (l *PluginLoader) LoadPlugin(ctx context.Context, name string, version string) (wazero.CompiledModule, error) + func (l *PluginLoader) ResolvePlugin(ctx context.Context, name string, constraint string) (string, *PluginDef, error) + func (l *PluginLoader) SetLimits(limits plugin.CapabilityLimits) + type PluginRegistry struct + func NewPluginRegistry() *PluginRegistry + func (pr *PluginRegistry) Has(pluginName, funcName string) bool + func (pr *PluginRegistry) IsPluginHealthy(pluginName string) bool + func (pr *PluginRegistry) Lookup(pluginName, funcName string) (plugin.PluginFunc, bool, bool) + func (pr *PluginRegistry) MarkPluginUnhealthy(pluginName string, err error) + func (pr *PluginRegistry) PluginHealthStatus() []plugin.HealthStatus + func (pr *PluginRegistry) Register(pluginName, funcName string, fn plugin.PluginFunc) error + func (pr *PluginRegistry) RegisterIdempotent(pluginName, funcName string, fn plugin.PluginFunc) error + func (pr *PluginRegistry) SetHealthTracker(t *plugin.PluginHealthTracker) + func (pr *PluginRegistry) UnhealthyError(pluginName string) error + type PluginStreamRegistry struct + func NewPluginStreamRegistry() *PluginStreamRegistry + func (psr *PluginStreamRegistry) Has(pluginName, funcName string) bool + func (psr *PluginStreamRegistry) IsPluginHealthy(pluginName string) bool + func (psr *PluginStreamRegistry) Lookup(pluginName, funcName string) (plugin.PluginStreamFunc, bool) + func (psr *PluginStreamRegistry) MarkPluginUnhealthy(pluginName string, err error) + func (psr *PluginStreamRegistry) PluginHealthStatus() []plugin.HealthStatus + func (psr *PluginStreamRegistry) Register(pluginName, funcName string, fn plugin.PluginStreamFunc) error + func (psr *PluginStreamRegistry) RegisterStream(pluginName string, opts plugin.FuncOptions, fn plugin.PluginStreamFunc) error + func (psr *PluginStreamRegistry) SetHealthTracker(t *plugin.PluginHealthTracker) + func (psr *PluginStreamRegistry) UnhealthyError(pluginName string) error + type PostgresStore struct + Metrics *prometheus.Metrics + func NewPostgresStore(db *sql.DB, taskQueues ...string) *PostgresStore + func (s *PostgresStore) AcquireConcurrencyKey(ctx context.Context, key, workflowID string, ttl time.Duration) (bool, error) + func (s *PostgresStore) AdminForceComplete(ctx context.Context, workflowID string, generation int64, result string, ...) error + func (s *PostgresStore) AdminForceFail(ctx context.Context, workflowID string, generation int64, ...) error + func (s *PostgresStore) AdminReReplay(ctx context.Context, workflowID string, generation int64, operator string) error + func (s *PostgresStore) AppendEventHistory(ctx context.Context, workflowID string, rec EventRecord) error + func (s *PostgresStore) AppendEventHistoryBatch(ctx context.Context, workflowID string, recs []EventRecord) error + func (s *PostgresStore) BatchHeartbeat(ctx context.Context, workerID string) (int64, error) + func (s *PostgresStore) CheckCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *PostgresStore) CheckCrossTenantCapability(ctx context.Context) CrossTenantCapability + func (s *PostgresStore) ClaimDueSchedule(ctx context.Context, name string, expectedNextRun, newNextRun time.Time, ...) (bool, error) + func (s *PostgresStore) ClaimStickyWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *PostgresStore) ClaimWorkflow(ctx context.Context, workerID string) (*WorkflowInstance, error) + func (s *PostgresStore) ClaimWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *PostgresStore) ClaimWorkflowsAcrossTenants(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *PostgresStore) CleanupMemorySamples(ctx context.Context, maxSamplesPerDef int) (int64, error) + func (s *PostgresStore) ClearStickyWorker(ctx context.Context, workflowID string) error + func (s *PostgresStore) CompactHistory(ctx context.Context, workflowID string, compactionState []byte, ...) error + func (s *PostgresStore) CompleteCallIntent(ctx context.Context, workflowID string, rec EventRecord, payload []byte, ...) error + func (s *PostgresStore) CompleteUpdateRequest(ctx context.Context, workflowID, updateName, result, errMsg string) error + func (s *PostgresStore) CompleteWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *PostgresStore) ContinueAsNew(ctx context.Context, currentRunID, workerID string, generation int64, ...) (string, error) + func (s *PostgresStore) CountActiveInstances(ctx context.Context, name string, version int) (int, error) + func (s *PostgresStore) CountEventHistory(ctx context.Context, workflowID string) (int, error) + func (s *PostgresStore) CountEventHistoryTotal(ctx context.Context) (int, error) + func (s *PostgresStore) CountStalledWorkflows(ctx context.Context, threshold time.Duration) (int, error) + func (s *PostgresStore) CreatePromise(ctx context.Context, workflowID, promiseName, promiseID string) error + func (s *PostgresStore) CreateSchedule(ctx context.Context, sch Schedule) error + func (s *PostgresStore) CreateUpdateRequest(ctx context.Context, workflowID, updateName, payload, promiseID string) error + func (s *PostgresStore) DeleteCompletedWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *PostgresStore) DeleteDeadLetteredWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *PostgresStore) DeleteExpiredEvents(ctx context.Context, olderThan time.Time) (int64, error) + func (s *PostgresStore) DeleteSchedule(ctx context.Context, name string) error + func (s *PostgresStore) DeliverSignal(ctx context.Context, workflowID, signalName, payload string) error + func (s *PostgresStore) DeployWorkflowDef(ctx context.Context, def *WorkflowDef) error + func (s *PostgresStore) EstimateEventHistorySize(ctx context.Context) (int64, error) + func (s *PostgresStore) FailWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *PostgresStore) FinalizeWorkflowSegment(ctx context.Context, runID, workerID string, generation int64, ...) error + func (s *PostgresStore) GetActiveInstanceCountsByVersion(ctx context.Context) (map[string]int, error) + func (s *PostgresStore) GetAllowedSignalCallers(ctx context.Context, workflowID string) ([]string, error) + func (s *PostgresStore) GetChildCount(ctx context.Context, parentWorkflowID string) (int, error) + func (s *PostgresStore) GetChildResult(ctx context.Context, runID string) (string, bool, error) + func (s *PostgresStore) GetChildResultInSchema(ctx context.Context, targetSchema, runID string) (string, bool, error) + func (s *PostgresStore) GetCompactionCandidates(ctx context.Context, threshold int, limit int) ([]string, error) + func (s *PostgresStore) GetConcurrencyKeyCount(ctx context.Context, workflowID string) (int, error) + func (s *PostgresStore) GetDueSchedules(ctx context.Context) ([]Schedule, error) + func (s *PostgresStore) GetDueSchedulesAcrossTenants(ctx context.Context) ([]Schedule, error) + func (s *PostgresStore) GetEventCount(ctx context.Context, workflowID string) (int, error) + func (s *PostgresStore) GetPendingUpdateRequests(ctx context.Context, workflowID string) ([]UpdateRequestInfo, error) + func (s *PostgresStore) GetPromise(ctx context.Context, workflowID, promiseID string) (status string, result string, errMsg string, err error) + func (s *PostgresStore) GetQueryState(ctx context.Context, workflowID, key string) (string, error) + func (s *PostgresStore) GetRoutingRules(ctx context.Context, workflowName string) ([]RoutingRule, error) + func (s *PostgresStore) GetWASMLength(ctx context.Context, defName string, defVersion int) (int64, error) + func (s *PostgresStore) GetWorkflowByID(ctx context.Context, id string) (*WorkflowInstance, error) + func (s *PostgresStore) GetWorkflowDef(ctx context.Context, name string, version int) (*WorkflowDef, error) + func (s *PostgresStore) GetWorkflowTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *PostgresStore) GetWorkflowTags(ctx context.Context, workflowName string) (map[string]int, error) + func (s *PostgresStore) Heartbeat(ctx context.Context, workflowID, workerID string, generation int64) (bool, error) + func (s *PostgresStore) ListPromises(ctx context.Context, workflowID string) ([]PromiseInfo, error) + func (s *PostgresStore) ListSchedules(ctx context.Context) ([]Schedule, error) + func (s *PostgresStore) ListVersions(ctx context.Context, defName string) ([]int, error) + func (s *PostgresStore) ListWorkflowDefs(ctx context.Context, name string) ([]WorkflowDef, error) + func (s *PostgresStore) ListWorkflows(ctx context.Context, filter WorkflowFilter) ([]WorkflowInstance, error) + func (s *PostgresStore) LoadCompactionState(ctx context.Context, workflowID string) (*CompactionState, error) + func (s *PostgresStore) LoadDAGSpec(ctx context.Context, defName string, defVersion int) (json.RawMessage, error) + func (s *PostgresStore) LoadEventHistory(ctx context.Context, workflowID string) ([]EventRecord, error) + func (s *PostgresStore) LoadEventHistoryPaginated(ctx context.Context, workflowID string, offset, limit int) ([]EventRecord, error) + func (s *PostgresStore) LoadMemoryEstimates(ctx context.Context) (map[string]float64, error) + func (s *PostgresStore) LoadMemoryStats(ctx context.Context) ([]WorkflowMemoryStats, error) + func (s *PostgresStore) LoadWASM(ctx context.Context, defName string, defVersion int) ([]byte, error) + func (s *PostgresStore) LoadWorkflowConfig(ctx context.Context, defName string, defVersion int) (int, error) + func (s *PostgresStore) MarkVersionDeprecated(ctx context.Context, name string, version int, deprecated bool) error + func (s *PostgresStore) MoveToDeadLetterQueue(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *PostgresStore) PickVersionByRouting(ctx context.Context, workflowName string) (int, error) + func (s *PostgresStore) PollAndClaimSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *PostgresStore) PollCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *PostgresStore) PollSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *PostgresStore) PurgeWorkflowDef(ctx context.Context, name string, version int) error + func (s *PostgresStore) QueueDepth(ctx context.Context) (int64, error) + func (s *PostgresStore) ReapExpiredConcurrencyKeys(ctx context.Context) (int64, error) + func (s *PostgresStore) ReapStaleInstances(ctx context.Context, timeout time.Duration) (int, error) + func (s *PostgresStore) RecordWorkflowMemorySample(ctx context.Context, defName string, sampleBytes int64) error + func (s *PostgresStore) RejectPromise(ctx context.Context, workflowID, promiseID, errMsg string) error + func (s *PostgresStore) ReleaseConcurrencyKey(ctx context.Context, key string) error + func (s *PostgresStore) ReleaseWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *PostgresStore) ReleaseWorkflowConcurrencyKeys(ctx context.Context, workflowID string) error + func (s *PostgresStore) RemoveRoutingRule(ctx context.Context, ruleID string) error + func (s *PostgresStore) RemoveWorkflowTag(ctx context.Context, workflowName string, tag string) error + func (s *PostgresStore) RequestCancellation(ctx context.Context, workflowID, reason string) error + func (s *PostgresStore) ResolveCallIntent(ctx context.Context, workflowID string, rec EventRecord, payload []byte, ...) error + func (s *PostgresStore) ResolveLatestVersion(ctx context.Context, defName string) (int, error) + func (s *PostgresStore) ResolvePromise(ctx context.Context, workflowID, promiseID, result string) error + func (s *PostgresStore) ResolveTenantFromAPIKey(ctx context.Context, keyHash []byte) (uuid.UUID, error) + func (s *PostgresStore) ResolveVersionByTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *PostgresStore) RetryWorkflow(ctx context.Context, workflowID string) error + func (s *PostgresStore) SetRoutingRule(ctx context.Context, workflowName string, targetVersion int, weight float64) error + func (s *PostgresStore) SetScheduleEnabled(ctx context.Context, name string, enabled bool) error + func (s *PostgresStore) SetSyncCommitOff(v bool) + func (s *PostgresStore) SetWorkflowTag(ctx context.Context, workflowName string, version int, tag string) error + func (s *PostgresStore) StartChildWorkflow(ctx context.Context, parentID, defName, inputJSON string, defVersion int, ...) (string, error) + func (s *PostgresStore) StartChildWorkflowAtomic(ctx context.Context, childID, parentID, defName, inputJSON string, ...) (string, error) + func (s *PostgresStore) StartChildWorkflowInSchema(ctx context.Context, targetSchema, parentID, defName, inputJSON string, ...) (string, error) + func (s *PostgresStore) StartNewRun(ctx context.Context, runID, defName string, defVersion int, ...) (string, bool, error) + func (s *PostgresStore) StreamEventHistory(ctx context.Context, workflowID string, pageSize int) (<-chan EventRecord, <-chan error) + func (s *PostgresStore) TerminateWorkflow(ctx context.Context, workflowID, reason string) error + func (s *PostgresStore) TraceWorkflow(ctx context.Context, workflowID, traceID string) error + func (s *PostgresStore) UpdateScheduleNextRun(ctx context.Context, name string, nextRun time.Time) error + func (s *PostgresStore) UpdateStickyWorker(ctx context.Context, workflowID, workerID string) error + func (s *PostgresStore) ValidateVersion(ctx context.Context, defName string, defVersion int) (bool, error) + func (s *PostgresStore) VerifyWorkflowEvents(ctx context.Context, workflowID string) error + func (s *PostgresStore) WithEncryption(enc *PayloadEncryption, enabled bool) *PostgresStore + func (s *PostgresStore) WithIdempotencyKeyTTL(ttl time.Duration) *PostgresStore + func (s *PostgresStore) WithLogger(l *slog.Logger) *PostgresStore + func (s *PostgresStore) WithNotifyChannel(channel string) *PostgresStore + func (s *PostgresStore) WithReadRedactionDisabled(disabled bool) *PostgresStore + func (s *PostgresStore) WithTenant(tenantID string) *PostgresStore + func (s *PostgresStore) WriteCallIntent(ctx context.Context, workflowID string, rec EventRecord, workerID string, ...) error + type PostgresStoreFactory struct + func NewPostgresStoreFactory(db *sql.DB, schemaName string, idempotencyKeyTTL ...time.Duration) *PostgresStoreFactory + func (f *PostgresStoreFactory) Dialect() Dialect + func (f *PostgresStoreFactory) DriverName() string + func (f *PostgresStoreFactory) OpenStore(ctx context.Context, tenantID string, taskQueues ...string) (WorkflowStore, io.Closer, error) + func (f *PostgresStoreFactory) WithEncryption(enc *PayloadEncryption, enabled bool) *PostgresStoreFactory + func (f *PostgresStoreFactory) WithLogger(l *slog.Logger) *PostgresStoreFactory + func (f *PostgresStoreFactory) WithMetrics(m *prometheus.Metrics) *PostgresStoreFactory + func (f *PostgresStoreFactory) WithNotifyChannel(channel string) *PostgresStoreFactory + func (f *PostgresStoreFactory) WithSyncCommitOff(v bool) *PostgresStoreFactory + type PromiseInfo struct + CreatedAt time.Time + ErrorMsg string + PromiseID string + PromiseName string + ResolvedAt *time.Time + Result string + Status string + type PromiseRejectedEvent struct + Err string + PromiseID string + func (e PromiseRejectedEvent) Step() int + func (e PromiseRejectedEvent) Type() EventType + type PromiseResolvedEvent struct + PromiseID string + Result string + func (e PromiseResolvedEvent) Step() int + func (e PromiseResolvedEvent) Type() EventType + type PromiseStore interface + CreatePromise func(ctx context.Context, workflowID, promiseName, promiseID string) error + GetPromise func(ctx context.Context, workflowID, promiseID string) (status string, result string, errMsg string, err error) + RejectPromise func(ctx context.Context, workflowID, promiseID, errMsg string) error + ResolvePromise func(ctx context.Context, workflowID, promiseID, result string) error + type QueryBuilder struct + func NewQueryBuilder(d Dialect, baseSQL string) *QueryBuilder + func (qb *QueryBuilder) AddArgs(args ...any) + func (qb *QueryBuilder) AddCondition(condFmt string, arg any) + func (qb *QueryBuilder) AddLikeCondition(column string, pattern string, caseInsensitive bool) + func (qb *QueryBuilder) AddRaw(sql string) + func (qb *QueryBuilder) NextPos() int + func (qb *QueryBuilder) SQL() (string, []any) + type RLSBypassReason struct + Detail string + Kind string + func CheckRLSEnforced(ctx context.Context, db *sql.DB) ([]RLSBypassReason, error) + type ReadOnlyDB struct + Inner *sql.DB + func (r *ReadOnlyDB) Begin(ctx context.Context) (plugin.PluginTx, error) + func (r *ReadOnlyDB) Exec(ctx context.Context, query string, args ...any) (int64, error) + func (r *ReadOnlyDB) Ping(ctx context.Context) error + func (r *ReadOnlyDB) Query(ctx context.Context, query string, args ...any) (plugin.Rows, error) + func (r *ReadOnlyDB) QueryRow(ctx context.Context, query string, args ...any) plugin.RowScanner + type ReplayStepAction int + const ReplayNext + const ReplayQuit + type ReplayStepCallback func(step int, event *EventRecord, queryState map[string]string) ReplayStepAction + type RetryableError interface + Retryable func() bool + type RoutingRule struct + ID string + TargetVersion int + Weight float64 + WorkflowName string + type RunDetachedEvent struct + func (e RunDetachedEvent) Step() int + func (e RunDetachedEvent) Type() EventType + type Runtime struct + MemoryLimitPages uint32 + Metrics *prometheus.Metrics + func NewRuntime(ctx context.Context, memoryLimitPages uint32, instructionLimit uint64) (*Runtime, error) + func (r *Runtime) CallExport(ctx context.Context, mod api.Module, exportName string, inputJSON []byte) (string, error) + func (r *Runtime) CallExportWithSuspend(ctx context.Context, mod api.Module, exportName string, inputJSON []byte) (result string, suspended bool, err error) + func (r *Runtime) Close(ctx context.Context) error + func (r *Runtime) CompileModule(ctx context.Context, wasmBytes []byte) (wazero.CompiledModule, error) + func (r *Runtime) InitModule(ctx context.Context, mod api.Module) error + func (r *Runtime) InstantiateAndInit(ctx context.Context, wasmBytes []byte) (api.Module, error) + func (r *Runtime) InstantiateModule(ctx context.Context, compiled wazero.CompiledModule) (api.Module, error) + func (r *Runtime) InstantiateModuleNamed(ctx context.Context, compiled wazero.CompiledModule, name string) (api.Module, error) + func (r *Runtime) Stderr() string + func (r *Runtime) Stdout() string + type SQLDBAdapter struct + DB *sql.DB + func (a *SQLDBAdapter) Begin(ctx context.Context) (plugin.PluginTx, error) + func (a *SQLDBAdapter) Exec(ctx context.Context, query string, args ...any) (int64, error) + func (a *SQLDBAdapter) Ping(ctx context.Context) error + func (a *SQLDBAdapter) Query(ctx context.Context, query string, args ...any) (plugin.Rows, error) + func (a *SQLDBAdapter) QueryRow(ctx context.Context, query string, args ...any) plugin.RowScanner + type Schedule struct + CatchUpLimit int + CronExpression string + DefName string + Enabled bool + EntryPoint string + Input json.RawMessage + LastRunAt *time.Time + LastRunID string + MisfirePolicy string + Name string + NextRunAt time.Time + OverlapPolicy string + TenantID string + Timezone string + type ServiceCaller interface + Call func(ctx context.Context, service, operation, requestJSON string) (responseJSON string, err error) + type Shard struct + Close func() error + Config ShardConfig + Store WorkflowStore + type ShardConfig struct + ConnStr string + Name string + Schema string + Tenants []string + type ShardedStore struct + func NewShardedStore(configs []ShardConfig, stores []WorkflowStore, closers []func() error) (*ShardedStore, error) + func (s *ShardedStore) AcquireConcurrencyKey(ctx context.Context, key, workflowID string, ttl time.Duration) (bool, error) + func (s *ShardedStore) AdminForceComplete(ctx context.Context, workflowID string, generation int64, result string, ...) error + func (s *ShardedStore) AdminForceFail(ctx context.Context, workflowID string, generation int64, ...) error + func (s *ShardedStore) AdminReReplay(ctx context.Context, workflowID string, generation int64, operator string) error + func (s *ShardedStore) AppendEventHistory(ctx context.Context, workflowID string, rec EventRecord) error + func (s *ShardedStore) AppendEventHistoryBatch(ctx context.Context, workflowID string, recs []EventRecord) error + func (s *ShardedStore) BatchHeartbeat(ctx context.Context, workerID string) (int64, error) + func (s *ShardedStore) CheckCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *ShardedStore) ClaimDueSchedule(ctx context.Context, name string, expectedNextRun, newNextRun time.Time, ...) (bool, error) + func (s *ShardedStore) ClaimStickyWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *ShardedStore) ClaimWorkflow(ctx context.Context, workerID string) (*WorkflowInstance, error) + func (s *ShardedStore) ClaimWorkflows(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + func (s *ShardedStore) CleanupMemorySamples(ctx context.Context, maxSamplesPerDef int) (int64, error) + func (s *ShardedStore) ClearStickyWorker(ctx context.Context, workflowID string) error + func (s *ShardedStore) Close() + func (s *ShardedStore) CompactHistory(ctx context.Context, workflowID string, compactionState []byte, ...) error + func (s *ShardedStore) CompleteUpdateRequest(ctx context.Context, workflowID, updateName, result, errMsg string) error + func (s *ShardedStore) CompleteWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *ShardedStore) ContinueAsNew(ctx context.Context, currentRunID, workerID string, generation int64, ...) (string, error) + func (s *ShardedStore) CountActiveConcurrencyKeys(ctx context.Context) (int, error) + func (s *ShardedStore) CountActiveInstances(ctx context.Context, name string, version int) (int, error) + func (s *ShardedStore) CountEventHistory(ctx context.Context, workflowID string) (int, error) + func (s *ShardedStore) CountEventHistoryTotal(ctx context.Context) (int, error) + func (s *ShardedStore) CountStalledWorkflows(ctx context.Context, threshold time.Duration) (int, error) + func (s *ShardedStore) CreatePromise(ctx context.Context, workflowID, promiseName, promiseID string) error + func (s *ShardedStore) CreateSchedule(ctx context.Context, sch Schedule) error + func (s *ShardedStore) CreateUpdateRequest(ctx context.Context, workflowID, updateName, payload, promiseID string) error + func (s *ShardedStore) DeleteCompletedWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *ShardedStore) DeleteDeadLetteredWorkflows(ctx context.Context, olderThan time.Time) (int64, error) + func (s *ShardedStore) DeleteExpiredEvents(ctx context.Context, olderThan time.Time) (int64, error) + func (s *ShardedStore) DeleteSchedule(ctx context.Context, name string) error + func (s *ShardedStore) DeliverSignal(ctx context.Context, workflowID, signalName, payload string) error + func (s *ShardedStore) DeployWorkflowDef(ctx context.Context, def *WorkflowDef) error + func (s *ShardedStore) EstimateEventHistorySize(ctx context.Context) (int64, error) + func (s *ShardedStore) FailWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *ShardedStore) FinalizeWorkflowSegment(ctx context.Context, runID, workerID string, generation int64, ...) error + func (s *ShardedStore) GetActiveInstanceCountsByVersion(ctx context.Context) (map[string]int, error) + func (s *ShardedStore) GetAllowedSignalCallers(ctx context.Context, workflowID string) ([]string, error) + func (s *ShardedStore) GetChildCount(ctx context.Context, parentWorkflowID string) (int, error) + func (s *ShardedStore) GetChildResult(ctx context.Context, runID string) (string, bool, error) + func (s *ShardedStore) GetCompactionCandidates(ctx context.Context, threshold int, limit int) ([]string, error) + func (s *ShardedStore) GetConcurrencyKeyCount(ctx context.Context, workflowID string) (int, error) + func (s *ShardedStore) GetDueSchedules(ctx context.Context) ([]Schedule, error) + func (s *ShardedStore) GetEventCount(ctx context.Context, workflowID string) (int, error) + func (s *ShardedStore) GetPendingUpdateRequests(ctx context.Context, workflowID string) ([]UpdateRequestInfo, error) + func (s *ShardedStore) GetPromise(ctx context.Context, workflowID, promiseID string) (string, string, string, error) + func (s *ShardedStore) GetQueryState(ctx context.Context, workflowID, key string) (string, error) + func (s *ShardedStore) GetRoutingRules(ctx context.Context, workflowName string) ([]RoutingRule, error) + func (s *ShardedStore) GetWASMLength(ctx context.Context, defName string, defVersion int) (int64, error) + func (s *ShardedStore) GetWorkflowByID(ctx context.Context, id string) (*WorkflowInstance, error) + func (s *ShardedStore) GetWorkflowDef(ctx context.Context, name string, version int) (*WorkflowDef, error) + func (s *ShardedStore) GetWorkflowTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *ShardedStore) GetWorkflowTags(ctx context.Context, workflowName string) (map[string]int, error) + func (s *ShardedStore) Heartbeat(ctx context.Context, workflowID, workerID string, generation int64) (bool, error) + func (s *ShardedStore) ListPromises(ctx context.Context, workflowID string) ([]PromiseInfo, error) + func (s *ShardedStore) ListSchedules(ctx context.Context) ([]Schedule, error) + func (s *ShardedStore) ListVersions(ctx context.Context, defName string) ([]int, error) + func (s *ShardedStore) ListWorkflowDefs(ctx context.Context, name string) ([]WorkflowDef, error) + func (s *ShardedStore) ListWorkflows(ctx context.Context, filter WorkflowFilter) ([]WorkflowInstance, error) + func (s *ShardedStore) LoadCompactionState(ctx context.Context, workflowID string) (*CompactionState, error) + func (s *ShardedStore) LoadDAGSpec(ctx context.Context, defName string, defVersion int) (json.RawMessage, error) + func (s *ShardedStore) LoadEventHistory(ctx context.Context, workflowID string) ([]EventRecord, error) + func (s *ShardedStore) LoadEventHistoryBatch(ctx context.Context, workflowIDs []string) (map[string][]EventRecord, error) + func (s *ShardedStore) LoadEventHistoryPaginated(ctx context.Context, workflowID string, offset, limit int) ([]EventRecord, error) + func (s *ShardedStore) LoadMemoryEstimates(ctx context.Context) (map[string]float64, error) + func (s *ShardedStore) LoadMemoryStats(ctx context.Context) ([]WorkflowMemoryStats, error) + func (s *ShardedStore) LoadWASM(ctx context.Context, defName string, defVersion int) ([]byte, error) + func (s *ShardedStore) LoadWorkflowConfig(ctx context.Context, defName string, defVersion int) (int, error) + func (s *ShardedStore) MarkVersionDeprecated(ctx context.Context, name string, version int, deprecated bool) error + func (s *ShardedStore) MoveToDeadLetterQueue(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *ShardedStore) PickVersionByRouting(ctx context.Context, workflowName string) (int, error) + func (s *ShardedStore) PollAndClaimSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *ShardedStore) PollCancellation(ctx context.Context, workflowID string) (bool, string, error) + func (s *ShardedStore) PollSignal(ctx context.Context, workflowID, signalName string) (string, bool, error) + func (s *ShardedStore) PurgeWorkflowDef(ctx context.Context, name string, version int) error + func (s *ShardedStore) QueueDepth(ctx context.Context) (int64, error) + func (s *ShardedStore) ReapExpiredConcurrencyKeys(ctx context.Context) (int64, error) + func (s *ShardedStore) ReapStaleInstances(ctx context.Context, timeout time.Duration) (int, error) + func (s *ShardedStore) RecordWorkflowMemorySample(ctx context.Context, defName string, sampleBytes int64) error + func (s *ShardedStore) RejectPromise(ctx context.Context, workflowID, promiseID, errMsg string) error + func (s *ShardedStore) ReleaseConcurrencyKey(ctx context.Context, key string) error + func (s *ShardedStore) ReleaseWorkflow(ctx context.Context, workflowID, workerID string, generation int64, ...) error + func (s *ShardedStore) ReleaseWorkflowConcurrencyKeys(ctx context.Context, workflowID string) error + func (s *ShardedStore) RemoveRoutingRule(ctx context.Context, ruleID string) error + func (s *ShardedStore) RemoveWorkflowTag(ctx context.Context, workflowName string, tag string) error + func (s *ShardedStore) RequestCancellation(ctx context.Context, workflowID, reason string) error + func (s *ShardedStore) ResolveLatestVersion(ctx context.Context, defName string) (int, error) + func (s *ShardedStore) ResolvePromise(ctx context.Context, workflowID, promiseID, result string) error + func (s *ShardedStore) ResolveTenantFromAPIKey(ctx context.Context, keyHash []byte) (uuid.UUID, error) + func (s *ShardedStore) ResolveVersionByTag(ctx context.Context, workflowName string, tag string) (int, error) + func (s *ShardedStore) RetryWorkflow(ctx context.Context, workflowID string) error + func (s *ShardedStore) SetRoutingRule(ctx context.Context, workflowName string, targetVersion int, weight float64) error + func (s *ShardedStore) SetScheduleEnabled(ctx context.Context, name string, enabled bool) error + func (s *ShardedStore) SetWorkflowTag(ctx context.Context, workflowName string, version int, tag string) error + func (s *ShardedStore) Shards() []*Shard + func (s *ShardedStore) StartChildWorkflow(ctx context.Context, parentID, defName, inputJSON string, defVersion int, ...) (string, error) + func (s *ShardedStore) StartChildWorkflowAtomic(ctx context.Context, childID, parentID, defName, inputJSON string, ...) (string, error) + func (s *ShardedStore) StartNewRun(ctx context.Context, runID, defName string, defVersion int, ...) (string, bool, error) + func (s *ShardedStore) StreamEventHistory(ctx context.Context, workflowID string, pageSize int) (<-chan EventRecord, <-chan error) + func (s *ShardedStore) TerminateWorkflow(ctx context.Context, workflowID, reason string) error + func (s *ShardedStore) TraceWorkflow(ctx context.Context, workflowID, traceID string) error + func (s *ShardedStore) UpdateScheduleNextRun(ctx context.Context, name string, nextRun time.Time) error + func (s *ShardedStore) UpdateStickyWorker(ctx context.Context, workflowID, workerID string) error + func (s *ShardedStore) ValidateVersion(ctx context.Context, defName string, defVersion int) (bool, error) + func (s *ShardedStore) VerifyWorkflowEvents(ctx context.Context, workflowID string) error + type SignalReceivedEvent struct + SignalName string + SignalPayload string + func (e SignalReceivedEvent) Step() int + func (e SignalReceivedEvent) Type() EventType + type SignalStore interface + DeliverSignal func(ctx context.Context, workflowID, signalName, payload string) error + PollCancellation func(ctx context.Context, workflowID string) (cancelled bool, reason string, err error) + PollSignal func(ctx context.Context, workflowID, signalName string) (payload string, found bool, err error) + type SliceEventStream struct + func NewSliceEventStream(events []EventRecord) *SliceEventStream + func (s *SliceEventStream) Append(rec EventRecord) + func (s *SliceEventStream) At(i int) *EventRecord + func (s *SliceEventStream) Close() error + func (s *SliceEventStream) Len() int + func (s *SliceEventStream) Slice(start, end int) []EventRecord + func (s *SliceEventStream) Total() (int, error) + type StaleVersionAlert struct + ActiveInstances int + DaysSinceCreated int + Deprecated bool + Message string + Name string + Version int + func CheckStaleVersions(ctx context.Context, store WorkflowStore, ...) ([]StaleVersionAlert, error) + type StateMutationEvent struct + Delta int64 + Key string + Op string + Value string + func (e StateMutationEvent) Step() int + func (e StateMutationEvent) Type() EventType + type StoreFactory interface + Dialect func() Dialect + DriverName func() string + OpenStore func(ctx context.Context, tenantID string, taskQueues ...string) (WorkflowStore, io.Closer, error) + type SuspendError struct + NewInput string + NewVersion int + Reason string + Until time.Time + func (e *SuspendError) Error() string + type SuspendResult struct + ContinueAsNewHandled bool + Deferrals map[string]string + History []EventRecord + NewInput string + NewRunID string + NewVersion int + Reason string + SuspendUntil time.Time + type TenantFlusherRegistry struct + func NewTenantFlusherRegistry(db *sql.DB, config FlusherConfig) *TenantFlusherRegistry + func (r *TenantFlusherRegistry) For(tenantID string) *AdaptiveFlusher + func (r *TenantFlusherRegistry) Remove(tenantID string) + func (r *TenantFlusherRegistry) SetEncryption(encrypt bool, enc *PayloadEncryption) + func (r *TenantFlusherRegistry) Shutdown() + type TruncationSummary struct + TruncatedCount int + type UpdateHandlerEvent struct + HandlerName string + func (e UpdateHandlerEvent) Step() int + func (e UpdateHandlerEvent) Type() EventType + type UpdateRequestInfo struct + CreatedAt time.Time + ErrorMsg string + Payload string + PromiseID string + Result string + Status string + UpdateName string + WorkflowID string + type VaultCredentialProvider struct + func NewVaultCredentialProvider(credentialPath string) *VaultCredentialProvider + func (p *VaultCredentialProvider) GetConnectionString(ctx context.Context) (string, error) + type VersionMetrics struct + ABIVersion int + ActiveInstances int + Age string + CreatedAt time.Time + Deprecated bool + MinVersion int + Name string + Version int + type VersionMetricsSummary struct + ActiveVersions int + Deprecated int + TotalActiveInstances int + TotalVersions int + Workflows []VersionMetrics + func CollectVersionMetrics(ctx context.Context, store WorkflowStore) (*VersionMetricsSummary, error) + type VersionStoreResolver func(w http.ResponseWriter, r *http.Request) (store WorkflowStore, ok bool) + func StaticVersionStore(store WorkflowStore) VersionStoreResolver + type WASMCache struct + func NewWASMCache(maxEntries int, maxBytes int64) *WASMCache + func (c *WASMCache) Get(key string) ([]byte, bool) + func (c *WASMCache) Len() int + func (c *WASMCache) Put(key string, data []byte) + func (c *WASMCache) TotalBytes() int64 + type WasmBackend interface + Close func(ctx context.Context) error + Execute func(ctx context.Context, wasmBytes []byte, entryPoint string, ...) (*ExecResult, error) + Name func() string + PerExecution func() WasmBackend + type WasmDiskCache struct + func NewWasmDiskCache(cacheDir string, maxLen int) *WasmDiskCache + func (c *WasmDiskCache) LookupByKey(key string) []byte + func (c *WasmDiskCache) LookupBytes(wasmBytes []byte) []byte + func (c *WasmDiskCache) LookupDef(name string, version int) []byte + func (c *WasmDiskCache) StoreDef(name string, version int, wasmBytes []byte) + type WasmtimeOption func(*wasmtimeLimits) + func WithWasmtimeExecutionTimeout(d time.Duration) WasmtimeOption + func WithWasmtimeInstructionLimit(n uint64) WasmtimeOption + func WithWasmtimeMemoryLimits(memoryBytes, tableElements, instances int64) WasmtimeOption + type WorkflowDef struct + ABIVersion int + CreatedAt time.Time + Deprecated bool + MinVersion int + Name string + PluginDeps map[string]string + Version int + WASMBytes []byte + type WorkflowFilter struct + ErrorContains string + InputContains string + Limit int + Offset int + Search string + Status string + type WorkflowInstance struct + AssignedTo string + CreatedAt time.Time + DefName string + DefVersion int + Error string + ErrorCode string + ErrorOp string + Generation int64 + ID string + Input json.RawMessage + MinVersion int + NextWakeAt time.Time + Priority int + Result string + Status string + TenantID string + TraceID string + type WorkflowLoader struct + func NewWorkflowLoader(db *sql.DB, rt *Runtime, diskCache *WasmDiskCache, maxSize ...int) *WorkflowLoader + func (l *WorkflowLoader) ActiveVersions(ctx context.Context) (map[string][]int, error) + func (l *WorkflowLoader) CacheStats() CacheStats + func (l *WorkflowLoader) Deploy(ctx context.Context, name string, version int, wasmBytes []byte, ...) error + func (l *WorkflowLoader) Deprecate(ctx context.Context, name string, version int) error + func (l *WorkflowLoader) ListVersions(ctx context.Context, name string) ([]WorkflowDef, error) + func (l *WorkflowLoader) Load(ctx context.Context, name string, version int) (wazero.CompiledModule, error) + func (l *WorkflowLoader) ResolveLatestVersion(ctx context.Context, name string) (int, error) + type WorkflowMemoryStats struct + AvgBytes float64 + DefName string + MaxBytes int64 + MinBytes int64 + P10 int64 + P25 int64 + P50 int64 + P75 int64 + P90 int64 + P99 int64 + SampleCount int + type WorkflowState interface + ChildVersion func(name string) (int, bool) + MinVersion func() int + Priority func() int + Version func() int + type WorkflowStore interface + AcquireConcurrencyKey func(ctx context.Context, key, workflowID string, ttl time.Duration) (acquired bool, err error) + AdminForceComplete func(ctx context.Context, workflowID string, generation int64, result string, ...) error + AdminForceFail func(ctx context.Context, workflowID string, generation int64, ...) error + AdminReReplay func(ctx context.Context, workflowID string, generation int64, operator string) error + AppendEventHistory func(ctx context.Context, workflowID string, rec EventRecord) error + AppendEventHistoryBatch func(ctx context.Context, workflowID string, recs []EventRecord) error + BatchHeartbeat func(ctx context.Context, workerID string) (int64, error) + CheckCancellation func(ctx context.Context, workflowID string) (cancelled bool, reason string, err error) + ClaimDueSchedule func(ctx context.Context, name string, expectedNextRun, newNextRun time.Time, ...) (claimed bool, err error) + ClaimStickyWorkflows func(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + ClaimWorkflow func(ctx context.Context, workerID string) (*WorkflowInstance, error) + ClaimWorkflows func(ctx context.Context, workerID string, limit int) ([]*WorkflowInstance, error) + CleanupMemorySamples func(ctx context.Context, maxSamplesPerDef int) (int64, error) + ClearStickyWorker func(ctx context.Context, workflowID string) error + CompactHistory func(ctx context.Context, workflowID string, compactionState []byte, ...) error + CompleteUpdateRequest func(ctx context.Context, workflowID, updateName, result, errMsg string) error + CompleteWorkflow func(ctx context.Context, workflowID, workerID string, generation int64, ...) error + ContinueAsNew func(ctx context.Context, currentRunID, workerID string, generation int64, ...) (newRunID string, err error) + CountActiveInstances func(ctx context.Context, name string, version int) (int, error) + CountEventHistory func(ctx context.Context, workflowID string) (int, error) + CreatePromise func(ctx context.Context, workflowID, promiseName, promiseID string) error + CreateSchedule func(ctx context.Context, s Schedule) error + CreateUpdateRequest func(ctx context.Context, workflowID, updateName, payload, promiseID string) error + DeleteCompletedWorkflows func(ctx context.Context, olderThan time.Time) (int64, error) + DeleteDeadLetteredWorkflows func(ctx context.Context, olderThan time.Time) (int64, error) + DeleteExpiredEvents func(ctx context.Context, olderThan time.Time) (int64, error) + DeleteSchedule func(ctx context.Context, name string) error + DeliverSignal func(ctx context.Context, workflowID, signalName, payload string) error + DeployWorkflowDef func(ctx context.Context, def *WorkflowDef) error + FailWorkflow func(ctx context.Context, workflowID, workerID string, generation int64, ...) error + FinalizeWorkflowSegment func(ctx context.Context, runID, workerID string, generation int64, ...) error + GetActiveInstanceCountsByVersion func(ctx context.Context) (map[string]int, error) + GetAllowedSignalCallers func(ctx context.Context, workflowID string) ([]string, error) + GetChildCount func(ctx context.Context, parentWorkflowID string) (int, error) + GetChildResult func(ctx context.Context, runID string) (resultJSON string, completed bool, err error) + GetCompactionCandidates func(ctx context.Context, threshold int, limit int) ([]string, error) + GetConcurrencyKeyCount func(ctx context.Context, workflowID string) (int, error) + GetDueSchedules func(ctx context.Context) ([]Schedule, error) + GetEventCount func(ctx context.Context, workflowID string) (int, error) + GetPendingUpdateRequests func(ctx context.Context, workflowID string) ([]UpdateRequestInfo, error) + GetPromise func(ctx context.Context, workflowID, promiseID string) (status string, result string, errMsg string, err error) + GetQueryState func(ctx context.Context, workflowID, key string) (string, error) + GetRoutingRules func(ctx context.Context, workflowName string) ([]RoutingRule, error) + GetWASMLength func(ctx context.Context, defName string, defVersion int) (int64, error) + GetWorkflowByID func(ctx context.Context, id string) (*WorkflowInstance, error) + GetWorkflowDef func(ctx context.Context, name string, version int) (*WorkflowDef, error) + GetWorkflowTag func(ctx context.Context, workflowName string, tag string) (int, error) + GetWorkflowTags func(ctx context.Context, workflowName string) (map[string]int, error) + Heartbeat func(ctx context.Context, workflowID, workerID string, generation int64) (bool, error) + ListPromises func(ctx context.Context, workflowID string) ([]PromiseInfo, error) + ListSchedules func(ctx context.Context) ([]Schedule, error) + ListVersions func(ctx context.Context, defName string) ([]int, error) + ListWorkflowDefs func(ctx context.Context, name string) ([]WorkflowDef, error) + ListWorkflows func(ctx context.Context, filter WorkflowFilter) ([]WorkflowInstance, error) + LoadCompactionState func(ctx context.Context, workflowID string) (*CompactionState, error) + LoadDAGSpec func(ctx context.Context, defName string, defVersion int) (json.RawMessage, error) + LoadEventHistory func(ctx context.Context, workflowID string) ([]EventRecord, error) + LoadEventHistoryPaginated func(ctx context.Context, workflowID string, offset, limit int) ([]EventRecord, error) + LoadMemoryEstimates func(ctx context.Context) (map[string]float64, error) + LoadMemoryStats func(ctx context.Context) ([]WorkflowMemoryStats, error) + LoadWASM func(ctx context.Context, defName string, defVersion int) ([]byte, error) + LoadWorkflowConfig func(ctx context.Context, defName string, defVersion int) (maxHistoryLength int, err error) + MarkVersionDeprecated func(ctx context.Context, name string, version int, deprecated bool) error + MoveToDeadLetterQueue func(ctx context.Context, workflowID, workerID string, generation int64, ...) error + PickVersionByRouting func(ctx context.Context, workflowName string) (int, error) + PollAndClaimSignal func(ctx context.Context, workflowID, signalName string) (payload string, found bool, err error) + PollCancellation func(ctx context.Context, workflowID string) (cancelled bool, reason string, err error) + PollSignal func(ctx context.Context, workflowID, signalName string) (payload string, found bool, err error) + PurgeWorkflowDef func(ctx context.Context, name string, version int) error + QueueDepth func(ctx context.Context) (int64, error) + ReapExpiredConcurrencyKeys func(ctx context.Context) (int64, error) + ReapStaleInstances func(ctx context.Context, timeout time.Duration) (int, error) + RecordWorkflowMemorySample func(ctx context.Context, defName string, sampleBytes int64) error + RejectPromise func(ctx context.Context, workflowID, promiseID, errMsg string) error + ReleaseConcurrencyKey func(ctx context.Context, key string) error + ReleaseWorkflow func(ctx context.Context, workflowID, workerID string, generation int64, ...) error + ReleaseWorkflowConcurrencyKeys func(ctx context.Context, workflowID string) error + RemoveRoutingRule func(ctx context.Context, ruleID string) error + RemoveWorkflowTag func(ctx context.Context, workflowName string, tag string) error + RequestCancellation func(ctx context.Context, workflowID, reason string) error + ResolveLatestVersion func(ctx context.Context, defName string) (int, error) + ResolvePromise func(ctx context.Context, workflowID, promiseID, result string) error + ResolveTenantFromAPIKey func(ctx context.Context, keyHash []byte) (uuid.UUID, error) + ResolveVersionByTag func(ctx context.Context, workflowName string, tag string) (int, error) + RetryWorkflow func(ctx context.Context, workflowID string) error + SetRoutingRule func(ctx context.Context, workflowName string, targetVersion int, weight float64) error + SetScheduleEnabled func(ctx context.Context, name string, enabled bool) error + SetWorkflowTag func(ctx context.Context, workflowName string, version int, tag string) error + StartChildWorkflow func(ctx context.Context, parentID, defName, inputJSON string, defVersion int, ...) (runID string, err error) + StartChildWorkflowAtomic func(ctx context.Context, childID, parentID, defName, inputJSON string, ...) (runID string, err error) + StartNewRun func(ctx context.Context, runID, defName string, defVersion int, ...) (string, bool, error) + StreamEventHistory func(ctx context.Context, workflowID string, pageSize int) (<-chan EventRecord, <-chan error) + TerminateWorkflow func(ctx context.Context, workflowID, reason string) error + TraceWorkflow func(ctx context.Context, workflowID, traceID string) error + UpdateScheduleNextRun func(ctx context.Context, name string, nextRun time.Time) error + UpdateStickyWorker func(ctx context.Context, workflowID, workerID string) error + ValidateVersion func(ctx context.Context, defName string, defVersion int) (bool, error) + VerifyWorkflowEvents func(ctx context.Context, workflowID string) error