Found a case where every time a service level scan was run it would cause a repeating scan to run because it thought one of the resources had been "modified". In point of fact, it seems that somehow I got two resources of type "filesystem" in with the same resourceKey (i.e. a duplicate resource). The outcome is that InventoryManager:1740 thinks that resource has been modified because its comparing the id of the first to the id of the duplicate. Perhaps a more bullet proof solution is to have a limit on the # of recursive calls to discovery reports so that they won't go for ever if inventory gets into somewhat messed up places. I've marked this as a minor as I don't know of anyone else who has gotten their inventory into this messed up state... likely pretty rare. And a workaround is to delete one of the resources.
greg, can you try and re-run this scenario and see if it still happens for you. as part of the perf tuning we did for 1.2 release, the synchronization code between agents and server was relaxed. it was determined that we were notifying the agent that a resource had changed TOO often, which i have a strong feeling contributed to this infinite repeating discovery. if i'm right, you should not be able to reproduce this anymore.
Look at RHQ-2057 for a similar issue of duplicated resources in the agent inv.
This bug was previously known as http://jira.rhq-project.org/browse/RHQ-1885 This bug is related to RHQ-2057