code: public void stop() {
  
  		// Cancel the timer
  		this.logger.info( "The DM is about to be stopped." );
  		if( this.timer != null ) {
  			this.timer.cancel();
  			this.timer =  null;
  		}
  
  		// Save the instances
  		for( ManagedApplication ma : this.applicationMngr.getManagedApplications())
  			ConfigurationUtils.saveInstances( ma );
  
  		// Disable notifications to listeners
  		this.notificationMngr.disableNotifications();
  
  		// Stop the target configurator
  		this.targetConfigurator.stop();
  
  		// Stops listening to the debug queue.
  		if( this.messagingClient != null ) {
  			try {
  				this.messagingClient.listenToTheDm( ListenerCommand.STOP );
  
  			} catch ( IOException e ) {
  				this.logger.log( Level.WARNING, "Cannot stop to listen to the debug queue", e );
  			}
  
  			this.messagingClient.getMessageProcessor().stopProcessor();
  			this.messagingClient.getMessageProcessor().interrupt();
  			try {
  				this.messagingClient.closeConnection();
  
  			} catch( IOException e ) {
  				this.logger.warning( "The messaging client could not be terminated correctly. " + e.getMessage());
  				Utils.logException( this.logger, e );
  			}
  		}
  
  		this.logger.info( "The DM was stopped." );
  	}
docs: Stops the manager.
  <p>
  It is invoked by iPojo when an instance becomes INVALID.
  </p>