This is a JON bug for the issue described in Bug 801432 Comment 18:
"...I stumbled onto the log message added for Bug 801432 (see also Bug 807465). In my agent log I saw messages like this when uninventorying resources:
2014-07-24 09:05:41,859 DEBUG [WorkerThread#0[127.0.0.1:54666]] (rhq.core.pc.inventory.InventoryManager)- [BZ 801432]
java.lang.Exception: Unexpected child set - if you see this, please notify support or log it in bugzillajava.util.HashSet:10230:test-simple.war
This is a problem because it means that we are perhaps more susceptible to ConcurrentModificationException than we may have thought. This indicates that we are working with HashSet when we are expecting to have the child resources in a safer Set impl."
The issue has been fixed upstream. This is to track the fix for a JON release. I would recommend 3.3 as it could prevent a troublesome ConcurrentModificationException.
Author: Jay Shaughnessy <email@example.com>
Date: Fri Aug 22 16:20:46 2014 -0400
[801432, 807465] Related Issue to these BZs
Uninventory triggered our "assert-style" debug logging indicating that we
were working with HashSet for child resources when we expected to be using
a safer Set impl (wrt preventing ConcurrentModoficationException). There
were a few issues in play:
- When loading persisted resources from disk convert childResources to
CopyOnWriteArraySet if necessary. This repairs resources persisted with
the wrong Set impl.
- Eliminate some potential concurrent modification danger (or, at a minimum,
- Fix a couple of other places where we weren't using CopyOnWriteArraySet
- Fix Resource entity to ensure that when customChildResourcesCollection=tru
that the childResources Set is truly protected. It was here that we were
losing the proper Set impl.
some unnecessary work) by only calling deactivateResource() on the root
resource. It recursively deactivates the subtree, so no need to then call
it on every node in the subtree.
- Fix our "assert-logging" conditional, which despite finding this issue was
actually looking for the wrong set impl. It had not been updated when we
moved to CopyOnWriteArraySet.
Cherry-Pick master 3e47741694b55fedecf9c904d89de11a7b92ccb2
Moving to ON_QA as available for test with the following brew build:
Verified on version :3.3.0.ER02 Build Number :4fbb183:7da54e2