Nicholas Bartlett
Nicholas Bartlett

Reputation: 53

ThingsBoard Inactivity Events Not creating alarms

I am working with the following guide:. I am not able to get any alarms created. According to the guide, I must create an inactivityTimeout, in the guide it sets it to 60000, I have set it to 10000.

Server Attribute - inactivityTimout = 1000

I then edited the root rule chain: Edited Root Rule Chain

Here is the function details in the Create Inactivity Alarm:

if (metadata.prevAlarmDetails) {
    details = JSON.parse(metadata.prevAlarmDetails);
}


return details;

Here is a screenshot of the Create Inactivity Alarm node: Create Inactivity Alarm Node

Below is the function for the Clear Inactivity Alarm Node:

if (metadata.prevAlarmDetails) {
    details = JSON.parse(metadata.prevAlarmDetails);
}
return details;

And here is the screenshot for the Clear Inactivity Alarm Node: Clear Inactivity Alarm Node

When I post using Postman: postman screenshot

I get the value in the latest telemetry: IRMS out Value

But nothing in the alarms section of the specific device: No Alarms Found

I have also tried to set alarms in device profile for activity and for the IRMS value and when the conditions are met, there are still no alarms being set.

I have double checked as I notice that the guide i followed was for the thingsboard.io So i followed this guide as well: Guide for thinsboard.cloud

Any assistance would be appreciated.

Upvotes: 0

Views: 345

Answers (1)

ahmed hamza
ahmed hamza

Reputation: 21

I suggest send email as kind of debugging to check if inactivityTimeout chain work

enter image description here

if working then go to check the alarm node

Upvotes: 0

Related Questions