Pollerd takes too much time scheduling polling when OpenNMS starts

Description

On a customer installation, I noticed that OpenNMS takes too much time to start due to Pollerd.

I've never seen this before, but Pollerd takes around 15min to schedule polling for all the existing monitored services.

Acceptance / Success Criteria

None

Attachments

1

Lucidchart Diagrams

Activity

Show:

Alejandro Galue April 17, 2017 at 12:45 PM

It turns out that the changes from foundation-2016 are still valid in foundation-2017, they were just placed differently which caused the confusion. I've added an additional commit with the missing change.

Alejandro Galue April 17, 2017 at 11:08 AM

I'm going to merge foundation-2016 to foundation-2017 as I described above.

The main different in terms of updating the status is the following:

In foundation-2016 this is done by performing an actual DAO call (the main intention of this refactoring was avoid retrieving the object through the DAO as the object was already available, before perform the update+save). Now in foundation-2017 the update is performed by just calling PollableService.updateStatus, and I can't see DAO calls involved:

https://github.com/OpenNMS/opennms/blob/foundation-2017/opennms-services/src/main/java/org/opennms/netmgt/poller/pollables/PollableService.java#L302

After the merge, I'll repeat the tests to be sure that foundation-2017 doesn't suffer the same problem.

Alejandro Galue April 17, 2017 at 10:48 AM

You're welcome!

It turns out that in foundation-2017 the solution is different. I'll port the refactor of the code that is written twice, but I'll keep the logic for update the service status as it doesn't involve DAO calls in foundation-2017 (apparently). I'll repeat the tests on a VM with this branch to be sure.

Jesse White April 17, 2017 at 10:31 AM

I tested the patch again, works like a charm, I must of missed something the first time.

Thanks for resolving this one.

Alejandro Galue April 13, 2017 at 2:39 PM

Fixed

Details

Assignee

Reporter

Labels

Components

Sprint

Affects versions

Priority

PagerDuty

Created March 27, 2017 at 11:42 AM
Updated April 17, 2017 at 4:41 PM
Resolved April 17, 2017 at 10:32 AM