Config Tester Tool doesn't check some of the core configuration files

Description

The classes that handle the thresholds configuration are part of the OpenNMS Core package. For this reason, I can't see why the config-tester tool doesn't check threshd-configuration.xml and thresholds.xml, as these two files are very important. For similar reasons, collectd-configuration.xml and poller-configuration.xml should be checked as well.

/opt/opennms/bin/config-tester-l

I can understand that the tool won't check the files that are NOT part of OpenNMS Core, but for the Core components, all files should be tested.

Acceptance / Success Criteria

None

Lucidchart Diagrams

Activity

Show:

Jesse White April 13, 2016 at 11:08 AM

I removed Meridian-2015.1.2 from the fix version since the PR was targeted to foundation-2016.

Please cherry pick this to foundation if you want the fix in Meridian-2015.1.2 as well.

Alejandro Galue April 13, 2016 at 9:15 AM

Alejandro Galue April 12, 2016 at 9:20 AM
Edited

Same logic applies to collectd-configuration.xml and poller-configuration.xml. It uses FilterDaoFactory and because of this, that is another core file that is not being tested.

Alejandro Galue April 12, 2016 at 9:18 AM

Actually, it uses FilterDaoFactory. Having a mock implementation for that factory will remove the need of accessing the DB.

Alejandro Galue April 12, 2016 at 9:13 AM

Looking at /opennms-config-tester/src/main/resources/META-INF/opennms/applicationContext-configTester.xml, I can see that threshd-configuration.xml is not tested because it requires DB access. As this is just an XML validation tool, I think we can have a Mock DBLayer/FilterDao just to be able to parse the files that require DB access, specially because sometimes, if there are issues with those files, OpenNMS can become unstable or won't start.

Fixed

Details

Assignee

Reporter

Labels

Components

Affects versions

Priority

PagerDuty

Created April 7, 2016 at 8:46 AM
Updated April 13, 2016 at 3:07 PM
Resolved April 13, 2016 at 11:08 AM