Description of problem: Agent was shutdown. In inventory is a single Linux platform with 30 children JBossAS 4 servers (and their children of course). I have one dynagroup definition defined: resource.type.plugin = JBossAS resource.type.name = JBossAS Server And one group (from that dynagroup def) was created. All 30 of my jboss-as instances are in the group. platform is not in any group. There are no other groups defined. I went to uninventory the platform and got error: "Failed to uninventory selected resources Cause: javax.ejb.EJBException:java.lang.IllegalArgumentException: Could not remove resources from their containing groups -> java.lang.IllegalArgumentException:Could not remove resources from their containing groups" This was in the release-3.0.0 branch as of about June 30.
I just checked the logs and it looks like its the Oracle 1000-in-clause limit problem that should be fixed in newer code. I'm moving this to ON_QA since this should be fixed, but this particular use-case should be tested.
This is happens in the old code: 2010-07-02 08:48:37,065 ERROR [org.rhq.enterprise.server.resource.ResourceManagerBean] Bulk native query delete error for 'DELETE FROM RHQ_RESOURCE_GROUP_RES_EXP_MAP WHERE RESOURCE_ID IN ( :resourceIds )' for [195522, 195523, 195524, 195525, 195526, 195527, 195528, 195529, 195530, 195531, 195532, 195533, 195534, 195535, 195536, 1955.................] Still fails with the code from 2010/7/2 2010-07-02 11:41:09,380 ERROR [org.rhq.enterprise.server.resource.ResourceManagerBean] Bulk native query delete error for 'DELETE FROM RHQ_RESOURCE_GROUP_RES_EXP_MAP WHERE RESOURCE_ID IN ( :resourceIds )' for [195522, 195523, 195524, 195525, 195526, 195527, 195528, 195529, 195530, 195531, 195532, 195533, 195534, 195535, 19
The issue actually also shows up when there is no group is defined in the system.
d91539e on release-3.0.0 ; tested on perf-env with Oracle
QA Verified. After having child resources in a dynagroup -- multiple different child resources in different groups, actually -- I was able to successfully uninventory the platform.
To be certain i used appropriate test criteria, i re-ran this with postgresql servers dynagroups and table dynagroups, which references postgresql servers that contained over 1000 tables. I was still able to uninventory the parent platform.
Tested against postgresql and oracle backends.
Mass-closure of verified bugs against JON.