Execution

Contents

bpmn-server / Execution

Class: Execution

is accessed two ways:
execute – start process
signal – invoke a node (userTask, event, etc.)

Hierarchy

Implements

Table of contents

Constructors

Properties

Accessors

Methods

Constructors

constructor

new Execution(server, name, source, state?): Execution

Parameters

Name Type Default value Description
server any undefined
name string undefined process name
source any undefined bpmn source
state any null

Returns

Execution

Overrides

ServerComponent.constructor

Defined in

engine/Execution.ts:62

Properties

instance

instance: InstanceObject

Implementation of

IExecution.instance

Defined in

engine/Execution.ts:26


tokens

tokens: Map<any, any>

Implementation of

IExecution.tokens

Defined in

engine/Execution.ts:27


definition

definition: IDefinition

Implementation of

IExecution.definition

Defined in

engine/Execution.ts:28


process

process: Process

Implementation of

IExecution.process

Defined in

engine/Execution.ts:29


errors

errors: any

Implementation of

IExecution.errors

Defined in

engine/Execution.ts:30


item

item: any

Implementation of

IExecution.item

Defined in

engine/Execution.ts:31


messageMatchingKey

messageMatchingKey: any

Implementation of

IExecution.messageMatchingKey

Defined in

engine/Execution.ts:32


worker

worker: any

Implementation of

IExecution.worker

Defined in

engine/Execution.ts:33


userName

userName: any

Implementation of

IExecution.userName

Defined in

engine/Execution.ts:34


promises

promises: any[] = []

Implementation of

IExecution.promises

Defined in

engine/Execution.ts:35


servicesProvider

servicesProvider: any

Defined in

engine/Execution.ts:36


isLocked

isLocked: boolean = false

Implementation of

IExecution.isLocked

Defined in

engine/Execution.ts:37


options

options: any

Implementation of

IExecution.options

Defined in

engine/Execution.ts:38


operation

operation: any

Defined in

engine/Execution.ts:39


uids

uids: Object = {}

Implementation of

IExecution.uids

Defined in

engine/Execution.ts:610


server

server: any

Implementation of

IExecution.server

Inherited from

ServerComponent.server

Defined in

server/ServerComponent.ts:9

Accessors

id

get id(): any

Returns

any

Implementation of

IExecution.id

Defined in

engine/Execution.ts:41


name

get name(): any

Returns

any

Implementation of

IExecution.name

Defined in

engine/Execution.ts:42


status

get status(): EXECUTION_STATUS

Returns

EXECUTION_STATUS

Implementation of

IExecution.status

Defined in

engine/Execution.ts:43


execution

get execution(): this

Returns

this

Defined in

engine/Execution.ts:44


listener

get listener(): any

Returns

any

Implementation of

IExecution.listener

Overrides

ServerComponent.listener

Defined in

engine/Execution.ts:52


configuration

get configuration(): any

Returns

any

Implementation of

IExecution.configuration

Inherited from

ServerComponent.configuration

Defined in

server/ServerComponent.ts:14


logger

get logger(): any

Returns

any

Implementation of

IExecution.logger

Inherited from

ServerComponent.logger

Defined in

server/ServerComponent.ts:15


cron

get cron(): Cron

Returns

Cron

Implementation of

IExecution.cron

Inherited from

ServerComponent.cron

Defined in

server/ServerComponent.ts:16


cache

get cache(): CacheManager

Returns

CacheManager

Implementation of

IExecution.cache

Inherited from

ServerComponent.cache

Defined in

server/ServerComponent.ts:17


appDelegate

get appDelegate(): any

Returns

any

Implementation of

IExecution.appDelegate

Inherited from

ServerComponent.appDelegate

Defined in

server/ServerComponent.ts:18


engine

get engine(): IEngine

Returns

IEngine

Implementation of

IExecution.engine

Inherited from

ServerComponent.engine

Defined in

server/ServerComponent.ts:19


dataStore

get dataStore(): any

Returns

any

Implementation of

IExecution.dataStore

Inherited from

ServerComponent.dataStore

Defined in

server/ServerComponent.ts:20


definitions

get definitions(): any

Returns

any

Implementation of

IExecution.definitions

Inherited from

ServerComponent.definitions

Defined in

server/ServerComponent.ts:21

Methods

tillDone

tillDone(): Promise<Execution>

Returns

Promise<Execution>

Defined in

engine/Execution.ts:46


getNodeById

getNodeById(id): Node

Parameters

Name Type
id any

Returns

Node

Implementation of

IExecution.getNodeById

Defined in

engine/Execution.ts:76


getToken

getToken(id): Token

Parameters

Name Type
id number

Returns

Token

Implementation of

IExecution.getToken

Defined in

engine/Execution.ts:79


tokenEnded

tokenEnded(token): void

Parameters

Name Type
token Token

Returns

void

Implementation of

IExecution.tokenEnded

Defined in

engine/Execution.ts:82


end

end(): Promise<void>

Returns

Promise<void>

Implementation of

IExecution.end

Defined in

engine/Execution.ts:90


terminate

terminate(): void

causes the execution to stop from running any further

Returns

void

Implementation of

IExecution.terminate

Defined in

