i just ran into the problem that my startup rule is faster than the persistence service that should restore some values. As far as i remember in some configuration file the times to loaf differnt thing are described, but i cannot find it.
OCuld someone giv me a hint. Besides this i will start to build a solution that delay any rule execution until i set a flag that allows rule execution. But at the end this is not a really good solution.
This might be a new thing. When did you start noticing this behavior because I’ve never had that problem since moving to OH 2.
There is no longer a polling period parameter in OH 2 so there is no way to change this. But I have noticed on my setup that rules always seem to load way later than persistence.
But I’m using MapDB for restoreOnStartup. Perhaps if you are using something that requires a network connection like MySQL or InfluxDB it takes just enough longer to matter.
I am using mapdb and recognised this behavior yesterday while creating a timer configuration for the xmas tree with three times.
The idea is to apply value only if i am sure that the timer value are the right ones. with the apply button the values moved from proxy items to the real items wich are persited. Based on this approach i initialise the proxy items at startup with the real values.
Now i build te initialisation with a 15 second timer and a flag that allows rules only to run after initialisation.