bpmn-engine 23.0.2 → 24.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/lib/index.cjs CHANGED
@@ -577,7 +577,10 @@ Execution.prototype._setup = function setup(setupOptions) {
577
577
  for (const definition of this.definitions) {
578
578
  if (listener) definition.environment.options.listener = listener;
579
579
 
580
- const { queueName } = definition.broker.subscribeTmp('event', 'definition.#', onChildMessage, { noAck: true, consumerTag: '_engine_definition' });
580
+ const { queueName } = definition.broker.subscribeTmp('event', 'definition.#', onChildMessage, {
581
+ noAck: true,
582
+ consumerTag: '_engine_definition',
583
+ });
581
584
  definition.broker.bindQueue(queueName, 'event', 'process.#');
582
585
  definition.broker.bindQueue(queueName, 'event', 'activity.#');
583
586
  definition.broker.bindQueue(queueName, 'event', 'flow.#');
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "bpmn-engine",
3
3
  "description": "BPMN 2.0 execution engine. Open source javascript workflow engine.",
4
- "version": "23.0.2",
4
+ "version": "24.0.0",
5
5
  "type": "module",
6
6
  "module": "./src/index.js",
7
7
  "main": "./lib/index.cjs",
@@ -62,14 +62,14 @@
62
62
  "chronokinesis": "^6.0.0",
63
63
  "eslint": "^9.10.0",
64
64
  "markdown-toc": "^1.2.0",
65
- "mocha": "^10.2.0",
65
+ "mocha": "^11.0.1",
66
66
  "mocha-cakes-2": "^3.3.0",
67
67
  "prettier": "^3.2.5",
68
68
  "rollup": "^4.10.0",
69
69
  "texample": "^0.0.6"
70
70
  },
71
71
  "dependencies": {
72
- "bpmn-elements": "^16.2.1",
72
+ "bpmn-elements": "^17.0.0",
73
73
  "bpmn-moddle": "^9.0.1",
74
74
  "debug": "^4.3.7",
75
75
  "moddle-context-serializer": "^4.2.1"
package/src/index.js CHANGED
@@ -431,7 +431,10 @@ Execution.prototype._setup = function setup(setupOptions) {
431
431
  for (const definition of this.definitions) {
432
432
  if (listener) definition.environment.options.listener = listener;
433
433
 
434
- const { queueName } = definition.broker.subscribeTmp('event', 'definition.#', onChildMessage, { noAck: true, consumerTag: '_engine_definition' });
434
+ const { queueName } = definition.broker.subscribeTmp('event', 'definition.#', onChildMessage, {
435
+ noAck: true,
436
+ consumerTag: '_engine_definition',
437
+ });
435
438
  definition.broker.bindQueue(queueName, 'event', 'process.#');
436
439
  definition.broker.bindQueue(queueName, 'event', 'activity.#');
437
440
  definition.broker.bindQueue(queueName, 'event', 'flow.#');
@@ -3,11 +3,7 @@
3
3
 
4
4
  import { EventEmitter } from 'node:events';
5
5
  import { Definitions as BpmnModdleDefinitions } from 'bpmn-moddle';
6
- import {
7
- extendFn,
8
- SerializableContext,
9
- TypeResolver,
10
- } from 'moddle-context-serializer';
6
+ import { extendFn, SerializableContext, TypeResolver } from 'moddle-context-serializer';
11
7
  import {
12
8
  ActivityStatus,
13
9
  ElementBroker,
@@ -61,10 +57,7 @@ declare module 'bpmn-engine' {
61
57
  flow.discard: The sequence flow was discarded
62
58
  flow.looped: The sequence is looped
63
59
  */
64
- export type BpmnSequenceFlowEvent =
65
- | 'flow.take'
66
- | 'flow.discard'
67
- | 'flow.looped';
60
+ export type BpmnSequenceFlowEvent = 'flow.take' | 'flow.discard' | 'flow.looped';
68
61
 
69
62
  export interface BpmnMessage {
70
63
  id?: string;
@@ -173,10 +166,7 @@ declare module 'bpmn-engine' {
173
166
  */
174
167
  execute(): Promise<Execution>;
175
168
  execute(options: BpmnEngineExecuteOptions): Promise<Execution>;
176
- execute(
177
- options: BpmnEngineExecuteOptions,
178
- cb: (err: Error, execution?: Execution) => void
179
- ): Promise<Execution>;
169
+ execute(options: BpmnEngineExecuteOptions, cb: (err: Error, execution?: Execution) => void): Promise<Execution>;
180
170
  execute(cb: (err: Error) => void): Promise<Execution>;
181
171
 
182
172
  /**
@@ -207,10 +197,7 @@ declare module 'bpmn-engine' {
207
197
  * @param options
208
198
  * @param callback
209
199
  */
210
- resume(
211
- options?: BpmnEngineExecuteOptions,
212
- callback?: (err: Error, execution?: Execution) => void
213
- ): Promise<Execution>;
200
+ resume(options?: BpmnEngineExecuteOptions, callback?: (err: Error, execution?: Execution) => void): Promise<Execution>;
214
201
 
215
202
  /**
216
203
  * Stop execution. The instance is terminated.
@@ -320,10 +307,7 @@ declare module 'bpmn-engine' {
320
307
  * @param message {BpmnMessage}
321
308
  * @param options
322
309
  */
323
- signal(
324
- message?: BpmnMessage,
325
- options?: { ignoreSameDefinition?: boolean }
326
- ): void;
310
+ signal(message?: BpmnMessage, options?: { ignoreSameDefinition?: boolean }): void;
327
311
 
328
312
  /**
329
313
  * send cancel activity to execution, distributed to all definitions
@@ -345,9 +329,6 @@ declare module 'bpmn-engine' {
345
329
  */
346
330
  constructor(disableDummy?: boolean);
347
331
  register(activity: any): Script | undefined;
348
- getScript(
349
- language: string,
350
- identifier: { id: string; [x: string]: any }
351
- ): Script;
332
+ getScript(language: string, identifier: { id: string; [x: string]: any }): Script;
352
333
  }
353
334
  }