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
FR: core nodes to permit input and output to properties other than the hard coded payload #4651
Comments
adapted from google Doc shared by @dceejay for markdown Adding configurable output field to core nodesD-C-J, SMcLThis is a quick think-list about the core nodes that could possibly benefit from having a configurable output property - rather than always setting Basic AssumptionIt only really needs to apply to nodes that have an input and output, as This reduces the list to 22 possible nodes out of 43 core nodes we install. So by no means all, so no need for some generic solution. List of core nodes with input and output
ConclusionOut of 22 I/O nodes I think 1 definite candidate (http request), 8 would possibly make sense, 9 don’t need modification, 2 potentially, and 2 allow setting already. So 11 don’t need modification, Of the remaining 11 Of these I think the higher priority ones are http request, exec, join, and then xml, json and yaml (I.E. the parsers - with CSV being fixed as part of making it RFC compliant. Finally we should possibly let the split node specify the input property to split on Other Thoughts
So a general node would be like
Migration considerationCurrently several nodes already allow setting the input property… and if you do so they use that as the output property also… so we need to think about migration… I think two options
In both cases default for input would be payload - and thus so would output. |
A Draft PR implementing the majority of Dave's suggestions was raised in #4656 Below are screenshots of before and after for evaluation and agreement before I proceed with tests and doc updates. Notes:
CSV
JSON
YAML
XML
RANGE
FILE
HTTP REQUEST
TEMPLATE
|
Added/updated unit test specific to these changes
|
Looking good so far ! Great work |
Discussed and triaged with @dceejay but again, i am failing to find the supporting information. Dave listed out all the nodes where this made sense. I will update this once I locate the preparations/supporting discussion.
The PR proposes that, where it makes sense, we permit the input and output property to be user configurable.
It was determined this would be strictly a
msg.xyz
only option as this simplifies implementation and promotes the use ofmsg
properties (over context or other potentially mutating values)The aim is to reduce friction when flows are made in a serial fashion whereby users are not aware they can move or copy the
payload
to an alternatemsg
property (using change nodes). The first instinct many users seem to apply is to store the payload in context and then pick this up at the end of the flow. This leads to subtle timing bugs when messages flow in quick succession and async operations are involved.The text was updated successfully, but these errors were encountered: