Rules are faster than persistence

Hi everybody,

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.

Thomas

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 rdd2j and seeing this behavior regularly.

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.

Thomas

I use the same workaround. Only my timer is 240 sec long.

How long have you see this problem? Was it introduced with a recent build or is it something that has always been a problem?

This behavior was in 1.x and also always available when I startet to move to OH2 which was in summer this year.