Node Red Incident - edited RBE

Hi all,

These last weeks, I have received almost every week a Node Red email mentionning "unplanned incident - sevirity 1: IMS provisioning workflows are not functiong at this time".

My question is: how do I know if my flows have been reset or not due to this event ? (especially my regex switch). Is there something on Node Red to check the state of the flow ?

In general, how do I check the latest information contained in my regex ? (I see this information directly in the debug window when the flow is working but not anymore later on).

Thank you very much to this community, much appreciated.

I assume you mean these are notification email coming from IBM Cloud? If so, they are absolutely nothing to do with your Node-RED application. They are notifications of issues with other parts of the IBM Cloud platform. Your Node-RED application will not be affected.

What regex? What information? Not sure what you mean.

In my flow I use a regex node that block same information coming from my source.
How/where can I see what information my regex node is blocking ?
How can I check the state of that regex node ?

image

doubleclick ?

That looks as if it may be a Switch node (I am not aware of a Regex node). As bakman2 says, if you double click it you will see how it is configured. In addition you can use Debug nodes to look at the input and outputs to what it is doing. If you want to see if any input is not being passed to either of the outputs then add another output configured with the test Otherwise and it will route anything that does not go to o/p 1 or 2 to o/p 3.

Regarding "the unplanned incident" apprearing on my account, indeed apparently there is nothing to do in my side. My flow won't normally be reset because of these events.

Otherwise, I am having a hard time with the RBE. It doesn't work properly when the payload message comes back to the initial value/string that has been blocked. For instant topic 1 PASS, topic 1 BLOCK, topic 2 PASS, topic 1 BLOCK. In this example, I do not understand why the last topic 1 is blocked.

I am also looking to have something as below :

payload="xxx" topic1 PASS
payload="xxx" topic1 BLOCK
payload="xxx" topic1 BLOCK

payload="xxx" topic2 PASS
payload="xxx" topic2 BLOCK

payload="xxx" topic1 PASS

I am looking to have the last topic1 to PASS, and so on.

Secondly, I was looking for precise detail of the RBE debug message. Because, if I exit the Node Red platform, I do not see anymore what the RBE blocked/passed previously. Is there a file or something available that save all previously blocked RBE message ?

Please find attached part of my flow where RBE is currently used.

image

The payload hasn't changed, therefore it will be blocked.

The RBE node blocks unless the payload changes. This is on a per topic basis.

You may have to roll your own. E.g. append topic and value into a CSV or JSON string and leave the topic empty. Then pass that through the RBE.

E.g.

payload="{ value:'xxx', topic:'topic1'}" PASS
payload="{ value:'xxx', topic:'topic1'}" BLOCK
payload="{ value:'xxx', topic:'topic1'}" BLOCK

payload="{ value:'xxx', topic:'topic2'}" PASS
payload="{ value:'xxx', topic:'topic2'}" BLOCK   
payload="{ value:'xxx', topic:'topic1'}" PASS

this would work as the payload changes.

All you would need to do is put a JSON node on the output to turn the JSON back into a useable object.

I have tried to bring some modifications to my flow with the JSON node, but it appears the "RBE block-pass" is still occuring and I am receiving a message "unexpected tocken b in JSON at position 0".

Is the JSON node well positionned among the flow or I am mistaking something ?

image

image

image

What are you passing to the json node? add a couple debug nodes...

I am trying to circumvent this situation :
payload="xxx" topic1 PASS
payload="xxx" topic1 BLOCK
payload="xxx" topic1 BLOCK

payload="xxx" topic2 PASS
payload="xxx" topic2 BLOCK

payload="xxx" topic1 BLOCK

in order to have :
payload="xxx" topic1 PASS
payload="xxx" topic1 BLOCK
payload="xxx" topic1 BLOCK

payload="xxx" topic2 PASS
payload="xxx" topic2 BLOCK

payload="xxx" topic1 PASS

As a result, I am passing the output of the RBE to the json node in order to solve the situation above.

Like we have stated. That's not what the RBE does.

I provided a workaround by making the payload a JSON string that you can parse back into a JS object to get the values.

Remember, the payload value must change (per topic) to pass.

My workaround put both payload and topic into payload meaning it would function as you requested.

Where are you stuck?

1 Like

Hello Steve-Mcl,
Sorry, I am a beginner with Node Red, I sometimes don't understand the whole message/solution.
Well, I am stuck because I don't understand where JSON string should be placed. Does it replace my Regex node which contains my payload value ?

I dont understand the JS object. This will be placed between the JSON string and the changes node "Buy/Sell" ?

Well, i'm afraid you have some learning to do.

JSON is a string representation of a javascript object.

A JS object is declared like this...

var myObject = {MyPropery : "hello"}

you can then access the properties through dot notation e.g.

myObject.MyPropery = "goodbye";

you can even add properies on the fly...
myObject.NewProperty = 77

var myMsg = {payload : { value : "xxx", topic : "topic1" } };
return myMsg;

or if it makes more sense...

var myMsg = { }; //make empty object
myMsg.payload = { }; //make empty object inside myMsg
myMsg.payload.value = "xxx";
myMsg.payload.topic = "topic1";
return myMsg;

then send this through RBE (not sure but you might have to send it through an JSON node first to change the JS object into a JSON (Javascript Object Notation) string before sending through the RBE. Give it a try.

The point is you need to change something (anything) in the msg.payload to permit it to pass the RBE.

1 Like

No, No...You now have the opportunity to expand your knowledge and learn a fantastic new tool. Just take it a little bit at a time, after all you weren't taught algebra in kindergarten (well I wasn't).

Take it step by step (like we al have) and before you know it, you wil be answering questions on the forum.

1 Like