2023-05-09 21:19:28.305 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_TotalCloudCover' in registry
2023-05-09 21:19:28.306 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_temperature' in registry
2023-05-09 21:19:28.307 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_TotalCloudCover' in registry
2023-05-09 21:19:28.308 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_WindSpeedMS' in registry
2023-05-09 21:19:28.308 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_temperature' in registry
2023-05-09 21:19:28.308 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_TotalCloudCover' in registry
2023-05-09 21:19:28.310 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_WindSpeedMS' in registry
2023-05-09 21:19:28.310 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_TotalCloudCover' in registry
2023-05-09 21:19:28.310 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_temperature' in registry
2023-05-09 21:19:28.312 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_WindSpeedMS' in registry
2023-05-09 21:19:28.313 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_temperature' in registry
2023-05-09 21:19:28.314 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_WindSpeedMS' in registry
2023-05-09 21:19:28.315 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_temperature' in registry
2023-05-09 21:19:28.316 [INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'fmi_forecast_WindSpeedMS' in registry
Is there a particular time when you see these errors (e.g. at system startup)?
The registry it mentions is the Item registry and the error means that at the time it checked, the Item didn’t exist. Knowing a bit more about the timing can maybe point at a cause, or at least a path to a cause.
They don’t happen to correspond to editing .items files or anything like that? The only reason I can think of that the InfluxDB add-on would be looking for Items in the registry is to do a restoreOnStartup, which happens during OH start and for file based .items files when the file is reloaded after a change.
Did some debugging and found out the root cause for this error. It happens when the graph is fetching point values from InfluxDB that do not have a corresponding Item in OpenHAB. If I add an item with the same name the error goes away.
Seems like the graphing engine is expects items for all displayed values. Is this a bug or is this how it is supposed to work? I see no need for items for values that are used for graphing only.
openHAB charting only works with Items. Yes, the healing engine is expecting Items. This is working as designed. I’m not entirely clear how you got it to even try to chart data that isn’t associated with an Item.
This is a kludgy workaround to get openhab chrts to render our control value time series.
Background:
The control value time series data is saved to the influxdb directly with the Influx REST API (called from the script actions of our rules) , bypasing the openhab persistence layers completely. This is because openHab doesn’t currently support saving timeseries data with future timestamps.
Now, the data of the control points is in the influx database, but openHab is completely unaware of it, so it cannot render it in the Charts.
To make the data available for charting, the kludgy workaround is to create an Item with exactly the same name as what we used when we saved the data to the database. This way we Charts will read the data from the database just like it does for “normal” items whose data openHab had saved via normal persistence.
This is interesting… Did you enter the name of the control point to the chart YAML manually? I can’t think of any other way how the chart could be aware of that time series, if you had not created the Item with the same name earlier.
Yes. For example, the weather forecast from fmi has several forecasts named differently. I just added them to the scripts that fetch the data and then added the same names in the graph yaml. As far as I recall I never had any items created.
Okay, this then explains this. Openhab charts were completely unaware that such data could exist because there were no items for them. It’s kinda a same thing as editing the YAMLs manually and making a typo, that would for sure result in similar errors.
Now that we know what was behind this, it’s quite easy to connect the dots. The error message is telling us exactly what the problem is
My theory would be as follows. The interface between OH and InfluxDB is pretty generic. If you give it an Item name, even one that doesn’t exist in OH, it will happily generate a query InfluxDB for that. And since the timeseries in InfluxDB match the Item name, it finds data and charts it.
However, the chart widget also subscribes for update events from the Items it is displaying. This is where the error is coming from since the Item doesn’t exist.
Hey @timo12357,
cloud you explain what you did in influx to get rid of the messages? I’ve got the same problem after restoring some influx openhab measurements for some items. now i see that
[INFO ] [b.internal.InfluxDBStateConvertUtils] - Could not find item 'MQTTSmartMeters.SM01GASKBMTotal' in registry
InfluxDB, for some reason, is able to store values without a corresponding Item. If this happens, i.e. you have a measurement in InfluxDB that does not have an Item with same name in OpenHAB you get this error.
For example, you have a measurement in InfluxDB that is called:
it will churn out the error but you will still be able to use it in graphs without having a corresponding Item in OpenHAB. This is very counterintuitive and it took some time for me to understand.
The solution, is to create dummy items in OpenHAB with the exact name of the offending item in your logs. In your case, you need to create a dummy item with the name
MQTTSmartMeters.SM01GASKBMTotal
in OpenHAB. After doing this the error should go away.
Well after some testing - this isnt my problem, unfortunately…
I used InfluxDB Studio to look inside database and found that i did something wrong while importing the old data. So current data is stored in item_1, label_1 and type_1 while old, imported data is in item, label and type: