@5minds/node-red-contrib-processcube 1.1.5-develop-ea4932-m1aok5mh → 1.2.0-develop-268bee-m1xd03z9

Sign up to get free protection for your applications and to get access to all the features.
@@ -22,6 +22,8 @@ module.exports = function (RED) {
22
22
  msg.errorCode = config.error;
23
23
  msg.errorMessage = msgError.message;
24
24
 
25
+ node.log(`handle-${flowNodeInstanceId}: *flowNodeInstanceId* '${flowNodeInstanceId}' with *msg._msgid* '${msg._msgid}'`);
26
+
25
27
  eventEmitter.emit(`handle-${flowNodeInstanceId}`, error, true);
26
28
 
27
29
  node.send(msg);
@@ -47,7 +47,7 @@ module.exports = function (RED) {
47
47
  let result = RED.util.encodeObject(msg.payload);
48
48
 
49
49
  node.log(
50
- `handle event for *external task flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* ${externalTask.processInstanceId} with result ${result} on msg._msgid ${msg._msgid}.`,
50
+ `handle finish task *flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* ${externalTask.processInstanceId} with result ${result} on msg._msgid ${msg._msgid}.`,
51
51
  );
52
52
 
53
53
  if (externalTask.flowNodeInstanceId) {
@@ -62,7 +62,7 @@ module.exports = function (RED) {
62
62
 
63
63
  const handleErrorTask = (msg) => {
64
64
  node.log(
65
- `handle error event for *external task flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* '${externalTask.processInstanceId}' on *msg._msgid* '${msg._msgid}'.`,
65
+ `handle error task *flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* '${externalTask.processInstanceId}' on *msg._msgid* '${msg._msgid}'.`,
66
66
  );
67
67
 
68
68
  if (externalTask.flowNodeInstanceId) {
@@ -80,7 +80,7 @@ module.exports = function (RED) {
80
80
 
81
81
  eventEmitter.once(`handle-${externalTask.flowNodeInstanceId}`, (msg, isError = false) => {
82
82
  node.log(
83
- `handle event for *external task flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* '${externalTask.processInstanceId}' with *msg._msgid* '${msg._msgid}' and *isError* '${isError}'`,
83
+ `handle-${externalTask.flowNodeInstanceId}: *flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* '${externalTask.processInstanceId}' with *msg._msgid* '${msg._msgid}' and *isError* '${isError}'`,
84
84
  );
85
85
 
86
86
  if (isError) {
@@ -99,10 +99,11 @@ module.exports = function (RED) {
99
99
  task: RED.util.encodeObject(externalTask),
100
100
  payload: payload,
101
101
  flowNodeInstanceId: externalTask.flowNodeInstanceId,
102
+ processInstanceId: externalTask.processInstanceId
102
103
  };
103
104
 
104
105
  node.log(
105
- `Received *external task flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* '${externalTask.processInstanceId}' with *msg._msgid* '${msg._msgid}'`,
106
+ `new task *flowNodeInstanceId* '${externalTask.flowNodeInstanceId}' and *processInstanceId* '${externalTask.processInstanceId}' with *msg._msgid* '${msg._msgid}'`,
106
107
  );
107
108
 
108
109
  node.send(msg);
@@ -13,9 +13,14 @@ module.exports = function (RED) {
13
13
 
14
14
  node.on('input', function (msg) {
15
15
  const flowNodeInstanceId = msg.flowNodeInstanceId;
16
+ const processInstanceId = msg.processInstanceId;
16
17
 
17
18
  if (!flowNodeInstanceId) {
18
19
  node.error('Error: The message did not contain the required external task id.', msg);
20
+ } else {
21
+ node.log(
22
+ `handle-${flowNodeInstanceId}: *flowNodeInstanceId* '${flowNodeInstanceId}' and *processInstanceId* '${processInstanceId}' with *msg._msgid* '${msg._msgid}'`,
23
+ );
19
24
  }
20
25
 
21
26
  eventEmitter.emit(`handle-${flowNodeInstanceId}`, msg, false);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@5minds/node-red-contrib-processcube",
3
- "version": "1.1.5-develop-ea4932-m1aok5mh",
3
+ "version": "1.2.0-develop-268bee-m1xd03z9",
4
4
  "license": "MIT",
5
5
  "description": "Node-RED nodes for ProcessCube",
6
6
  "scripts": {
@@ -57,7 +57,7 @@
57
57
  "examples": "examples"
58
58
  },
59
59
  "dependencies": {
60
- "@5minds/processcube_engine_client": "^5.0.1",
60
+ "@5minds/processcube_engine_client": "^5.0.2",
61
61
  "jwt-decode": "^4.0.0",
62
62
  "openid-client": "^5.5.0"
63
63
  },