engine/Execution.ts:104


stop

stop(): void

causes the execution to stop from running any further

Returns

void

Implementation of

IExecution.stop

Defined in

engine/Execution.ts:114


execute

execute(startNodeId?, inputData?, options?): Promise<void>

Parameters

Name Type Default value
startNodeId any null
inputData Object {}
options Object {}

Returns

Promise<void>

Implementation of

IExecution.execute

Defined in

engine/Execution.ts:121


assign

assign(executionId, inputData, assignment?, userName, options?): Promise<void>

Parameters

Name Type
executionId any
inputData any
assignment Object
userName any
options Object

Returns

Promise<void>

Defined in

engine/Execution.ts:181


signalItem

signalItem(itemId, inputData, userName, options?): Promise<IExecution>

invoke scenarios:
itemId
elementId – but only one is active
elementId – for a startEvent in a secondary process

Parameters

Name Type
itemId any
inputData any
userName any
options Object

Returns

Promise<IExecution>

Implementation of

IExecution.signalItem

Defined in

engine/Execution.ts:218


restart

restart(itemId, inputData, userName, options?): Promise<IExecution>

restarting an already completed instance at a particular node

Parameters

Name Type
itemId any
inputData any
userName any
options Object

Returns

Promise<IExecution>

Defined in

engine/Execution.ts:268


signalEvent

signalEvent(executionId, inputData, userName, options?): Promise<IExecution>

Parameters

Name Type
executionId any
inputData any
userName any
options Object

Returns

Promise<IExecution>

Implementation of

IExecution.signalEvent

Defined in

engine/Execution.ts:290


signalRepeatTimerEvent

signalRepeatTimerEvent(executionId, prevItem, inputData, options?): Promise<IExecution>

Parameters

Name Type
executionId any
prevItem any
inputData any
options Object

Returns

Promise<IExecution>

Implementation of

IExecution.signalRepeatTimerEvent

Defined in

engine/Execution.ts:390


save

save(): Promise<void>

Returns

Promise<void>

Implementation of

IExecution.save

Defined in

engine/Execution.ts:420


getItems

getItems(): Item[]

Returns

Item[]

Implementation of

IExecution.getItems

Defined in

engine/Execution.ts:433


getItemsData

getItemsData(): any[]

Returns

any[]

Implementation of

IExecution.getItemsData

Defined in

engine/Execution.ts:444


getState

getState(): IInstanceData

Returns

IInstanceData

Implementation of

IExecution.getState

Defined in

engine/Execution.ts:454


findSavePoint

findSavePoint(state, itemId): any

Parameters

Name Type
state any
itemId any

Returns

any

Defined in

engine/Execution.ts:475


restore

restore(server, state, itemId?): Promise<Execution>

re-enstate the execution from db

Parameters

Name Type Default value
server any undefined
state IInstanceData undefined
itemId any null

Returns

Promise<Execution>

Defined in

engine/Execution.ts:495


restored

restored(): Promise<void>

Returns

Promise<void>

Implementation of

IExecution.restored

Defined in

engine/Execution.ts:569


resume

resume(): Promise<void>

Returns

Promise<void>

Implementation of

IExecution.resume

Defined in

engine/Execution.ts:576


report

report(): void

Returns

void

Implementation of

IExecution.report

Defined in

engine/Execution.ts:582


getNewId

getNewId(scope): number

Parameters

Name Type
scope string

Returns

number

Implementation of

IExecution.getNewId

Defined in

engine/Execution.ts:612


getUUID

getUUID(): any

Returns

any

Implementation of

IExecution.getUUID

Defined in

engine/Execution.ts:619


doExecutionEvent

doExecutionEvent(process, event): Promise<void>

Parameters

Name Type
process any
event any

Returns

Promise<void>

Implementation of

IExecution.doExecutionEvent

Defined in

engine/Execution.ts:626


doItemEvent

doItemEvent(item, event): Promise<void>

Parameters

Name Type
item any
event any

Returns

Promise<void>

Implementation of

IExecution.doItemEvent

Defined in

engine/Execution.ts:632


log

log(...msg): void

Parameters

Name Type
...msg any[]

Returns

void

Implementation of

IExecution.log

Defined in

engine/Execution.ts:637


info

info(...msg): void

Parameters

Name Type
...msg any[]

Returns

void

Implementation of

IExecution.info

Defined in

engine/Execution.ts:640


error

error(msg): void

Parameters

Name Type
msg any

Returns

void

Implementation of

IExecution.error

Defined in

engine/Execution.ts:643


appendData

appendData(inputData, item, dataPath?, assignment?): void

Parameters

Name Type Default value
inputData any undefined
item any undefined
dataPath any null
assignment any null

Returns

void

Implementation of

IExecution.appendData

Defined in

engine/Execution.ts:652


getData

getData(dataPath): any

Parameters

Name Type
dataPath any

Returns

any

Implementation of

IExecution.getData

Defined in

engine/Execution.ts:688


getAndCreateData

getAndCreateData(dataPath, asArray?): any

Parameters

Name Type Default value
dataPath any undefined
asArray boolean false

Returns

any

Implementation of

IExecution.getAndCreateData

Defined in

engine/Execution.ts:701