Link request node

I am often using a pattern where my flow will branch out to a linked process as shown in the screenshot below. It could be nice if the 2 links between Request and Result could actually be a Link Request node (that would be configured with a link out and link in node). Anyone using a similar pattern ?

You could make you function into a subflow then I think that gives exactly what you want. Unless I don't understand the requirement.

Hi @nlecaude

Yes, a 'Link Call' node is planned. It will be able to call a Link In node and when the message reaches a Link Out node, it will return to whichever Link Call node it came from.

There are some parallels to the Subflow concept and there will be plenty of cases where you could use either approach.

But there is an important difference between the approaches.

  • Adding multiple subflow instances will give you separate instances of the nodes - each with its own context etc.

  • The Link-Call node would allow you to call out to a single concrete instance of the nodes from multiple places - so any state would be common.

This new node is at the very early drawing board stage - quite literally, drawing various ideas of what it would look like in the editor to maintain the 'link' wires appearance coming in and out of the middle of the node.

4 Likes

This 'Link Call' node sounds like a great idea. I've been using link nodes quite regularly to separate different modules of the application and help keep the main flows clean and easier to read. In most of these cases, subflows weren't an alternative because of their instance scopes.

Very much looking forward to this!

Thanks! Good to know it's on the roadmap ! To answer @Colin as @knolleary mentioned I use these patterns when the processing part is global and needs to keep state. Also often the processing section will process messages coming from multiple places.

The link in/out nodes sound a like a great idea, and I hope you can keep the implementation visually and conceptually simple. The concept seems similar to that of node-red-contrib-actionflows, but I never actually tried those nodes -- the description is so complex that it frightened me off.

I actually used actionflows, however they're not exactly the same concept.
They allow to add a 'placeholder' node in your flow and later add any number of processing implementations for it, based on the name assigned. So it's like a call link, but you introduce implementations by name, even multiple ones with priorities defining the processing order.