Join/Split Nodes

331 views
Skip to first unread message

Maurizio Carboni

unread,
Feb 10, 2016, 6:36:48 AM2/10/16
to Node-RED

We have made a couple node really similar to the ones specified in this page :
https://trello.com/c/hAVvU7wT,

they are designed to be able to handle one more scenario :

1) You have an Array and you want to iterate over every single value, and continue with the flow only after all the flows generated have finished

2) You have an Object and in the flow at some point this Object is split in multiple messages and you want to continue only after  all the flows generated have finished

The node for the second case offer a numeric property where you specify the number of generated flows.


https://github.com/redconnect-io/node-red-contrib-flow-combine



Another thing : 

At the moment the split node don’t split the Array because exists already a splitter node that you can use in conjunction (I can implement this functionality really easily).

The end node don’t preserve the order (Another thing that I can implement).


We have other 2 nodes for similar situations :

Parallel Split : It’s essentially split/join in one node, where the Array is split in multiple messages and after the messages is processed, the flow needs to come back to the input of the Split node. The node have 2 outputs : one for iterate over every item of the Array and one where continue after have iterated over all the items.
https://github.com/redconnect-io/node-red-contrib-parallel-iterator

Serial Split : Same thing but each item is sent to the flow only after the previous one have finished.
https://github.com/redconnect-io/node-red-contrib-serial-iterator

Maurizio Carboni

unread,
Feb 16, 2016, 12:06:53 PM2/16/16
to Node-RED
I've changed the addon, now the Addon preserve the order of the items and can iterate over it.

jo2

unread,
May 2, 2016, 5:25:04 PM5/2/16
to Node-RED
Hi!

Thanks a lot for this node, I have started using it now instead of a handcrafted iteration flow. it seems to work great, and runs much faster too :-)

Cheers
-jo2
Reply all
Reply to author
Forward
0 new messages