Hi All,
I was thinking to post a request for a new feature on https://github.com/eclipse/smarthome regarding the web based management of logging. I did a quick check on the issues list and i didn’t find anything similar.
Before I open up the request, I wanted to check if the community believes that it would be useful feature, so go ahead and post some comments
Scope: Create a new Configuration section in PaperUI called “Logging” that will allow a web based modification of the logging facility (levels, appenders, etc) of openHAB2. At least for org.openhab.*
and smarthome.*
Why ??? : To make it easier for users to: (1) identify loggers & (2) change on the fly log settings to help them with debugging/root-cause analysis.
Requested Features:
- Display current loggers and their levels (grouped)
- Allow changes to the log levels per logger
- (optional) Allow creation of new file appenders (with their parameters)
- (optional) Allow assignment of file appender to logger
A draft concept would look like (don’t laugh with the poor design… I did this fast ) :
In my current setup, I manage logs via the openHAB2 console:
openhab> log:list
Logger | Level
-------------------------------------------------------------------
ROOT | WARN
javax.jmdns | ERROR
org.apache.aries.spifly | ERROR
org.apache.karaf.kar.internal.KarServiceImpl | ERROR
org.eclipse.smarthome | INFO
org.jupnp | ERROR
org.openhab | INFO
org.openhab.binding.knx | WARN
org.openhab.binding.mpower | WARN
org.openhab.binding.mqtt | WARN
org.openhab.binding.ntp | WARN
org.openhab.binding.samsungtv | WARN
org.openhab.binding.unifi | WARN
org.openhab.binding.weather | WARN
org.openhab.binding.wol | WARN
org.openhab.binding.zwave | WARN
org.openhab.io.transport.mqtt | WARN
org.openhab.persistence.influxdb | WARN
org.openhab.persistence.mapdb | WARN
org.openhab.ui.paper | WARN
org.ops4j.pax.web.service.jetty.internal.JettyServerWrapper | WARN
smarthome.binding.astro | WARN
smarthome.event | INFO
smarthome.event.ChannelTriggeredEvent | WARN
smarthome.event.ConfigStatusInfoEvent | WARN
smarthome.event.ExtensionEvent | WARN
smarthome.event.GroupItemStateChangedEvent | WARN
smarthome.event.InboxAddedEvent | WARN
smarthome.event.InboxRemovedEvent | WARN
smarthome.event.InboxUpdatedEvent | WARN
smarthome.event.ItemAddedEvent | WARN
smarthome.event.ItemChannelLinkAddedEvent | WARN
smarthome.event.ItemChannelLinkRemovedEvent | WARN
smarthome.event.ItemCommandEvent | WARN
smarthome.event.ItemRemovedEvent | WARN
smarthome.event.ItemStateChangedEvent | WARN
smarthome.event.ItemStateEvent | WARN
smarthome.event.ThingAddedEvent | WARN
smarthome.event.ThingRemovedEvent | WARN
smarthome.event.ThingStatusInfoChangedEvent | WARN
smarthome.event.ThingStatusInfoEvent | WARN
smarthome.event.ThingUpdatedEvent | WARN
smarthome.ui.paper | WARN
tuwien.auto.calimero | WARN
openhab>
Usually, I put the major category on INFO level and then the subcategories in WARN (after I monitor the system to check if all is ok)