if (initalized)
return;
try
{
PollScheduler scheduler = PollScheduler.getInstance();
scheduler.start();
MetricObserver fileObserver = new FileMetricObserver("stats", new File("."));
MetricObserver transform = new CounterToRateMetricTransform(fileObserver, 2, TimeUnit.MINUTES);
PollRunnable task = new PollRunnable(new MonitorRegistryMetricPoller(), BasicMetricFilter.MATCH_ALL, transform);
scheduler.addPoller(task, 1, TimeUnit.MINUTES);
}
catch (Throwable e)
{
// dont do anything... just eat.
logger.error("Epic Plugin was not intialized: ", e);