class ZpeMetric {

    ZpeMetric() {
        File directory = new File(String.valueOf(getFilePath()));
        //noinspection ResultOfMethodCallIgnored
        directory.mkdir();
        //setting the timer to the interval specified in the system property
        if (statsEnabled) {
            Integer interval = Integer.parseInt(System.getProperty(ZpeConsts.ZPE_PROP_METRIC_WRITE_INTERVAL, ZPE_WRITE_INTERVAL));
            Timer timer = FETCH_TIMER;
            if (timer == null) {
                synchronized (TIMER_LOCK) {
                    timer = FETCH_TIMER;
                    if (timer == null) {
                        timer = new Timer();
                        timer.schedule(new SchedulerService(), interval, interval);
                        FETCH_TIMER = timer;
                    }
                }
            }
        }
    }

      ZpeMetric();

}