rule "Temperatursteigerung Büro Nati"
when
Time cron "0 30 21 * * ?"
then
sendCommand(EG_Buero_Heizung, 23)
end
stopped working today.
I have timed rules for rollershutters, decoration light and heating temperatures.
In the morning everything worked fine. But today in the evening they didn’t worked and they arent working till now.
I already checked if I can trigger the actions in openhab using my sidemap… thats working fine. I was able to move a roller shutter with openhab app. I changed the time for the rule to the current time +1 minute and waited till the time. Nothing happend. I also checked the logviewer and it wasn’t even a action visible. Time in logviewer matches the current time…
So I have no idea whats the problem… have you any ideas?
Depending on the version of OH, you can have only 2 (2.4 or older) or 10 (2.5 or newer) time based threads running at the same time. This includes Time triggered Rules, Timers, and Astro event triggered Rules. I’m sure there are more.
If you have reentrant locks, Thread::sleeps, long running calls like executeCommandLine, or errors that cause a rule not to exit, you can quickly run out of the available threads. Look for errors and analyze your Rules to see if you might have too many of these sitting around waiting.
Im just started with creating my first rules and I have 90% rules like the rule in the first post. This is just for the start of my smart home because there are better indiciators other then just the time. So a lot of them will be changed in the future. but maybe thats the cause of the issue… a lot of rules waiting to reach a specific time.
I solved the issue by restarting the PI which is running my openhab… but from my point of view this should not be necessary… so I have to find the real solution
It’s not a problem of how many Rules are waiting to be triggered. The mere fact that you have a Rule with a Time trigger doesn’t consume a thread. Only actively running Rules consume a thread. So you can only have two running at the same time. This is why it’s important not to have Rules that take a long time to run or have a chance that they never return.