-
-
Notifications
You must be signed in to change notification settings - Fork 431
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Items not found when displaying sitemap or executing rules #865
Comments
I confirm the issue. Build #1603 (x86_64, Debian 9, Docker) |
I saw one other bit of weirdness, which I think might be related to this. I have an .items file containing some item and group definitions. After starting openHAB, the group is empty. But, if I then save a small change to the .items file (such as adding a blank line), the group now contains the items. |
I see this often after clearing the cache. After upgrading OH, I do wait a bit and then do another OH restart to get passed this. The scope of this issue is larger than sitemaps... rules fail due to missing Items. I have also not seen this happen to managed Items. |
In recent snapshots I'm seeing this after almost every restart (with or without clearing cache).
Agreed. |
Sounds to me as if either something has changed wrt to start levels or by having a different startup behavior by recent refactorings wrt service activation (constructor injection, "immediate=true" removals, etc. That'll be very tricky to figure out... |
I've seen this since before the constructor injection PRs. I don't specifically remember, so could be mistaken, but I want to say that it's been happening since S1566. If needed, it wouldn't be hard to test. In my setup, I've only seen this after clearing the cache. |
I installed build 1618 (the one with the fix for #829) on two systems (one test system and one production system) where I was seeing this issue consistently on startup. After several restarts on each of those systems, I'm no longer seeing the issue. 😕 I'll monitor for a while. If it no longer occurs, I'll close this. |
I did not see the error with S1618, but several rules failed to load due to Items not being present...
Other rules started properly. I suppose this is just a timing issue with the rule engine starting before the Items are available, but I have a script to delay the loading of other scripts to prevent this. And I also found these errors...
I use jdbc-mariadb for persistence. After a restart of OH, everything was OK. |
I now have 1622 running on three systems (one test and two production). I've not seen this issue on any of those systems since installing build 1618 or later. Therefore, I'm closing this issue. |
I'm reopening this issue because similar behavior was reported recently on the forum. https://community.openhab.org/t/oh2-system-behavior-after-upgrade-some-items-not-resolved/83373 |
I don't have a lot to add except that I'm seeing the same as openhab-5iver. When I upgrade or clear the cache the first boot results in lots of missing Item errors from both the sitemap and Python rules (e.g. cannot create Rule triggers). I just need to wait patiently for OH to fully start up and then a restart of OH will work like it should. I can't remember when I first saw this (I should have written that down) but I can confirm that yesterday when I updated to build 1715 I saw the same behavior. All my Items are defined in .items files. |
I don't have much to add as well. But, this thread details my experiences and are similar to mhilbush. [https://community.openhab.org/t/oh2-system-behavior-after-upgrade-some-items-not-resolved/83373] This started for me after the following upgrade: To: |
Hasn't it been like that ever since ? Remember ESH#1892 (IIRC), that no-startlevels thingy. |
Yes, it was not uncommon to see this on the first startup after an upgrade. However, the behavior I was seeing was occurring consistently on every startup, which from my perspective was new behavior. |
I've ever been seeing that. Possibly more visible because my RPi is slower than most of your boxes. |
But it's not just a rules thing. It impacts sitemaps, as well as console |
Yes but the predominant problem is with rules, in particular when these take long to compile (such as they do on Raspis if you use primitives there - I for instance have got a rules file that takes 90-100 secs. to load. Almost nothing else to work meanwhile). |
I would disagree. I view it as a problem with rules AND sitemaps (or any UI for that matter) equally. And, for the problem I'm describing in this issue, no amount of delay in loading the rules will resolve the situation. |
Oh that's right. I didn't mean to say to delay rules actually solves the problem(s). |
I just did an update from one openHAB snapshot to the latest 2.5.6 build #144 and experienced missing items (like on a few updates before). Then I searched for related bugs and found this issue. I am not sure if its only timing related, which might then be fixed by #1514, because I observed the following: By comparing the output of "items list" after startup with an "items list" after I had done "touch *.items" in bash, I could see a pattern showing WHICH items were not loaded:
So all these items didn't exist after my update and only appeared once I refreshed the ALL items that were linked against openHAB-2 thing channels were correctly loaded! @kaikreuzer FYI: Since you have just worked on improving the model loading. Maybe my observation rings a bell to you. |
I can confirm this observation, only items without a channel seem to be affected. |
I'm closing this as it may be fixed as a result of changes for OH3. |
* Fixed links in uis.md Multiple dead links fixed * Fix links multiple links to addons page fixed * Delete reference to non-existing doc page Reorg of docs made the referenced chapter obsolete * Fixed multiple links various links fixed * Fixed links links to section addons fixed Deleted reference to yahooweather binding (now obsolete) as example for binding that requires manual thing definition. * link fixed link to addons section fixed * fixed link fixed link to UI selection screen * Fix link Fixed link to addons section * Fix links, update example Signed-off-by: Markus Lipp [email protected] (github: LightIsLife) Links to addon section and others fixed. Old example using the now obsolete Yahooweather binding has been replaced with an example using the network binding * delete link habpanel.md Deleted inexisitng link * Fix links index.md Fixed links * Fix link sitemaps.md (code review) * Update installation/windows.md (Code review) Co-Authored-By: LightIsLife <[email protected]> * Fix typo migration.md (Code review) * Fixed typo migration.md (code review) * Update qnap.md
I just installed build 1607 on a system that had been running 1502 for quite a while.
After an openHAB restart, sometimes, when displaying a sitemap, I see errors in my log indicating that items cannot be found, even though the items exist.
I've found each of the following things will clear the issue:
org.openhab.core.model.item
also resolves the issueCould there be a timing issue where a dependent bundle might not be available at the right time during startup?
Example of errors.
The text was updated successfully, but these errors were encountered: