3 Replies Latest reply on May 14, 2013 4:50 AM by edelacruz

    Agent plugins using the EventManager is showing an error on shutdown

    edelacruz

      I have encountered this error log on the agent shutdown:

       

      2013-05-14 09:37:02,807 ERROR [ResourceContainer.invoker.daemon-2] (rhq.core.pc.event.EventManager)- Failed to remove poller with PollerKey[resourceId=10761, eventType=SnmpTrap] from thread pool.

       

      Is this something I should be concerned about? Is there something I can do on the configuration that will stop the agent on showing this error on the logs?

       

      Thanks!

        • 1. Re: Agent plugins using the EventManager is showing an error on shutdown
          mazz

          I think you can ignore that. That appears to be a message that has been coming out of the agent shutdown for many years - I found it in this forum post from 2009  So I'll assume it can be ignored.

          • 2. Re: Agent plugins using the EventManager is showing an error on shutdown
            mazz

            for the record, this is coming from EventManager.unregisterEventPoller:

             

                void unregisterEventPoller(Resource resource, String eventType, String sourceLocation) {

                    PollerKey pollerKey = new PollerKey(resource.getId(), eventType, sourceLocation);

                    if (this.pollerThreads.containsKey(pollerKey)) {

                        Runnable pollerThread = this.pollerThreads.get(pollerKey);

                        boolean wasRemoved = this.pollerThreadPool.remove(pollerThread);

                        if (!wasRemoved) {

                            log.error("Failed to remove poller with " + pollerKey + " from thread pool.");

                        }

                        this.pollerThreads.remove(pollerKey);

                    }

                }

             

            This ends up being called from some plugin components' stop() methods - so this doesn't seem like anything to be concerned about.  We could probably be smarter here - the thread pool might have been shutdown already and so remove returned false??? I dunno, but its during shutdown anyway, so I wouldn't worry about it. When the agent starts the components back up, it will reconstitute the thread pool and the pollers.

            1 of 1 people found this helpful
            • 3. Re: Agent plugins using the EventManager is showing an error on shutdown
              edelacruz

              Thanks mazz!