I just started using persistence in my setup, and wanted to try my motion sensor.
When it detects motion, it changes state from OFF to ON, and after 30 s it changes back, from ON to OFF.
When looking in the persistence docs I only see the Cron triggers, everyChange and everyUpdate.
Using everyChange will in this case generate a row in the db both when going from OFF to ON, and when going from ON to OFF.
Is there a way to only get the OFF to ON transition recorded in the db?
i don’t think there is a way to do this in OH right out of the box.
But of course this is doable, depending on what kind of persistence you are using.
Basically you need some sort of cli for the database
Space should not be an issue, and if it really was you can use a persistence service to compress/auto-aggregate older data such as rrd4j. I`m sure once you omit recording half of the events, right the other day you’ll encounter an application where it would be helpful to still have access to that data.