After upgrade to Openhab 4: a lot of "Item updated to" in the log

Dear all, I just upgraded my docker contained openhab instance from 3.4 to 4. My fronttail is now showing an “item updated to” every time the item was refreshed by the thing. This is new and did not happen in my previous openhab instance.

I give an example to better clarify what I mean.

Contact_VeluxRoom3 is an item that represents the OPENING state of a window. It is read using the modbus binding from my PLC. The binding polls the PLC every second. I see this in my log:

2023-07-24 23:37:30.240 [INFO ] [openhab.event.ItemStateUpdatedEvent ] - Item 'Contact_VeluxRoom3' updated to CLOSED
2023-07-24 23:37:31.328 [INFO ] [openhab.event.ItemStateUpdatedEvent ] - Item 'Contact_VeluxRoom3' updated to CLOSED
2023-07-24 23:37:32.316 [INFO ] [openhab.event.ItemStateUpdatedEvent ] - Item 'Contact_VeluxRoom3' updated to CLOSED
2023-07-24 23:37:33.419 [INFO ] [openhab.event.ItemStateUpdatedEvent ] - Item 'Contact_VeluxRoom3' updated to CLOSED
2023-07-24 23:37:34.466 [INFO ] [openhab.event.ItemStateUpdatedEvent ] - Item 'Contact_VeluxRoom3' updated to CLOSED
2023-07-24 23:37:35.649 [INFO ] [openhab.event.ItemStateUpdatedEvent ] - Item 'Contact_VeluxRoom3' updated to CLOSED

This is the item definition:

label: Dakraam Linde contact
type: Contact
category: window
groupNames:
  - Contacts
  - ContactsVelux
  - Contacts_Summed
  - gBedroomLindeVelux
groupType: None
function: null
tags:
  - OpenState

This is the item definition:

UID: modbus:data:plc:coils1:SM_2_H4
label: PLC SM_2_H4
thingTypeUID: modbus:data
configuration:
  readValueType: bit
  readTransform: MAP(invertContact.map)
  writeTransform: default
  readStart: "75"
  updateUnchangedValuesEveryMillis: 1000
  writeMultipleEvenWithSingleRegisterOrCoil: false
  writeMaxTries: 3
bridgeUID: modbus:poller:plc:coils1

I also see this behavior for items that are connected to the HTTP binding, the Astro Binding, and several others.

Is this new normal behavior?

see this post openHAB 4.0 Milestone discussion - Setup, Configuration and Use / News & Important Changes - openHAB Community

1 Like

Thanks! So what I did to fix this was replace \userdata\etc\log4j2.xml with the official file: openhab-distro/distributions/openhab/src/main/resources/userdata/etc/log4j2.xml at main · openhab/openhab-distro (github.com)

My entire userdata folder is in a volume so it gets transferred from one version to the next. If Openhab doesn’t have any migration rules on that file then it won’t get updated.

1 Like

I also ran into this outdated logging config and created a PR to fix this for everyone:

2 Likes

Nice! Thanks!