Hi there,
apologies for a lengthy introduction…
My first post on this platform, even though I am an enthusiastic OH user since roughly 8y. I use it mainly for a customized alarm system, heating control and some peripherals (wallbox, lights, switches). So far, I could solve my issues and challenges through finding similar / matching topics in this community.
I am greatly thankful for all the contributions of the various experts here!
Now, after using a fairly wobbly OH2 system for many years, I finally started migrating the system to OH3 a couple of months ago (starting from a clean slate).
Even though OH4 was just released, I will stick to OH3 for now.
Now, as for the topic:
Whilst using mainly text files in OH2, I used the GUI in OH3 extensively to install all the various things and items and (for the first time) structured the whole setup using the Model functionality.
Yesterday, I configured persistence, using an SQL database. The weird outcome: once saving the connection information, the system immediately started storing items and their values with everyChange, although no .persist file was existing yet.
I thought I understood the documentation in a way that persistence in OH3 can only be configured using text files (.persist). And searching the GUI for almost an hour, I couldn’t find any context menu or config UI for things or items where a persistence definition could already be set up (despite the main persist config where the database connect information is placed).
And what is even weirder: the behavior (of storing values on everyChange) didn’t change when I actually placed a .persist file in the config directory, using an every5min configuration for the items in question. The persist file was recognized by the system as the openhab.log clearly confirmed. Yet, it didn’t make a difference, the system kept storing on everyChange, which led me to disable one thing (Shelly 3em) because it was flooding the database with values every second for several items.
Content of the .persist file:
Strategies {
everyMinute : "0 * * * * ?"
every5Minutes: "0 0/5 * * * ?"
everyHour : "0 0 * * * ?"
everyDay : "0 0 0 * * ?"
// if no strategy is specified for an Item entry below, the default list will be used
//default = everyChange
default = every5Minutes
}
/*
* Each line in this section defines for which Item(s) which strategy(ies) should be applied.
* You can list single items, use "*" for all items or "groupitem*" for all members of a group
* Item (excl. the group Item itself).
*/
Items {
shelly* : strategy = everyMinute
shellyem38caab561eed31721666236_Leistung : strategy = everyMinute
}
Not sure what else to provide, the persistence connect information is pretty straight forward and certainly without any item/thing based context.
Hope anyone can give me a hint of what I am doing wrong…
- Platform information:
- Hardware: Intel Celeron
- OS: Unraid Platform - Linux Debian VM
- Java Runtime Environment: Zulu11.41+23-CA (build 11.0.8+10-LTS)
- openHAB version: openHAB 3.0.1