Item/Group State Changed Events

Is there anyway to disable change events for specific items/groups - from rules if possible?

Specific problem:
I have 16 spot lights (hue) changing randomly in a rule (colour/saturation/brightness using math random on a recurring schedule) (like a disco). Trouble is my log is flooded / extra resource usage as they are changing rapidly - like 48 lines per second.

I’d preferably like to disable the item/group state changes just for these lights when the rule fires (scene from a fibaro dimmer), then enable them again when the rule stops.

Not sure if this is possible or if anyone has any suggestions?

No, but you can filter them out of the log. I think you might be able to disable the Thing that the Items are linked to from a JavaScript/Python/Groovy rule or Script Action. But you cannot make the Items not receive updates and changes.

Sorry I wasn’t very clear. It’s just the log I want to filter, not stop changes. But only for specific items on demand if possible rather than from the console.

I think I can do ‘all’ items using exec and a script but didn’t know if there was a way to filter down further.

The on demand part is the hard part. You can change the logging level from the console but that won’t target individual items. You can modify the config but that’s more he less permanently.

But this might be an XY Problem. What are you trying to see in the logs? How are you looking at the logs? Maybe a filter (logviewer) or a grep to cooker the logs would do the same. Maybe the developer sidebar event stream could do the job and you don’t even need to look at the logs.

Where are item state logs generated from? (What class?) could I override this class from a rule and apply an if statement to the logger? Filtering on channelUID…

Using the openhabian log viewer on a non openhabian install but don’t really want to disable for all item changes.

I’ll have a play later

All the logging is handled by a third party library and even if that were not the case, you couldn’t override anything like that from a rule. And there isn’t one logger per Item. It’s one logger for everything that gets put on the event bus.

But, Frontail has a filter option and you can filter the logs you are seeing down to just those lines you care about at the time. For example (MyItem1|MyItem2) as the filter will only show those lines containing those two Item names.

If on the command line see How to watch and look through logging where you can filter out those lines that match those Items you don’t care about.

In OH3 the Developer Sidebar will show the same information from events.log and you can filter that down to just the Items you want to see.

Or you can set the logs to permanently (until reconfigured) to exclude log statements that match a regular expression from being logged out. See openHAB - Filtering event logs, though that post needs to be updated for OH3’s log4j2.xml formatting.

thanks for all the info @rlkoshak
I did think it may be the case it was handled outside.
Ill take a look into frontail filtering as I have this set up as a seperate docker instance linked to the main dashboard.