ThresholdingVisitor: create: Can't create ThresholdingVisitor for <IP ADDRESS>
Description
Acceptance / Success Criteria
Lucidchart Diagrams
Activity

Alejandro Galue November 22, 2010 at 9:59 AM
Fixed on revision 927640905432 for branch 1.8
The message content will be:
log.warn("create: Can't create ThresholdingVisitor for " + hostAddress + "/" + serviceName + " on node " + nodeId + ", because it has no configured thresholds.");

Alejandro Galue November 8, 2010 at 8:01 AM
You are right, there is no much detail on that.
This is a common message if you set thresholding-enabled=true for OpenNMS-JVM, but there is no threshold group defined on thresholds.xml associated to a node/service combination on threshd-configuration.xml
You can also get details by checking the warning or error messages related to ThresholdingSet.
This is the method used to create ThresholdingVisitor class:
public static ThresholdingVisitor create(int nodeId, String hostAddress, String serviceName, RrdRepository repo, Map<String,String> params, long interval) {
ThreadCategory log = ThreadCategory.getInstance(ThresholdingVisitor.class);
String enabled = params.get("thresholding-enabled");
if (enabled != null && !"true".equals(enabled)) {
log.info("create: Thresholds processing is not enabled. Check thresholding-enabled param on collectd package");
return null;
}
CollectorThresholdingSet thresholdingSet = new CollectorThresholdingSet(nodeId, hostAddress, serviceName, repo, interval);
if (thresholdingSet.hasThresholds()) {
return new ThresholdingVisitor(thresholdingSet);
}
log.warn("create: Can't create ThresholdingVisitor for " + hostAddress + "/" + serviceName + " for node " + nodeId + ", beacuse it has no configured thresholds.");
return null;
}
The method hasThresholds(), will examine the content of thresholds.xml to see if any threshold definition applies for this node/service combination.
As you can see, if the method called hasThresholds returns false, the message that you pointed out will be generated. We can change the message content to something like the above example.
What do you think?
I get log message like this in collectd.log with no explanation and no other evidence:
2010-11-05 12:30:34,586 WARN [CollectdScheduler-100 Pool-fiber0] ThresholdingVisitor: create: Can't create ThresholdingVisitor for 10.30.15.36/OpenNMS-JVM
2010-11-05 12:30:34,656 WARN [CollectdScheduler-100 Pool-fiber0] ThresholdingVisitor: create: Can't create ThresholdingVisitor for 10.30.15.35/OpenNMS-JVM