Hide Forgot
The org.rhq.core.pc.plugin.CanonicalResourceKey#ancestorKeyTypePlugins is computed by doing while (parent != null) { KeyTypePlugin ktp = new KeyTypePlugin(parent.getResourceKey(), parent.getResourceType()); this.ancestorKeyTypePlugins.add(ktp); parent = parent.getParentResource(); } This will create a new KeyTypePlugin object for every parent, which by itself is not problematic. Unfortunately when you have platform->server->service->services1..10 You will end up with 3 KTP for p/s/s for each of the services1..10 even if they are effectively the same for all of the services 1..10. For a case with 30k resources on an agent this can easily add up to 100k KTP objects where 30k of them repeatedly describe the platform. 33k CanonicalResourceKey objects currently (without making KTP a static inner class) allocate 7MB heap, where the KTPs take 4MB out of that.
Bump the target version now that 4.11 is out.