code: @Override
      public synchronized void deactivate() throws InterruptedException, CouldNotPerformException {
          manageLock.lockWrite(this);
          try {
              try {
                  validateInitialization();
              } catch (InvalidStateException ex) {
                  // was never initialized!
                  return;
              }
  
              // skip initial data sync if still running
              if (initialDataSyncFuture != null && !initialDataSyncFuture.isDone()) {
                  initialDataSyncFuture.cancel(true);
              }
  
              logger.debug("Deactivate AbstractControllerServer for: " + this);
              // The order is important: The informer publishes a zero event when the availabilityState is set to deactivating which leads remotes to disconnect
              // The remotes try to reconnect again and start a requestData. If the server is still active it will respond
              // and the remotes will think that the server is still there..
              if (serverWatchDog != null) {
                  serverWatchDog.deactivate();
              }
              // inform remotes about deactivation
              setAvailabilityState(DEACTIVATING);
              if (informerWatchDog != null) {
                  informerWatchDog.deactivate();
              }
              setAvailabilityState(OFFLINE);
          } finally {
              manageLock.unlockWrite(this);
          }
      }
docs: {@inheritDoc}
  
  @throws InterruptedException     {@inheritDoc}
  @throws CouldNotPerformException {@inheritDoc}