Description of problem: $Summary Version-Release number of selected component (if applicable): JON3.3.10 How reproducible: Always Steps to Reproduce: 1. install and start jon 3.3.10 2. uninventory whole platform contain storage node Actual results: in agent.log: 2018-01-31 04:58:04,044 ERROR [ResourceDiscoveryComponent.invoker.daemon-114] (org.rhq.plugins.agent.AgentDiscoveryComponent)- An error occurred while attempting to auto-discover the agent's own management interface java.lang.NullPointerException at org.rhq.plugins.agent.AgentDiscoveryComponent.getResourceKey(AgentDiscoveryComponent.java:133) at org.rhq.plugins.agent.AgentDiscoveryComponent.discoverResources(AgentDiscoveryComponent.java:76) at sun.reflect.GeneratedMethodAccessor30.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.rhq.core.pc.util.DiscoveryComponentProxyFactory$ComponentInvocationThread.call(DiscoveryComponentProxyFactory.java:305) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) in server.log: 11:20:56,488 ERROR [org.rhq.enterprise.server.alert.engine.internal.AlertConditionCacheCoordinator] (EJB default - 3) Could not find agent for scheduleId = 24669 Expected results: NPE should be fixed. Not sure if the error in server.log is expected Additional info: NPE in agent log is visible even when uninventoring platform without storage node. Error in server.log was visible only once, it's not visible when doing uninventory second time.
The NPE is visible in JON 3.3.9 but the ERROR in server log is not -> it's a regression.
In the master: commit 8c8f998a197e2aabe065772abbfa5820fb247ce1 (HEAD -> master) Author: Michael Burman <miburman> Date: Mon Jul 9 17:01:28 2018 +0300 [BZ 1540527] If parentResourceContext is not available, stop discovery of agent
Server log does not have any error, but in agent logs we can still see the error: ************************************ ERROR [ResourceDiscoveryComponent.invoker.daemon-4] (org.rhq.plugins.agent.AgentDiscoveryComponent)- An error occurred while attempting to auto-discover the agent's own management interface java.lang.NullPointerException at org.rhq.plugins.agent.AgentDiscoveryComponent.getResourceKey(AgentDiscoveryComponent.java:133) at org.rhq.plugins.agent.AgentDiscoveryComponent.discoverResources(AgentDiscoveryComponent.java:76) at sun.reflect.GeneratedMethodAccessor46.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.rhq.core.pc.util.DiscoveryComponentProxyFactory$ComponentInvocationThread.call(DiscoveryComponentProxyFactory.java:305) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) at java.lang.Thread.run(Thread.java:748) ************************************ Attached latest agent.log
Created attachment 1484734 [details] latest agent.log
That line number is from an old release, so either the agent wasn't updated or the build is missing something. Lines should be 136 & 79 for the first two items in the stack trace (133 is empty line in the current release/jon3.3.x)
Problem with co-located agent is that new plugins are not downloaded after upgrade until it's restarted or operation Update all plugins is manually executed. When the agent has new plugins the issue is not visible -> marking as verified
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2018:2930