@nanobpm/engine-wasm 0.9.3 → 0.11.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 +8 -6
- package/lean/nanobpmn_engine.d.ts +12 -10
- package/lean/nanobpmn_engine.js +12 -10
- package/lean/nanobpmn_engine_bg.wasm +0 -0
- package/package.json +1 -1
- package/readmodel/nanobpmn_engine.d.ts +12 -10
- package/readmodel/nanobpmn_engine.js +12 -10
- package/readmodel/nanobpmn_engine_bg.wasm +0 -0
- package/readmodel-types/types.gen.d.ts +12870 -8218
package/README.md
CHANGED
|
@@ -68,7 +68,7 @@ variablesJson)` evaluates a deployed decision standalone.
|
|
|
68
68
|
|
|
69
69
|
`activateJobs(type, maxJobs, timeoutMs, worker, withLease?)` defaults to nonleasing
|
|
70
70
|
for **every** job kind and agent marker. Activated jobs always contain
|
|
71
|
-
`
|
|
71
|
+
`jobLeaseToken`: `null` without a lease, otherwise an opaque string. Never parse it
|
|
72
72
|
as a number. Once a job is leased, subsequent activations must also opt in;
|
|
73
73
|
nonleasing workers skip it after failures and timeouts.
|
|
74
74
|
|
|
@@ -79,14 +79,16 @@ a supplied stale value is rejected. Timeout updates accept signed millisecond
|
|
|
79
79
|
durations; zero and negative updates make the activation immediately eligible for
|
|
80
80
|
expiry on the next clock tick without discarding its current lease.
|
|
81
81
|
|
|
82
|
-
Agent APIs follow the vendored stable/8.10 contract
|
|
82
|
+
Agent APIs follow the vendored stable/8.10 contract. Requests take `jobLeaseToken`
|
|
83
|
+
(the Camunda 8.10 name); the pre-8.10 name `jobLease` is still accepted as a
|
|
84
|
+
deprecated alias (#1283):
|
|
83
85
|
|
|
84
|
-
- `createAgentInstance(JSON.stringify({elementInstanceKey, jobKey,
|
|
85
|
-
requires nonempty history establishing CONFIGURATION. `
|
|
86
|
-
job's `
|
|
86
|
+
- `createAgentInstance(JSON.stringify({elementInstanceKey, jobKey, jobLeaseToken, history}))`
|
|
87
|
+
requires nonempty history establishing CONFIGURATION. `jobLeaseToken` is the activated
|
|
88
|
+
job's `jobLeaseToken`, unchanged. Definition, limits, tools, and metrics are history
|
|
87
89
|
fields, not top-level request properties.
|
|
88
90
|
- `updateAgentInstance(agentInstanceKey, JSON.stringify({elementInstanceKey, jobKey,
|
|
89
|
-
|
|
91
|
+
jobLeaseToken, status?, history?}))` requires all three attribution fields even without
|
|
90
92
|
history.
|
|
91
93
|
- Both return canonical results containing positionally correlated `createdHistory`;
|
|
92
94
|
CREATE also returns `agentInstanceKey`. Duplicate CREATE rejects rather than upserting.
|
|
@@ -88,7 +88,7 @@ export class TestEngine {
|
|
|
88
88
|
*/
|
|
89
89
|
correlateMessage(message_name: string, correlation_key: string, variables_json: string): string;
|
|
90
90
|
/**
|
|
91
|
-
* Create an agent using `{ elementInstanceKey, jobKey,
|
|
91
|
+
* Create an agent using `{ elementInstanceKey, jobKey, jobLeaseToken, history }`.
|
|
92
92
|
* History must establish its CONFIGURATION. Returns the canonical creation
|
|
93
93
|
* result with `agentInstanceKey` and positionally correlated `createdHistory`.
|
|
94
94
|
*/
|
|
@@ -192,14 +192,16 @@ export class TestEngine {
|
|
|
192
192
|
deployResource(resource_name: string, content: string): string;
|
|
193
193
|
/**
|
|
194
194
|
* Evaluate a deployed decision by id against the given variables — the
|
|
195
|
-
* standalone counterpart to a business rule task's in-line evaluation
|
|
196
|
-
*
|
|
197
|
-
*
|
|
198
|
-
*
|
|
199
|
-
*
|
|
200
|
-
* `
|
|
201
|
-
*
|
|
202
|
-
*
|
|
195
|
+
* standalone counterpart to a business rule task's in-line evaluation (the
|
|
196
|
+
* engine's `EvaluateDecision` command, exactly as the gateway runs it). The
|
|
197
|
+
* decision must already be deployed (via `deploy`/`deployDecision`). The
|
|
198
|
+
* evaluation is recorded as a decision instance with its own minted
|
|
199
|
+
* `decisionEvaluationKey` and no process instance — a failed one too
|
|
200
|
+
* (Zeebe parity, #1292). `variables_json` is a JSON object string (`"{}"` /
|
|
201
|
+
* `""` for none). Returns
|
|
202
|
+
* `{ "decisionId": ..., "decisionKey": ..., "decisionEvaluationKey": ..., "output": <value> }`
|
|
203
|
+
* on success, or throws a JS error carrying an "unknown decision" or
|
|
204
|
+
* evaluation-failure message.
|
|
203
205
|
*/
|
|
204
206
|
evaluateDecision(decision_id: string, variables_json: string): string;
|
|
205
207
|
/**
|
|
@@ -288,7 +290,7 @@ export class TestEngine {
|
|
|
288
290
|
*/
|
|
289
291
|
unassignUserTask(user_task_key: string): string;
|
|
290
292
|
/**
|
|
291
|
-
* Update an agent with `{ elementInstanceKey, jobKey,
|
|
293
|
+
* Update an agent with `{ elementInstanceKey, jobKey, jobLeaseToken, status?, history? }`.
|
|
292
294
|
* Configuration and metrics are submitted through history, never top-level fields.
|
|
293
295
|
* Returns `createdHistory`; the engine owns pending/commit/discard semantics.
|
|
294
296
|
*/
|
package/lean/nanobpmn_engine.js
CHANGED
|
@@ -400,7 +400,7 @@ export class TestEngine {
|
|
|
400
400
|
}
|
|
401
401
|
}
|
|
402
402
|
/**
|
|
403
|
-
* Create an agent using `{ elementInstanceKey, jobKey,
|
|
403
|
+
* Create an agent using `{ elementInstanceKey, jobKey, jobLeaseToken, history }`.
|
|
404
404
|
* History must establish its CONFIGURATION. Returns the canonical creation
|
|
405
405
|
* result with `agentInstanceKey` and positionally correlated `createdHistory`.
|
|
406
406
|
* @param {string} request_json
|
|
@@ -764,14 +764,16 @@ export class TestEngine {
|
|
|
764
764
|
}
|
|
765
765
|
/**
|
|
766
766
|
* Evaluate a deployed decision by id against the given variables — the
|
|
767
|
-
* standalone counterpart to a business rule task's in-line evaluation
|
|
768
|
-
*
|
|
769
|
-
*
|
|
770
|
-
*
|
|
771
|
-
*
|
|
772
|
-
* `
|
|
773
|
-
*
|
|
774
|
-
*
|
|
767
|
+
* standalone counterpart to a business rule task's in-line evaluation (the
|
|
768
|
+
* engine's `EvaluateDecision` command, exactly as the gateway runs it). The
|
|
769
|
+
* decision must already be deployed (via `deploy`/`deployDecision`). The
|
|
770
|
+
* evaluation is recorded as a decision instance with its own minted
|
|
771
|
+
* `decisionEvaluationKey` and no process instance — a failed one too
|
|
772
|
+
* (Zeebe parity, #1292). `variables_json` is a JSON object string (`"{}"` /
|
|
773
|
+
* `""` for none). Returns
|
|
774
|
+
* `{ "decisionId": ..., "decisionKey": ..., "decisionEvaluationKey": ..., "output": <value> }`
|
|
775
|
+
* on success, or throws a JS error carrying an "unknown decision" or
|
|
776
|
+
* evaluation-failure message.
|
|
775
777
|
* @param {string} decision_id
|
|
776
778
|
* @param {string} variables_json
|
|
777
779
|
* @returns {string}
|
|
@@ -1226,7 +1228,7 @@ export class TestEngine {
|
|
|
1226
1228
|
}
|
|
1227
1229
|
}
|
|
1228
1230
|
/**
|
|
1229
|
-
* Update an agent with `{ elementInstanceKey, jobKey,
|
|
1231
|
+
* Update an agent with `{ elementInstanceKey, jobKey, jobLeaseToken, status?, history? }`.
|
|
1230
1232
|
* Configuration and metrics are submitted through history, never top-level fields.
|
|
1231
1233
|
* Returns `createdHistory`; the engine owns pending/commit/discard semantics.
|
|
1232
1234
|
* @param {string} agent_instance_key
|
|
Binary file
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nanobpm/engine-wasm",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.11.0",
|
|
4
4
|
"description": "The nanobpmn engine (engine-core) compiled to WebAssembly for in-browser BPMN execution: deploy a diagram, start instances, activate/complete jobs, and read live snapshots/traces. Published as two subpath entrypoints — a lean baseline engine (default) and a read-model engine (the gateway's C8-style REST read surface). The substrate for the Bojtos demo framework (ADR 0043) and the console test-run panel.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -88,7 +88,7 @@ export class TestEngine {
|
|
|
88
88
|
*/
|
|
89
89
|
correlateMessage(message_name: string, correlation_key: string, variables_json: string): string;
|
|
90
90
|
/**
|
|
91
|
-
* Create an agent using `{ elementInstanceKey, jobKey,
|
|
91
|
+
* Create an agent using `{ elementInstanceKey, jobKey, jobLeaseToken, history }`.
|
|
92
92
|
* History must establish its CONFIGURATION. Returns the canonical creation
|
|
93
93
|
* result with `agentInstanceKey` and positionally correlated `createdHistory`.
|
|
94
94
|
*/
|
|
@@ -192,14 +192,16 @@ export class TestEngine {
|
|
|
192
192
|
deployResource(resource_name: string, content: string): string;
|
|
193
193
|
/**
|
|
194
194
|
* Evaluate a deployed decision by id against the given variables — the
|
|
195
|
-
* standalone counterpart to a business rule task's in-line evaluation
|
|
196
|
-
*
|
|
197
|
-
*
|
|
198
|
-
*
|
|
199
|
-
*
|
|
200
|
-
* `
|
|
201
|
-
*
|
|
202
|
-
*
|
|
195
|
+
* standalone counterpart to a business rule task's in-line evaluation (the
|
|
196
|
+
* engine's `EvaluateDecision` command, exactly as the gateway runs it). The
|
|
197
|
+
* decision must already be deployed (via `deploy`/`deployDecision`). The
|
|
198
|
+
* evaluation is recorded as a decision instance with its own minted
|
|
199
|
+
* `decisionEvaluationKey` and no process instance — a failed one too
|
|
200
|
+
* (Zeebe parity, #1292). `variables_json` is a JSON object string (`"{}"` /
|
|
201
|
+
* `""` for none). Returns
|
|
202
|
+
* `{ "decisionId": ..., "decisionKey": ..., "decisionEvaluationKey": ..., "output": <value> }`
|
|
203
|
+
* on success, or throws a JS error carrying an "unknown decision" or
|
|
204
|
+
* evaluation-failure message.
|
|
203
205
|
*/
|
|
204
206
|
evaluateDecision(decision_id: string, variables_json: string): string;
|
|
205
207
|
/**
|
|
@@ -347,7 +349,7 @@ export class TestEngine {
|
|
|
347
349
|
*/
|
|
348
350
|
unassignUserTask(user_task_key: string): string;
|
|
349
351
|
/**
|
|
350
|
-
* Update an agent with `{ elementInstanceKey, jobKey,
|
|
352
|
+
* Update an agent with `{ elementInstanceKey, jobKey, jobLeaseToken, status?, history? }`.
|
|
351
353
|
* Configuration and metrics are submitted through history, never top-level fields.
|
|
352
354
|
* Returns `createdHistory`; the engine owns pending/commit/discard semantics.
|
|
353
355
|
*/
|
|
@@ -400,7 +400,7 @@ export class TestEngine {
|
|
|
400
400
|
}
|
|
401
401
|
}
|
|
402
402
|
/**
|
|
403
|
-
* Create an agent using `{ elementInstanceKey, jobKey,
|
|
403
|
+
* Create an agent using `{ elementInstanceKey, jobKey, jobLeaseToken, history }`.
|
|
404
404
|
* History must establish its CONFIGURATION. Returns the canonical creation
|
|
405
405
|
* result with `agentInstanceKey` and positionally correlated `createdHistory`.
|
|
406
406
|
* @param {string} request_json
|
|
@@ -764,14 +764,16 @@ export class TestEngine {
|
|
|
764
764
|
}
|
|
765
765
|
/**
|
|
766
766
|
* Evaluate a deployed decision by id against the given variables — the
|
|
767
|
-
* standalone counterpart to a business rule task's in-line evaluation
|
|
768
|
-
*
|
|
769
|
-
*
|
|
770
|
-
*
|
|
771
|
-
*
|
|
772
|
-
* `
|
|
773
|
-
*
|
|
774
|
-
*
|
|
767
|
+
* standalone counterpart to a business rule task's in-line evaluation (the
|
|
768
|
+
* engine's `EvaluateDecision` command, exactly as the gateway runs it). The
|
|
769
|
+
* decision must already be deployed (via `deploy`/`deployDecision`). The
|
|
770
|
+
* evaluation is recorded as a decision instance with its own minted
|
|
771
|
+
* `decisionEvaluationKey` and no process instance — a failed one too
|
|
772
|
+
* (Zeebe parity, #1292). `variables_json` is a JSON object string (`"{}"` /
|
|
773
|
+
* `""` for none). Returns
|
|
774
|
+
* `{ "decisionId": ..., "decisionKey": ..., "decisionEvaluationKey": ..., "output": <value> }`
|
|
775
|
+
* on success, or throws a JS error carrying an "unknown decision" or
|
|
776
|
+
* evaluation-failure message.
|
|
775
777
|
* @param {string} decision_id
|
|
776
778
|
* @param {string} variables_json
|
|
777
779
|
* @returns {string}
|
|
@@ -1477,7 +1479,7 @@ export class TestEngine {
|
|
|
1477
1479
|
}
|
|
1478
1480
|
}
|
|
1479
1481
|
/**
|
|
1480
|
-
* Update an agent with `{ elementInstanceKey, jobKey,
|
|
1482
|
+
* Update an agent with `{ elementInstanceKey, jobKey, jobLeaseToken, status?, history? }`.
|
|
1481
1483
|
* Configuration and metrics are submitted through history, never top-level fields.
|
|
1482
1484
|
* Returns `createdHistory`; the engine owns pending/commit/discard semantics.
|
|
1483
1485
|
* @param {string} agent_instance_key
|
|
Binary file
|