Class LocalExecutor
Constructors
constructor
-
An executor whose journeys deliver their events through dispatchers that
dispatcherFactorymakes, or default dispatchers when none is given.Parameters
- dispatcherFactory: DispatcherFactory = ...
Returns LocalExecutor
Methods
run
-
Runs the one journey of
instance, and resolves to its result: it succeeded or failed, with its data bag, or it was aborted. Nothing that happens in the journey rejects.Parameters
- instance: WorkflowInstance
Returns Promise<JourneyResult>
Runs journeys in this process, one at a time, with no persistence: a journey lives only as long as the call to
runthat runs it. It accepts synchronous and asynchronous steps and reporters alike, and waits for whatever they return.For each journey it makes a new dispatcher with its dispatcher factory, the default one unless it is given another, and keeps nothing of the journey once
runsettles. Several executors run journeys in parallel.