-
Notifications
You must be signed in to change notification settings - Fork 160
Specification and Using multiple Data filters section: Error in Workflow definition ? #630
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Yeah, it sounds like a bug. In the writing, it is stated:
And the action arguments are expecting {
"actions":[
{
"functionRef":{
"refName":"greetingFunction",
"arguments":{
"greeting":"${ .hello.spanish } ",
"customerName":"${ .customerInfo.name } "
}
},
"actionDataFilter":{
"fromStateData":"${ { hello, customerInfo } }",
"results":"${ .greetingMessageResult }",
"toStateData":"${ .finalCustomerGreeting }"
}
}
]
} additional brackets added for GH formmating |
I will provide a PR then for the fix I saw also some other small issues in the doc that I will correct in the same PR, if you are ok with that> |
I think this should be ${ { hello, customerInfo } } as the event payload would be applied to state data first But then this would be the same thing as the current state data when action filter is applied, so think just remove fromStateData in the action filter is better in this case |
Not necessarily. I think the filter example is fine, and the |
https://github.com/serverlessworkflow/specification/blob/v0.8/specification.md#using-multiple-data-filters (same on
main
)Event action is calling greeint function:
We have the action data filter using the
"fromStateData": "${ .hello }",
which means the data for the action is
How is that possible that we use the
customerInfo
data into the function arguments, whereas, AFAIU, it is not in the current data for the action ?The text was updated successfully, but these errors were encountered: