Service task output #218
-
Hi, do you know how to pipe one service task's output as next's input? Just like AI workflow like defy, coze. Is previous service task's output variable available in next task's input expression? And how to gather input from multiple "previous node"? |
Beta Was this translation helpful? Give feedback.
Replies: 6 comments 3 replies
-
I am not familiar with AI workflow, can you please explain? Currently this is done through scripting and use of instance |
Beta Was this translation helpful? Give feedback.
-
This works export const twServiceProvider: IServiceProvider = {
'log-console'(input: Record<string, unknown>, _execution: Execution) {
console.log('log-console service called:', input);
return {
a: 'b',
}
},
a: {
b: (input: Record<string, unknown>, execution: Execution) => {
console.log(`b is called with ${JSON.stringify(input)} and last output is ${JSON.stringify(execution.item.token.lastItem.output)}`);
},
},
}; log
|
Beta Was this translation helpful? Give feedback.
-
Another question is what does the output on the panel mean? I didn't see where it is used in the So does the input in the panel. And exclusive gateway's expression, where does the variable comes from? https://docs.camunda.io/docs/components/concepts/workflow-patterns/#conditions-ifthen I simply want to create something like defi and coze. |
Beta Was this translation helpful? Give feedback.
-
I really like to know what does defi and coze do?? in bpmn-server, output variable is what is returned from the activity into item.output |
Beta Was this translation helpful? Give feedback.
-
There are two problems with the above solution execution.item.token.lastItem.output
So a more sure solution is using |
Beta Was this translation helpful? Give feedback.
-
In addition to above, Release 2.2.10, stores Thanks |
Beta Was this translation helpful? Give feedback.
In addition to above, Release 2.2.10, stores
item.output
so you can search back for the item and get its output.Thanks