Multiple catch nodes

I have a flow similar to the attached one where I want to keep an infinite loop doing some stuff related to HTTP requests. It's important to notice that there's just one inject operation at start.

What happens if you have one catch node for a specific node (HTTP request) and a global catch? I mean, which one of them would catch an exception if there was one in that node?

An talking about the HTTP request node, what happens when there's an exception/error inside of it such a connection rejected? Does it output anything if there's a catch node observing it either locally (the lowest catch node) or globaly? Does it output anything if there's no catch node observing it and there's an exception/error?

Regards

That should be easy enough to test for yourself.

However, You likely want the 1st catch node set to catch uncaught exceptions

image

So this means the exception will be triggered and node-red will look for all the potential catch nodes in order to decide who's going to get control of the flow?

If that's it, the checkbox you mentioned would do the trick, but what if for some reason you have multiple nodes that could actually handle the exception? I guess node-red would choose only one following some criteria but just one, correct?

No. All eligible catch nodes will get triggered.

Ok, thanks.

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.