@quantumbpm/sdk 1.2.0 → 2.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +93 -34
- package/dist/auth.d.ts +19 -14
- package/dist/auth.js +62 -84
- package/dist/bpmn.d.ts +83 -21
- package/dist/bpmn.js +61 -33
- package/dist/dmn.d.ts +0 -6
- package/dist/dmn.js +1 -15
- package/dist/generated/RawClient.js +2 -2
- package/dist/generated/core/OpenAPI.js +2 -2
- package/dist/generated/index.d.ts +9 -2
- package/dist/generated/index.js +8 -4
- package/dist/generated/models/BpmnActivityState.d.ts +85 -0
- package/dist/generated/models/BpmnActivityState.js +18 -0
- package/dist/generated/models/BpmnElementStatistics.d.ts +36 -0
- package/dist/generated/models/BpmnElementStatistics.js +17 -0
- package/dist/generated/models/BpmnExternalJobPaginatedResponse.d.ts +2 -2
- package/dist/generated/models/BpmnExternalJobPaginatedResponse.js +1 -1
- package/dist/generated/models/BpmnHistoryPage.d.ts +15 -0
- package/dist/generated/models/BpmnHistoryPage.js +3 -0
- package/dist/generated/models/BpmnIncident.d.ts +17 -17
- package/dist/generated/models/BpmnIncident.js +11 -11
- package/dist/generated/models/BpmnIncidentRecord.d.ts +10 -18
- package/dist/generated/models/BpmnIncidentRecord.js +6 -6
- package/dist/generated/models/BpmnIncidentRecordPaginatedResponse.d.ts +2 -2
- package/dist/generated/models/BpmnIncidentRecordPaginatedResponse.js +1 -1
- package/dist/generated/models/BpmnInstance.d.ts +21 -29
- package/dist/generated/models/BpmnInstance.js +1 -17
- package/dist/generated/models/BpmnInstancePaginatedResponse.d.ts +2 -2
- package/dist/generated/models/BpmnInstancePaginatedResponse.js +1 -1
- package/dist/generated/models/BpmnInstanceState.d.ts +49 -16
- package/dist/generated/models/BpmnInstanceState.js +1 -1
- package/dist/generated/models/BpmnInstanceStatus.d.ts +10 -0
- package/dist/generated/models/BpmnInstanceStatus.js +19 -0
- package/dist/generated/models/BpmnProcessDefinition.d.ts +5 -5
- package/dist/generated/models/BpmnProcessDefinition.js +1 -1
- package/dist/generated/models/BpmnProcessVersion.d.ts +9 -9
- package/dist/generated/models/BpmnProcessVersion.js +1 -1
- package/dist/generated/models/BpmnUserTaskPaginatedResponse.d.ts +2 -2
- package/dist/generated/models/BpmnUserTaskPaginatedResponse.js +1 -1
- package/dist/generated/models/CorrelationKeyNumber.d.ts +1 -1
- package/dist/generated/models/CorrelationKeyNumber.js +1 -1
- package/dist/generated/models/CorrelationKeys.d.ts +7 -6
- package/dist/generated/models/CorrelationKeys.js +1 -1
- package/dist/generated/models/CreateDefinitionRequest.d.ts +1 -5
- package/dist/generated/models/CreateDefinitionRequest.js +1 -1
- package/dist/generated/models/CursorPage.d.ts +12 -0
- package/dist/generated/models/CursorPage.js +3 -0
- package/dist/generated/models/DecisionSummary.d.ts +2 -2
- package/dist/generated/models/DecisionSummary.js +1 -1
- package/dist/generated/models/DecisionVersion.d.ts +25 -0
- package/dist/generated/models/DecisionVersion.js +3 -0
- package/dist/generated/models/DecisionVersionList.d.ts +7 -0
- package/dist/generated/models/DecisionVersionList.js +3 -0
- package/dist/generated/models/Definition.d.ts +16 -8
- package/dist/generated/models/Definition.js +1 -1
- package/dist/generated/models/Error.d.ts +8 -2
- package/dist/generated/models/Error.js +6 -2
- package/dist/generated/models/EvaluateStoredRequest.d.ts +6 -4
- package/dist/generated/models/EvaluateStoredRequest.js +1 -1
- package/dist/generated/models/EvaluationResult.d.ts +6 -0
- package/dist/generated/models/EvaluationResult.js +1 -1
- package/dist/generated/models/Execution.d.ts +30 -9
- package/dist/generated/models/Execution.js +1 -1
- package/dist/generated/models/ExternalJob.d.ts +9 -9
- package/dist/generated/models/ExternalJob.js +1 -1
- package/dist/generated/models/ExternalJobBatchResponse.d.ts +2 -2
- package/dist/generated/models/ExternalJobBatchResponse.js +1 -1
- package/dist/generated/models/JoinArrivals.d.ts +8 -0
- package/dist/generated/models/JoinArrivals.js +3 -0
- package/dist/generated/models/PollBpmnJobRequest.d.ts +1 -1
- package/dist/generated/models/PollBpmnJobRequest.js +1 -1
- package/dist/generated/models/StartBpmnInstanceRequest.d.ts +6 -2
- package/dist/generated/models/StartBpmnInstanceRequest.js +1 -1
- package/dist/generated/models/SuspendBpmnInstanceRequest.d.ts +1 -1
- package/dist/generated/models/SuspendBpmnInstanceRequest.js +1 -1
- package/dist/generated/models/SuspensionEntry.d.ts +2 -2
- package/dist/generated/models/SuspensionEntry.js +1 -1
- package/dist/generated/models/UpdateDefinitionRequest.d.ts +1 -5
- package/dist/generated/models/UpdateDefinitionRequest.js +1 -1
- package/dist/generated/models/UpdateUserTaskAssignmentRequest.d.ts +11 -4
- package/dist/generated/models/UpdateUserTaskAssignmentRequest.js +1 -1
- package/dist/generated/models/UserTask.d.ts +15 -11
- package/dist/generated/models/UserTask.js +1 -1
- package/dist/generated/services/BpmnService.d.ts +191 -94
- package/dist/generated/services/BpmnService.js +300 -119
- package/dist/generated/services/DefaultService.d.ts +118 -118
- package/dist/generated/services/DefaultService.js +156 -160
- package/dist/index.d.ts +8 -8
- package/dist/index.js +7 -7
- package/dist/tracing.js +2 -2
- package/dist/workers.d.ts +41 -7
- package/dist/workers.js +186 -53
- package/package.json +2 -4
- package/src/auth.test.ts +128 -0
- package/src/auth.ts +67 -64
- package/src/bpmn.ts +131 -43
- package/src/dmn.ts +0 -19
- package/src/generated/RawClient.ts +1 -1
- package/src/generated/core/OpenAPI.ts +1 -1
- package/src/generated/index.ts +9 -2
- package/src/generated/models/BpmnActivityState.ts +90 -0
- package/src/generated/models/BpmnElementStatistics.ts +41 -0
- package/src/generated/models/BpmnExternalJobPaginatedResponse.ts +2 -2
- package/src/generated/models/BpmnHistoryPage.ts +20 -0
- package/src/generated/models/BpmnIncident.ts +17 -17
- package/src/generated/models/BpmnIncidentRecord.ts +10 -18
- package/src/generated/models/BpmnIncidentRecordPaginatedResponse.ts +2 -2
- package/src/generated/models/BpmnInstance.ts +21 -29
- package/src/generated/models/BpmnInstancePaginatedResponse.ts +2 -2
- package/src/generated/models/BpmnInstanceState.ts +49 -16
- package/src/generated/models/BpmnInstanceStatus.ts +14 -0
- package/src/generated/models/BpmnProcessDefinition.ts +5 -5
- package/src/generated/models/BpmnProcessVersion.ts +9 -9
- package/src/generated/models/BpmnUserTaskPaginatedResponse.ts +2 -2
- package/src/generated/models/CorrelationKeyNumber.ts +1 -1
- package/src/generated/models/CorrelationKeys.ts +7 -6
- package/src/generated/models/CreateDefinitionRequest.ts +1 -5
- package/src/generated/models/CursorPage.ts +17 -0
- package/src/generated/models/DecisionSummary.ts +2 -2
- package/src/generated/models/DecisionVersion.ts +30 -0
- package/src/generated/models/DecisionVersionList.ts +12 -0
- package/src/generated/models/Definition.ts +16 -8
- package/src/generated/models/Error.ts +8 -2
- package/src/generated/models/EvaluateStoredRequest.ts +6 -4
- package/src/generated/models/EvaluationResult.ts +6 -0
- package/src/generated/models/Execution.ts +30 -9
- package/src/generated/models/ExternalJob.ts +9 -9
- package/src/generated/models/ExternalJobBatchResponse.ts +2 -2
- package/src/generated/models/JoinArrivals.ts +13 -0
- package/src/generated/models/PollBpmnJobRequest.ts +1 -1
- package/src/generated/models/StartBpmnInstanceRequest.ts +6 -2
- package/src/generated/models/SuspendBpmnInstanceRequest.ts +1 -1
- package/src/generated/models/SuspensionEntry.ts +2 -2
- package/src/generated/models/UpdateDefinitionRequest.ts +1 -5
- package/src/generated/models/UpdateUserTaskAssignmentRequest.ts +11 -4
- package/src/generated/models/UserTask.ts +15 -11
- package/src/generated/services/BpmnService.ts +357 -140
- package/src/generated/services/DefaultService.ts +178 -189
- package/src/index.test.ts +77 -31
- package/src/index.ts +13 -6
- package/src/tracing.ts +1 -1
- package/src/workers.test.ts +280 -3
- package/src/workers.ts +200 -60
- package/dist/generated/models/CreateProjectRequest.d.ts +0 -9
- package/dist/generated/models/CreateProjectRequest.js +0 -3
- package/src/generated/models/CreateProjectRequest.ts +0 -14
package/src/generated/index.ts
CHANGED
|
@@ -13,14 +13,18 @@ export type { OpenAPIConfig } from './core/OpenAPI';
|
|
|
13
13
|
export type { ActiveScope } from './models/ActiveScope';
|
|
14
14
|
export type { BatchEvaluateDesignRequest } from './models/BatchEvaluateDesignRequest';
|
|
15
15
|
export type { BatchEvaluationResponse } from './models/BatchEvaluationResponse';
|
|
16
|
+
export { BpmnActivityState } from './models/BpmnActivityState';
|
|
17
|
+
export { BpmnElementStatistics } from './models/BpmnElementStatistics';
|
|
16
18
|
export type { BpmnExternalJobPaginatedResponse } from './models/BpmnExternalJobPaginatedResponse';
|
|
19
|
+
export type { BpmnHistoryPage } from './models/BpmnHistoryPage';
|
|
17
20
|
export { BpmnIncident } from './models/BpmnIncident';
|
|
18
21
|
export { BpmnIncidentRecord } from './models/BpmnIncidentRecord';
|
|
19
22
|
export type { BpmnIncidentRecordPaginatedResponse } from './models/BpmnIncidentRecordPaginatedResponse';
|
|
20
|
-
export { BpmnInstance } from './models/BpmnInstance';
|
|
23
|
+
export type { BpmnInstance } from './models/BpmnInstance';
|
|
21
24
|
export type { BpmnInstanceChildrenResponse } from './models/BpmnInstanceChildrenResponse';
|
|
22
25
|
export type { BpmnInstancePaginatedResponse } from './models/BpmnInstancePaginatedResponse';
|
|
23
26
|
export type { BpmnInstanceState } from './models/BpmnInstanceState';
|
|
27
|
+
export { BpmnInstanceStatus } from './models/BpmnInstanceStatus';
|
|
24
28
|
export type { BpmnProcessDefinition } from './models/BpmnProcessDefinition';
|
|
25
29
|
export type { BpmnProcessSummary } from './models/BpmnProcessSummary';
|
|
26
30
|
export type { BpmnProcessSummaryPaginatedResponse } from './models/BpmnProcessSummaryPaginatedResponse';
|
|
@@ -41,9 +45,11 @@ export type { CorrelationKeys } from './models/CorrelationKeys';
|
|
|
41
45
|
export type { CorrelationKeyString } from './models/CorrelationKeyString';
|
|
42
46
|
export type { CreateBpmnResourceRequest } from './models/CreateBpmnResourceRequest';
|
|
43
47
|
export type { CreateDefinitionRequest } from './models/CreateDefinitionRequest';
|
|
44
|
-
export type {
|
|
48
|
+
export type { CursorPage } from './models/CursorPage';
|
|
45
49
|
export type { DecisionInputField } from './models/DecisionInputField';
|
|
46
50
|
export type { DecisionSummary } from './models/DecisionSummary';
|
|
51
|
+
export type { DecisionVersion } from './models/DecisionVersion';
|
|
52
|
+
export type { DecisionVersionList } from './models/DecisionVersionList';
|
|
47
53
|
export type { Definition } from './models/Definition';
|
|
48
54
|
export type { ElementMapping } from './models/ElementMapping';
|
|
49
55
|
export { Error } from './models/Error';
|
|
@@ -63,6 +69,7 @@ export type { FeelString } from './models/FeelString';
|
|
|
63
69
|
export type { FeelValue } from './models/FeelValue';
|
|
64
70
|
export type { FeelWarning } from './models/FeelWarning';
|
|
65
71
|
export type { HitRule } from './models/HitRule';
|
|
72
|
+
export type { JoinArrivals } from './models/JoinArrivals';
|
|
66
73
|
export type { MigrateBpmnInstanceRequest } from './models/MigrateBpmnInstanceRequest';
|
|
67
74
|
export type { MigrationValidationResult } from './models/MigrationValidationResult';
|
|
68
75
|
export { ModificationInstruction } from './models/ModificationInstruction';
|
|
@@ -0,0 +1,90 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
/**
|
|
6
|
+
* Execution record for a single BPMN activity (service task, user task, gateway, etc.).
|
|
7
|
+
*/
|
|
8
|
+
export type BpmnActivityState = {
|
|
9
|
+
/**
|
|
10
|
+
* Position of the entry in the instance's history, from 1.
|
|
11
|
+
*/
|
|
12
|
+
seq?: number;
|
|
13
|
+
/**
|
|
14
|
+
* ID of the BPMN flow node.
|
|
15
|
+
*/
|
|
16
|
+
nodeID?: string;
|
|
17
|
+
/**
|
|
18
|
+
* Type of the BPMN node (e.g. ServiceTask, UserTask, ExclusiveGateway).
|
|
19
|
+
*/
|
|
20
|
+
nodeType?: string;
|
|
21
|
+
/**
|
|
22
|
+
* Execution outcome - Started, Completed, Failed, Canceled, or Resolved. `Resolved` replaces `Failed` once the originating incident is removed (retry, modification-cancel, boundary catch); the entry's `errorMessage` is preserved so the failed attempt remains auditable.
|
|
23
|
+
*/
|
|
24
|
+
status?: BpmnActivityState.status;
|
|
25
|
+
/**
|
|
26
|
+
* When the element started. Each entry records one event, so a Started entry carries it and a Completed, Failed, Canceled or Resolved entry leaves it out. An entry for an operation, such as a suspension or a migration, carries both times. Entries are ordered by `seq`, not by time.
|
|
27
|
+
*/
|
|
28
|
+
startTime?: string;
|
|
29
|
+
/**
|
|
30
|
+
* When the element ended. Absent on a Started entry.
|
|
31
|
+
*/
|
|
32
|
+
endTime?: string;
|
|
33
|
+
/**
|
|
34
|
+
* Input variables evaluated at activity entry. Absent on history page entries.
|
|
35
|
+
*/
|
|
36
|
+
inputs?: Record<string, any>;
|
|
37
|
+
/**
|
|
38
|
+
* Output variables produced by the activity. Absent on history page entries.
|
|
39
|
+
*/
|
|
40
|
+
outputs?: Record<string, any>;
|
|
41
|
+
/**
|
|
42
|
+
* Failure reason on Failed / Canceled / Resolved entries. Empty on success paths.
|
|
43
|
+
*/
|
|
44
|
+
errorMessage?: string;
|
|
45
|
+
/**
|
|
46
|
+
* BPMN `errorCode` of the throw error that caused the failure. Set on Failed/Resolved entries originating from a BPMN error; empty for non-BPMN failures. Error variables (if any) ride on `outputs` since a Failed entry doesn't otherwise produce outputs.
|
|
47
|
+
*/
|
|
48
|
+
errorCode?: string;
|
|
49
|
+
/**
|
|
50
|
+
* Key of the element's execution, the same on its Started and its ending entry. Absent for an element that runs no execution, such as a start or end event.
|
|
51
|
+
*/
|
|
52
|
+
executionKey?: string;
|
|
53
|
+
/**
|
|
54
|
+
* User or service account whose call produced this entry: the completion of a job or user task, the publish of a message or signal a catch took, a start, a resolve, a suspension or a cancel. Empty for an entry the engine produced on its own.
|
|
55
|
+
*/
|
|
56
|
+
actor?: string;
|
|
57
|
+
/**
|
|
58
|
+
* Task type of the external job this entry ended, on the Completed, Failed or Canceled entry of a job's element. Empty otherwise.
|
|
59
|
+
*/
|
|
60
|
+
taskType?: string;
|
|
61
|
+
/**
|
|
62
|
+
* Retries the external job had left when a worker or a lock expiry reported its outcome. Absent on a job the engine canceled.
|
|
63
|
+
*/
|
|
64
|
+
retries?: number;
|
|
65
|
+
/**
|
|
66
|
+
* `clientID` of the worker that reported the external job's outcome, or whose lock ran out. Empty when no worker was named.
|
|
67
|
+
*/
|
|
68
|
+
worker?: string;
|
|
69
|
+
/**
|
|
70
|
+
* For CallActivity nodes, the identifier of the child instance spawned by this execution. Empty for non-CallActivity nodes.
|
|
71
|
+
*/
|
|
72
|
+
childInstanceID?: string;
|
|
73
|
+
/**
|
|
74
|
+
* IDs of the sequence flows that brought the token to this element, on its first entry (Started, or Completed for an element without duration). A join firing lists every flow it consumed, a join cancelled before it fired lists the flows that had reached it. A flow is taken when some entry lists it, together with `pendingJoinArrivals` on the instance state.
|
|
75
|
+
*/
|
|
76
|
+
incomingFlows?: Array<string>;
|
|
77
|
+
};
|
|
78
|
+
export namespace BpmnActivityState {
|
|
79
|
+
/**
|
|
80
|
+
* Execution outcome - Started, Completed, Failed, Canceled, or Resolved. `Resolved` replaces `Failed` once the originating incident is removed (retry, modification-cancel, boundary catch); the entry's `errorMessage` is preserved so the failed attempt remains auditable.
|
|
81
|
+
*/
|
|
82
|
+
export enum status {
|
|
83
|
+
STARTED = 'Started',
|
|
84
|
+
COMPLETED = 'Completed',
|
|
85
|
+
FAILED = 'Failed',
|
|
86
|
+
CANCELED = 'Canceled',
|
|
87
|
+
RESOLVED = 'Resolved',
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
/**
|
|
6
|
+
* What an instance's history recorded for one element.
|
|
7
|
+
*/
|
|
8
|
+
export type BpmnElementStatistics = {
|
|
9
|
+
/**
|
|
10
|
+
* Times the element completed.
|
|
11
|
+
*/
|
|
12
|
+
completed?: number;
|
|
13
|
+
/**
|
|
14
|
+
* Times the element failed.
|
|
15
|
+
*/
|
|
16
|
+
failed?: number;
|
|
17
|
+
/**
|
|
18
|
+
* Times the element was canceled.
|
|
19
|
+
*/
|
|
20
|
+
canceled?: number;
|
|
21
|
+
/**
|
|
22
|
+
* The element's latest Completed, Failed, Canceled or Resolved entry.
|
|
23
|
+
*/
|
|
24
|
+
lastStatus?: BpmnElementStatistics.lastStatus;
|
|
25
|
+
/**
|
|
26
|
+
* For a call activity, the child its latest execution started.
|
|
27
|
+
*/
|
|
28
|
+
childInstanceID?: string;
|
|
29
|
+
};
|
|
30
|
+
export namespace BpmnElementStatistics {
|
|
31
|
+
/**
|
|
32
|
+
* The element's latest Completed, Failed, Canceled or Resolved entry.
|
|
33
|
+
*/
|
|
34
|
+
export enum lastStatus {
|
|
35
|
+
COMPLETED = 'Completed',
|
|
36
|
+
FAILED = 'Failed',
|
|
37
|
+
CANCELED = 'Canceled',
|
|
38
|
+
RESOLVED = 'Resolved',
|
|
39
|
+
}
|
|
40
|
+
}
|
|
41
|
+
|
|
@@ -2,13 +2,13 @@
|
|
|
2
2
|
/* istanbul ignore file */
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
5
|
+
import type { CursorPage } from './CursorPage';
|
|
5
6
|
import type { ExternalJob } from './ExternalJob';
|
|
6
|
-
import type { PaginationMetadata } from './PaginationMetadata';
|
|
7
7
|
/**
|
|
8
8
|
* Page of external jobs.
|
|
9
9
|
*/
|
|
10
10
|
export type BpmnExternalJobPaginatedResponse = {
|
|
11
11
|
data: Array<ExternalJob>;
|
|
12
|
-
pagination:
|
|
12
|
+
pagination: CursorPage;
|
|
13
13
|
};
|
|
14
14
|
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
import type { BpmnActivityState } from './BpmnActivityState';
|
|
6
|
+
/**
|
|
7
|
+
* A window of an instance's BPMN history, oldest first. Its entries carry
|
|
8
|
+
* no `inputs` or `outputs`. `total` is the entry count at the time of the
|
|
9
|
+
* call, which is also the newest entry's `seq`. It grows while the
|
|
10
|
+
* instance runs. New entries never reorder earlier ones.
|
|
11
|
+
*
|
|
12
|
+
*/
|
|
13
|
+
export type BpmnHistoryPage = {
|
|
14
|
+
items: Array<BpmnActivityState>;
|
|
15
|
+
/**
|
|
16
|
+
* Number of history entries at the time of the call.
|
|
17
|
+
*/
|
|
18
|
+
total: number;
|
|
19
|
+
};
|
|
20
|
+
|
|
@@ -41,19 +41,19 @@ export type BpmnIncident = {
|
|
|
41
41
|
/**
|
|
42
42
|
* Category of the error. Values:
|
|
43
43
|
* * `BpmnError` - A `bpmn:error` thrown by the process or an external job worker.
|
|
44
|
-
* * `EscalationError` - A `bpmn:escalation` raised by the process.
|
|
45
44
|
* * `CompensationError` - Failure during compensation handler execution.
|
|
46
45
|
* * `FeelError` - A FEEL expression failed to evaluate.
|
|
47
|
-
* * `NoHandler` - A thrown error/escalation has no matching catch event.
|
|
48
46
|
* * `GatewayNoMatch` - An exclusive gateway evaluated all conditions to false with no default flow.
|
|
49
47
|
* * `TimerResolution` - A timer expression could not be parsed or resolved.
|
|
50
48
|
* * `LinkNotFound` - A link throw event has no matching link catch.
|
|
51
49
|
* * `MigrationError` - A process instance migration could not be applied.
|
|
52
|
-
* * `SubscriptionError` - A message/signal listener's registry row could not be written; the listener is dead until resolved.
|
|
53
|
-
* * `RotationLimitError` - The instance reached its ContinueAsNew rotation cap.
|
|
54
|
-
* * `SnapshotSizeExceeded` - A ContinueAsNew snapshot exceeded the configured size cap.
|
|
55
50
|
* * `CallActivityCanceled` - A call-activity child terminated as Canceled out-of-band.
|
|
56
51
|
* * `ExternalRowRefreshError` - A migration could not rewrite a parked wait's external row (job, user task or subscription) against the target definition. Resolving re-runs the refresh.
|
|
52
|
+
* * `JobLockLost` - An external job's worker lock ran out, by missed heartbeats or the maximum hold, with no retries left.
|
|
53
|
+
* * `DecisionNotFound` - A business rule task called a decision, or a pinned version of one, that is not deployed.
|
|
54
|
+
* * `DecisionEvaluationError` - The decision a business rule task called failed while it was evaluated, such as a FEEL error or a violated hit policy. The failed evaluation is recorded.
|
|
55
|
+
* * `ProcessNotFound` - A call activity called a process, or a pinned version of one, that is not deployed.
|
|
56
|
+
* * `ProcessSuspended` - A call activity called a suspended process version.
|
|
57
57
|
* * `Unknown` - Internal error not classified above.
|
|
58
58
|
*
|
|
59
59
|
*/
|
|
@@ -63,45 +63,45 @@ export type BpmnIncident = {
|
|
|
63
63
|
*/
|
|
64
64
|
variables?: Record<string, any>;
|
|
65
65
|
/**
|
|
66
|
-
*
|
|
66
|
+
* When the incident was raised.
|
|
67
67
|
*/
|
|
68
|
-
|
|
68
|
+
raisedAt?: string;
|
|
69
69
|
};
|
|
70
70
|
export namespace BpmnIncident {
|
|
71
71
|
/**
|
|
72
72
|
* Category of the error. Values:
|
|
73
73
|
* * `BpmnError` - A `bpmn:error` thrown by the process or an external job worker.
|
|
74
|
-
* * `EscalationError` - A `bpmn:escalation` raised by the process.
|
|
75
74
|
* * `CompensationError` - Failure during compensation handler execution.
|
|
76
75
|
* * `FeelError` - A FEEL expression failed to evaluate.
|
|
77
|
-
* * `NoHandler` - A thrown error/escalation has no matching catch event.
|
|
78
76
|
* * `GatewayNoMatch` - An exclusive gateway evaluated all conditions to false with no default flow.
|
|
79
77
|
* * `TimerResolution` - A timer expression could not be parsed or resolved.
|
|
80
78
|
* * `LinkNotFound` - A link throw event has no matching link catch.
|
|
81
79
|
* * `MigrationError` - A process instance migration could not be applied.
|
|
82
|
-
* * `SubscriptionError` - A message/signal listener's registry row could not be written; the listener is dead until resolved.
|
|
83
|
-
* * `RotationLimitError` - The instance reached its ContinueAsNew rotation cap.
|
|
84
|
-
* * `SnapshotSizeExceeded` - A ContinueAsNew snapshot exceeded the configured size cap.
|
|
85
80
|
* * `CallActivityCanceled` - A call-activity child terminated as Canceled out-of-band.
|
|
86
81
|
* * `ExternalRowRefreshError` - A migration could not rewrite a parked wait's external row (job, user task or subscription) against the target definition. Resolving re-runs the refresh.
|
|
82
|
+
* * `JobLockLost` - An external job's worker lock ran out, by missed heartbeats or the maximum hold, with no retries left.
|
|
83
|
+
* * `DecisionNotFound` - A business rule task called a decision, or a pinned version of one, that is not deployed.
|
|
84
|
+
* * `DecisionEvaluationError` - The decision a business rule task called failed while it was evaluated, such as a FEEL error or a violated hit policy. The failed evaluation is recorded.
|
|
85
|
+
* * `ProcessNotFound` - A call activity called a process, or a pinned version of one, that is not deployed.
|
|
86
|
+
* * `ProcessSuspended` - A call activity called a suspended process version.
|
|
87
87
|
* * `Unknown` - Internal error not classified above.
|
|
88
88
|
*
|
|
89
89
|
*/
|
|
90
90
|
export enum errorType {
|
|
91
91
|
BPMN_ERROR = 'BpmnError',
|
|
92
|
-
ESCALATION_ERROR = 'EscalationError',
|
|
93
92
|
COMPENSATION_ERROR = 'CompensationError',
|
|
94
93
|
FEEL_ERROR = 'FeelError',
|
|
95
|
-
NO_HANDLER = 'NoHandler',
|
|
96
94
|
GATEWAY_NO_MATCH = 'GatewayNoMatch',
|
|
97
95
|
TIMER_RESOLUTION = 'TimerResolution',
|
|
98
96
|
LINK_NOT_FOUND = 'LinkNotFound',
|
|
99
97
|
MIGRATION_ERROR = 'MigrationError',
|
|
100
|
-
SUBSCRIPTION_ERROR = 'SubscriptionError',
|
|
101
|
-
ROTATION_LIMIT_ERROR = 'RotationLimitError',
|
|
102
|
-
SNAPSHOT_SIZE_EXCEEDED = 'SnapshotSizeExceeded',
|
|
103
98
|
CALL_ACTIVITY_CANCELED = 'CallActivityCanceled',
|
|
104
99
|
EXTERNAL_ROW_REFRESH_ERROR = 'ExternalRowRefreshError',
|
|
100
|
+
JOB_LOCK_LOST = 'JobLockLost',
|
|
101
|
+
DECISION_NOT_FOUND = 'DecisionNotFound',
|
|
102
|
+
DECISION_EVALUATION_ERROR = 'DecisionEvaluationError',
|
|
103
|
+
PROCESS_NOT_FOUND = 'ProcessNotFound',
|
|
104
|
+
PROCESS_SUSPENDED = 'ProcessSuspended',
|
|
105
105
|
UNKNOWN = 'Unknown',
|
|
106
106
|
}
|
|
107
107
|
}
|
|
@@ -5,7 +5,7 @@
|
|
|
5
5
|
/**
|
|
6
6
|
* A persisted incident - the cross-instance audit row that backs the
|
|
7
7
|
* "Incidents" view. The same incident is also available in
|
|
8
|
-
* `BpmnInstanceState.incidents` while it is
|
|
8
|
+
* `BpmnInstanceState.incidents` while it is open and the instance runs. The
|
|
9
9
|
* persisted row additionally carries `raisedAt` / `resolvedAt` /
|
|
10
10
|
* `resolvedBy` and the parent process metadata so it can be listed and
|
|
11
11
|
* filtered without joining back to the instance.
|
|
@@ -13,23 +13,15 @@
|
|
|
13
13
|
*/
|
|
14
14
|
export type BpmnIncidentRecord = {
|
|
15
15
|
/**
|
|
16
|
-
*
|
|
17
|
-
*/
|
|
18
|
-
id: string;
|
|
19
|
-
/**
|
|
20
|
-
* Engine-assigned incident identifier, unique within the workflow.
|
|
16
|
+
* Engine-assigned incident identifier, unique within the instance. Resolve the incident with it.
|
|
21
17
|
*/
|
|
22
18
|
incidentID: string;
|
|
23
19
|
/**
|
|
24
20
|
* Identifier of the instance that produced the incident.
|
|
25
21
|
*/
|
|
26
|
-
|
|
27
|
-
/**
|
|
28
|
-
* ID of the process definition the instance is running. May be absent when the source definition was deleted.
|
|
29
|
-
*/
|
|
30
|
-
definitionID?: string;
|
|
22
|
+
instanceID: string;
|
|
31
23
|
/**
|
|
32
|
-
* BPMN process ID of the
|
|
24
|
+
* BPMN process ID of the definition the instance is running.
|
|
33
25
|
*/
|
|
34
26
|
processID?: string;
|
|
35
27
|
/**
|
|
@@ -81,7 +73,7 @@ export type BpmnIncidentRecord = {
|
|
|
81
73
|
*/
|
|
82
74
|
resolvedAt?: string;
|
|
83
75
|
/**
|
|
84
|
-
*
|
|
76
|
+
* User or service account that resolved the incident. Empty for engine-internal resolves (boundary catches, modification cancel) and for open incidents.
|
|
85
77
|
*/
|
|
86
78
|
resolvedBy?: string;
|
|
87
79
|
};
|
|
@@ -91,19 +83,19 @@ export namespace BpmnIncidentRecord {
|
|
|
91
83
|
*/
|
|
92
84
|
export enum errorType {
|
|
93
85
|
BPMN_ERROR = 'BpmnError',
|
|
94
|
-
ESCALATION_ERROR = 'EscalationError',
|
|
95
86
|
COMPENSATION_ERROR = 'CompensationError',
|
|
96
87
|
FEEL_ERROR = 'FeelError',
|
|
97
|
-
NO_HANDLER = 'NoHandler',
|
|
98
88
|
GATEWAY_NO_MATCH = 'GatewayNoMatch',
|
|
99
89
|
TIMER_RESOLUTION = 'TimerResolution',
|
|
100
90
|
LINK_NOT_FOUND = 'LinkNotFound',
|
|
101
91
|
MIGRATION_ERROR = 'MigrationError',
|
|
102
|
-
SUBSCRIPTION_ERROR = 'SubscriptionError',
|
|
103
|
-
ROTATION_LIMIT_ERROR = 'RotationLimitError',
|
|
104
|
-
SNAPSHOT_SIZE_EXCEEDED = 'SnapshotSizeExceeded',
|
|
105
92
|
CALL_ACTIVITY_CANCELED = 'CallActivityCanceled',
|
|
106
93
|
EXTERNAL_ROW_REFRESH_ERROR = 'ExternalRowRefreshError',
|
|
94
|
+
JOB_LOCK_LOST = 'JobLockLost',
|
|
95
|
+
DECISION_NOT_FOUND = 'DecisionNotFound',
|
|
96
|
+
DECISION_EVALUATION_ERROR = 'DecisionEvaluationError',
|
|
97
|
+
PROCESS_NOT_FOUND = 'ProcessNotFound',
|
|
98
|
+
PROCESS_SUSPENDED = 'ProcessSuspended',
|
|
107
99
|
UNKNOWN = 'Unknown',
|
|
108
100
|
}
|
|
109
101
|
}
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
5
5
|
import type { BpmnIncidentRecord } from './BpmnIncidentRecord';
|
|
6
|
-
import type {
|
|
6
|
+
import type { CursorPage } from './CursorPage';
|
|
7
7
|
/**
|
|
8
8
|
* Page of persisted incidents.
|
|
9
9
|
*/
|
|
10
10
|
export type BpmnIncidentRecordPaginatedResponse = {
|
|
11
11
|
data: Array<BpmnIncidentRecord>;
|
|
12
|
-
pagination:
|
|
12
|
+
pagination: CursorPage;
|
|
13
13
|
};
|
|
14
14
|
|
|
@@ -2,26 +2,20 @@
|
|
|
2
2
|
/* istanbul ignore file */
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
5
|
+
import type { BpmnInstanceStatus } from './BpmnInstanceStatus';
|
|
5
6
|
/**
|
|
6
7
|
* A running or completed execution of a BPMN process.
|
|
7
8
|
*/
|
|
8
9
|
export type BpmnInstance = {
|
|
9
10
|
/**
|
|
10
|
-
*
|
|
11
|
+
* Identifier of this instance. Use it to address the instance in all API calls - fetch state, send signals/messages, complete user tasks, list children, cancel, etc.
|
|
11
12
|
*/
|
|
12
|
-
|
|
13
|
+
instanceID: string;
|
|
13
14
|
/**
|
|
14
|
-
*
|
|
15
|
+
* Identifier of the parent instance that started this one via a CallActivity. Empty for top-level instances.
|
|
15
16
|
*/
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
* Execution identifier of the parent instance that started this one via a CallActivity. Empty for top-level instances.
|
|
19
|
-
*/
|
|
20
|
-
parentWorkflowID?: string;
|
|
21
|
-
/**
|
|
22
|
-
* Current lifecycle status of the instance.
|
|
23
|
-
*/
|
|
24
|
-
status: BpmnInstance.status;
|
|
17
|
+
parentInstanceID?: string;
|
|
18
|
+
status: BpmnInstanceStatus;
|
|
25
19
|
/**
|
|
26
20
|
* User or service account that initiated the instance.
|
|
27
21
|
*/
|
|
@@ -38,6 +32,10 @@ export type BpmnInstance = {
|
|
|
38
32
|
* True when at least one unresolved incident is currently attached to this instance. Computed at query time against the open-incidents index - useful for rendering a "needs attention" indicator in instance lists without paying for a per-row state fetch from the engine.
|
|
39
33
|
*/
|
|
40
34
|
hasIncident?: boolean;
|
|
35
|
+
/**
|
|
36
|
+
* True for a test run, see `StartBpmnTestInstance`.
|
|
37
|
+
*/
|
|
38
|
+
draft?: boolean;
|
|
41
39
|
/**
|
|
42
40
|
* Timestamp at which this instance was paused at INSTANCE scope. Empty
|
|
43
41
|
* when not instance-suspended. The instance may still be effectively
|
|
@@ -61,34 +59,28 @@ export type BpmnInstance = {
|
|
|
61
59
|
*
|
|
62
60
|
*/
|
|
63
61
|
definitionSuspended?: boolean;
|
|
62
|
+
/**
|
|
63
|
+
* True when an instance above this running call-activity child in the
|
|
64
|
+
* call chain is paused, which pauses this one too. It clears when that
|
|
65
|
+
* instance is resumed.
|
|
66
|
+
*
|
|
67
|
+
*/
|
|
68
|
+
parentSuspended?: boolean;
|
|
64
69
|
/**
|
|
65
70
|
* Caller-supplied correlation key set when the instance was started. Inherited unchanged on child instances spawned via CallActivity.
|
|
66
71
|
*/
|
|
67
72
|
businessId?: string;
|
|
68
73
|
/**
|
|
69
|
-
* BPMN process ID of the definition this instance was started from. Together with `processVersion` it addresses the version
|
|
74
|
+
* BPMN process ID of the definition this instance was started from. Together with `processVersion` it addresses the version.
|
|
70
75
|
*/
|
|
71
|
-
processId
|
|
76
|
+
processId: string;
|
|
72
77
|
/**
|
|
73
78
|
* Human-readable name of that process definition.
|
|
74
79
|
*/
|
|
75
80
|
processName?: string;
|
|
76
81
|
/**
|
|
77
|
-
* Version of the process definition this instance was started from.
|
|
82
|
+
* Version of the process definition this instance was started from. 0 on a test run, which runs no deployed version.
|
|
78
83
|
*/
|
|
79
|
-
processVersion
|
|
84
|
+
processVersion: number;
|
|
80
85
|
};
|
|
81
|
-
export namespace BpmnInstance {
|
|
82
|
-
/**
|
|
83
|
-
* Current lifecycle status of the instance.
|
|
84
|
-
*/
|
|
85
|
-
export enum status {
|
|
86
|
-
RUNNING = 'RUNNING',
|
|
87
|
-
COMPLETED = 'COMPLETED',
|
|
88
|
-
FAILED = 'FAILED',
|
|
89
|
-
CANCELED = 'CANCELED',
|
|
90
|
-
TERMINATED = 'TERMINATED',
|
|
91
|
-
TIMED_OUT = 'TIMED_OUT',
|
|
92
|
-
}
|
|
93
|
-
}
|
|
94
86
|
|
|
@@ -3,12 +3,12 @@
|
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
5
5
|
import type { BpmnInstance } from './BpmnInstance';
|
|
6
|
-
import type {
|
|
6
|
+
import type { CursorPage } from './CursorPage';
|
|
7
7
|
/**
|
|
8
8
|
* Page of BPMN process instances.
|
|
9
9
|
*/
|
|
10
10
|
export type BpmnInstancePaginatedResponse = {
|
|
11
11
|
data: Array<BpmnInstance>;
|
|
12
|
-
pagination:
|
|
12
|
+
pagination: CursorPage;
|
|
13
13
|
};
|
|
14
14
|
|
|
@@ -3,24 +3,31 @@
|
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
5
5
|
import type { ActiveScope } from './ActiveScope';
|
|
6
|
+
import type { BpmnElementStatistics } from './BpmnElementStatistics';
|
|
6
7
|
import type { BpmnIncident } from './BpmnIncident';
|
|
8
|
+
import type { BpmnInstanceStatus } from './BpmnInstanceStatus';
|
|
9
|
+
import type { JoinArrivals } from './JoinArrivals';
|
|
7
10
|
import type { SuspensionEntry } from './SuspensionEntry';
|
|
8
11
|
/**
|
|
9
12
|
* Full runtime state of a BPMN process instance.
|
|
10
13
|
*/
|
|
11
14
|
export type BpmnInstanceState = {
|
|
12
15
|
/**
|
|
13
|
-
* ID of the BPMN resource
|
|
16
|
+
* ID of the BPMN resource the instance's process version was deployed from. Empty for a version deployed from no resource.
|
|
14
17
|
*/
|
|
15
|
-
resourceID
|
|
18
|
+
resourceID?: string;
|
|
16
19
|
/**
|
|
17
|
-
*
|
|
20
|
+
* Identifier of this instance.
|
|
18
21
|
*/
|
|
19
|
-
|
|
22
|
+
instanceID: string;
|
|
20
23
|
/**
|
|
21
|
-
*
|
|
24
|
+
* Identifier of the parent instance that started this one via a CallActivity. Empty for top-level instances.
|
|
22
25
|
*/
|
|
23
|
-
|
|
26
|
+
parentInstanceID?: string;
|
|
27
|
+
/**
|
|
28
|
+
* User or service account that started the instance. For an instance a message or signal started, its publisher. Empty for a timer start or a call-activity child.
|
|
29
|
+
*/
|
|
30
|
+
startedBy?: string;
|
|
24
31
|
/**
|
|
25
32
|
* BPMN process definition ID this instance was started from.
|
|
26
33
|
*/
|
|
@@ -29,20 +36,26 @@ export type BpmnInstanceState = {
|
|
|
29
36
|
* Version of the BPMN process definition this instance is currently running. Updated by migration operations.
|
|
30
37
|
*/
|
|
31
38
|
processVersion?: number;
|
|
32
|
-
|
|
33
|
-
* Current lifecycle status of the instance (e.g. RUNNING, COMPLETED, FAILED, TERMINATED).
|
|
34
|
-
*/
|
|
35
|
-
status?: string;
|
|
39
|
+
status?: BpmnInstanceStatus;
|
|
36
40
|
/**
|
|
37
41
|
* All variables currently in scope for the root process.
|
|
38
42
|
*/
|
|
39
43
|
variables?: Record<string, any>;
|
|
40
44
|
/**
|
|
41
|
-
* True when the instance has an unresolved incident.
|
|
45
|
+
* True when the instance failed or has an unresolved incident.
|
|
42
46
|
*/
|
|
43
47
|
error?: boolean;
|
|
44
48
|
/**
|
|
45
|
-
*
|
|
49
|
+
* True for a test run, see `StartBpmnTestInstance`. Messages and signals
|
|
50
|
+
* reach it under their names with the `draft:` prefix.
|
|
51
|
+
*
|
|
52
|
+
*/
|
|
53
|
+
draft?: boolean;
|
|
54
|
+
/**
|
|
55
|
+
* Active incidents that require resolution before the process can
|
|
56
|
+
* continue. Empty once the instance has finished: the incident list keeps
|
|
57
|
+
* each one with `resolvedBy` set to `system:<status>`.
|
|
58
|
+
*
|
|
46
59
|
*/
|
|
47
60
|
incidents?: Array<BpmnIncident>;
|
|
48
61
|
/**
|
|
@@ -50,14 +63,14 @@ export type BpmnInstanceState = {
|
|
|
50
63
|
*/
|
|
51
64
|
activeScopes?: Array<ActiveScope>;
|
|
52
65
|
/**
|
|
53
|
-
* Error message
|
|
66
|
+
* Error message of the instance when status is FAILED.
|
|
54
67
|
*/
|
|
55
68
|
failureReason?: string;
|
|
56
69
|
/**
|
|
57
70
|
* Present when this instance has been explicitly suspended by an
|
|
58
|
-
* operator.
|
|
59
|
-
*
|
|
60
|
-
*
|
|
71
|
+
* operator. Clear via the resume instance endpoint. Composes with
|
|
72
|
+
* `definitionSuspension` - both must be null for the instance to
|
|
73
|
+
* dispatch tokens.
|
|
61
74
|
*
|
|
62
75
|
*/
|
|
63
76
|
instanceSuspension?: SuspensionEntry;
|
|
@@ -68,6 +81,26 @@ export type BpmnInstanceState = {
|
|
|
68
81
|
*
|
|
69
82
|
*/
|
|
70
83
|
definitionSuspension?: SuspensionEntry;
|
|
84
|
+
/**
|
|
85
|
+
* Present on a call-activity child while an instance above it in the
|
|
86
|
+
* call chain is suspended, carrying that suspension. It clears when that
|
|
87
|
+
* instance is resumed. A suspension of the child itself stays until the
|
|
88
|
+
* child is resumed.
|
|
89
|
+
*
|
|
90
|
+
*/
|
|
91
|
+
parentSuspension?: SuspensionEntry;
|
|
92
|
+
/**
|
|
93
|
+
* Joins still waiting to fire, with the flows that have reached them.
|
|
94
|
+
*/
|
|
95
|
+
pendingJoinArrivals?: Array<JoinArrivals>;
|
|
96
|
+
/**
|
|
97
|
+
* The whole history summarised per element ID, so a diagram can show what each element did without reading the history.
|
|
98
|
+
*/
|
|
99
|
+
elementStatistics?: Record<string, BpmnElementStatistics>;
|
|
100
|
+
/**
|
|
101
|
+
* Sequence flows a token has taken, by flow ID.
|
|
102
|
+
*/
|
|
103
|
+
takenFlows?: Array<string>;
|
|
71
104
|
/**
|
|
72
105
|
* Caller-supplied correlation key set when the instance was started.
|
|
73
106
|
*/
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/* generated using openapi-typescript-codegen -- do not edit */
|
|
2
|
+
/* istanbul ignore file */
|
|
3
|
+
/* tslint:disable */
|
|
4
|
+
/* eslint-disable */
|
|
5
|
+
/**
|
|
6
|
+
* Current lifecycle status of the instance.
|
|
7
|
+
*/
|
|
8
|
+
export enum BpmnInstanceStatus {
|
|
9
|
+
RUNNING = 'RUNNING',
|
|
10
|
+
COMPLETED = 'COMPLETED',
|
|
11
|
+
FAILED = 'FAILED',
|
|
12
|
+
CANCELED = 'CANCELED',
|
|
13
|
+
TERMINATED = 'TERMINATED',
|
|
14
|
+
}
|
|
@@ -3,13 +3,9 @@
|
|
|
3
3
|
/* tslint:disable */
|
|
4
4
|
/* eslint-disable */
|
|
5
5
|
/**
|
|
6
|
-
* A
|
|
6
|
+
* A deployed process version from a BPMN resource. `processID` and `version` address it.
|
|
7
7
|
*/
|
|
8
8
|
export type BpmnProcessDefinition = {
|
|
9
|
-
/**
|
|
10
|
-
* Platform identifier of this process definition. Used as `processDefinitionID` when starting instances.
|
|
11
|
-
*/
|
|
12
|
-
id: string;
|
|
13
9
|
/**
|
|
14
10
|
* Platform identifier of the owning BPMN resource.
|
|
15
11
|
*/
|
|
@@ -30,6 +26,10 @@ export type BpmnProcessDefinition = {
|
|
|
30
26
|
* Timestamp when this version became available.
|
|
31
27
|
*/
|
|
32
28
|
createdAt: string;
|
|
29
|
+
/**
|
|
30
|
+
* User or service account that deployed this version.
|
|
31
|
+
*/
|
|
32
|
+
deployedBy?: string;
|
|
33
33
|
/**
|
|
34
34
|
* Timestamp at which this process definition was paused. Empty when active.
|
|
35
35
|
*/
|