Red Hat Bugzilla – Bug 535659
content discovery doesn't happen for 12 hours after initial import
Last modified: 2009-08-19 13:04:00 EDT
1) import a platform (linux or windows)
2) wait 2 minutes (2 minutes should be plenty of time) to let the initial content discovery get scheduled and trigger
3) recall that platform discovery is disabled by default, so go to the platform plugin configuration page in the UI and enable content discovery
4) wait... and wait.... and wait... content is never discovered
5) wait over 12 hours - content should eventually be discovered
The problem is this:
initial schedule of content triggers, but the platform resource is told to not discovery anything, so it returns an empty list. the schedule is then re-scheduled for 12 hours from now. You then switch the flag to enable content discovery - but the schedule has already triggered so it won't try to discovery content again for another 12 hours.
it seems like the reasonable thing to do would be to reschedule for now when you enable it. this doesn't just cover the disable->enable case, but also the enable->enable case. doing this will allow users a nifty trick to "force" the discovery by making a no-op change to active configs (or enabling currently disabled configs). note, when you reschedule it, it should cancel current schedules and basically reset the 12-hr clock from the point of enablement.
RHQ-2332 is tangentially related - deals with content scheduling too
one problem is that the inventory event listener had hooks for ACTIVATING resources but curiously did not have hooks for handling DEACTIVATING resources. so it never got rid of schedules for resources whose components were stopped.
I'll be adding this to the listener framework.
QA Verified, initial content discovery no longer takes 12 hours.
This bug was previously known as http://jira.rhq-project.org/browse/RHQ-2331
This bug is related to RHQ-2332