private static JVMStatisticsProbe initJVMStatisticsProbe() {
String statisticsProbeClass = System.getProperty("gs.admin.jvm.probe.statistics");
if (statisticsProbeClass != null)
return tryCreateInstance(statisticsProbeClass);
try {
JVMStatisticsProbe result = new SigarJVMStatisticsProbe();
result.probeStatistics();
return result;
} catch (Throwable t) {
LogHelper.log(_loggerName, Level.FINE, "Trying to load sigar failed", t);
}
try {
JVMStatisticsProbe result = new JMXJVMStatisticsProbe();
result.probeStatistics();
return result;
} catch (Throwable t) {
LogHelper.log(_loggerName, Level.FINE, "Trying to load JMX failed", t);
}
return null;
}