void () { try { myMemoryPoolMXBeansFuture.get(); ((NotificationEmitter)ManagementFactory.getMemoryMXBean()).removeNotificationListener(myLowMemoryListener); } catch (Exception e) { getLogger().error(e); } synchronized (myJanitor) { if (mySubmitted != null) { mySubmitted.cancel(false); mySubmitted = null; } } LowMemoryWatcher.stopAll(); }