Variable: ErrorCode {#variable-errorcode}
constErrorCode:object
String constants identifying specific engine error conditions.
Type Declaration {#type-declaration}
CHAIN_DEPTH_EXCEEDED {#chain_depth_exceeded}
readonlyCHAIN_DEPTH_EXCEEDED:"CHAIN_DEPTH_EXCEEDED"='CHAIN_DEPTH_EXCEEDED'
Event chain depth exceeds EngineOptions.maxChainDepth.
DRAIN_TIMEOUT {#drain_timeout}
readonlyDRAIN_TIMEOUT:"DRAIN_TIMEOUT"='DRAIN_TIMEOUT'
Engine.drain timed out waiting for runs to complete.
GRACEFUL_STOP_TIMEOUT {#graceful_stop_timeout}
readonlyGRACEFUL_STOP_TIMEOUT:"GRACEFUL_STOP_TIMEOUT"='GRACEFUL_STOP_TIMEOUT'
Engine.stop with graceful: true timed out.
HANDLER_NOT_FOUND {#handler_not_found}
readonlyHANDLER_NOT_FOUND:"HANDLER_NOT_FOUND"='HANDLER_NOT_FOUND'
No process registered for the emitted event name.
HANDLER_TIMEOUT {#handler_timeout}
readonlyHANDLER_TIMEOUT:"HANDLER_TIMEOUT"='HANDLER_TIMEOUT'
Handler execution exceeded EngineOptions.handlerTimeoutMs.
INVALID_CONFIG {#invalid_config}
readonlyINVALID_CONFIG:"INVALID_CONFIG"='INVALID_CONFIG'
An engine configuration option has an invalid value.
INVALID_RUN_STATE {#invalid_run_state}
readonlyINVALID_RUN_STATE:"INVALID_RUN_STATE"='INVALID_RUN_STATE'
An operation was attempted on a run in an invalid state.
LEASE_EXPIRED {#lease_expired}
readonlyLEASE_EXPIRED:"LEASE_EXPIRED"='LEASE_EXPIRED'
A run’s lease expired before it completed (crash recovery).
PAYLOAD_TOO_LARGE {#payload_too_large}
readonlyPAYLOAD_TOO_LARGE:"PAYLOAD_TOO_LARGE"='PAYLOAD_TOO_LARGE'
Emitted payload exceeds EngineOptions.maxPayloadBytes.
PROCESS_ALREADY_REGISTERED {#process_already_registered}
readonlyPROCESS_ALREADY_REGISTERED:"PROCESS_ALREADY_REGISTERED"='PROCESS_ALREADY_REGISTERED'
A process with the same name is already registered.
RUN_NOT_FOUND {#run_not_found}
readonlyRUN_NOT_FOUND:"RUN_NOT_FOUND"='RUN_NOT_FOUND'
A run was not found by ID.
SCHEMA_VALIDATION_FAILED {#schema_validation_failed}
readonlySCHEMA_VALIDATION_FAILED:"SCHEMA_VALIDATION_FAILED"='SCHEMA_VALIDATION_FAILED'
Payload failed the process schema’s parse() call.
Example {#example}
import { ErrorCode } from '@yellatech/engine'
if (err.code === ErrorCode.HANDLER_TIMEOUT) { ... }