@Override public synchronized void stop() { // unregister LensEventService eventService = LensServices.get().getService(LensEventService.NAME); if (eventService != null) { eventService.removeListener(queryStatusListener); } if (queryStatusListener != null) { queryStatusListener.stop(); } if (reporters != null) { for (ScheduledReporter reporter : reporters) { reporter.stop(); } } log.info("Stopped metrics service"); super.stop(); }