UNPKG

@hotmeshio/hotmesh

Version:

Permanent-Memory Workflows & AI Agents

135 lines (134 loc) 4.18 kB
import { ActivityDuplex } from '../types/activity'; import { CollationFaultType, CollationStage } from '../types/collator'; import { MemFlowChildErrorType, MemFlowProxyErrorType, MemFlowSleepErrorType, MemFlowWaitForAllErrorType, MemFlowWaitForErrorType } from '../types/error'; declare class GetStateError extends Error { jobId: string; code: number; constructor(jobId: string); } declare class SetStateError extends Error { constructor(); } declare class MemFlowWaitForError extends Error { code: number; signalId: string; workflowId: string; index: number; workflowDimension: string; type: string; constructor(params: MemFlowWaitForErrorType); } declare class MemFlowProxyError extends Error { activityName: string; arguments: string[]; backoffCoefficient: number; code: number; index: number; maximumAttempts: number; maximumInterval: number; originJobId: string | null; parentWorkflowId: string; expire: number; workflowDimension: string; workflowId: string; workflowTopic: string; type: string; constructor(params: MemFlowProxyErrorType); } declare class MemFlowChildError extends Error { await: boolean; entity: string; arguments: string[]; backoffCoefficient: number; code: number; expire: number; persistent: boolean; signalIn: boolean; workflowDimension: string; index: number; maximumAttempts: number; maximumInterval: number; originJobId: string | null; parentWorkflowId: string; workflowId: string; workflowTopic: string; type: string; constructor(params: MemFlowChildErrorType); } declare class MemFlowWaitForAllError extends Error { items: any[]; code: number; workflowDimension: string; size: number; index: number; originJobId: string | null; parentWorkflowId: string; workflowId: string; workflowTopic: string; type: string; constructor(params: MemFlowWaitForAllErrorType); } declare class MemFlowSleepError extends Error { workflowId: string; code: number; duration: number; index: number; workflowDimension: string; type: string; constructor(params: MemFlowSleepErrorType); } declare class MemFlowTimeoutError extends Error { code: number; type: string; constructor(message: string, stack?: string); } declare class MemFlowMaxedError extends Error { code: number; type: string; constructor(message: string, stackTrace?: string); } declare class MemFlowFatalError extends Error { code: number; type: string; constructor(message: string, stackTrace?: string); } declare class MemFlowRetryError extends Error { code: number; type: string; constructor(message: string, stackTrace?: string); } declare class MapDataError extends Error { constructor(); } declare class RegisterTimeoutError extends Error { constructor(); } declare class DuplicateJobError extends Error { jobId: string; constructor(jobId: string); } declare class InactiveJobError extends Error { jobId: string; activityId: string; status: number; constructor(jobId: string, status: number, activityId: string); } declare class GenerationalError extends Error { expected: string; actual: string; jobId: string; activityId: string; dimensionalAddress: string; constructor(expected: string, actual: string, jobId: string, activityId: string, dimensionalAddress: string); } declare class ExecActivityError extends Error { constructor(); } declare class CollationError extends Error { status: number; leg: ActivityDuplex; stage: CollationStage; fault: CollationFaultType; constructor(status: number, leg: ActivityDuplex, stage: CollationStage, fault?: CollationFaultType); } export { CollationError, MemFlowChildError, MemFlowFatalError, MemFlowMaxedError, MemFlowProxyError, MemFlowRetryError, MemFlowSleepError, MemFlowTimeoutError, MemFlowWaitForAllError, MemFlowWaitForError, DuplicateJobError, ExecActivityError, GenerationalError, GetStateError, InactiveJobError, MapDataError, RegisterTimeoutError, SetStateError, };