code: synchronized void stop(Integer timeout) {
          final InternalState required = this.requiredState;
          if(required != InternalState.STOPPED) {
              this.requiredState = InternalState.STOPPED;
              ROOT_LOGGER.stoppingServer(serverName);
              // Only send the stop operation if the server is started
              if (internalState == InternalState.SERVER_STARTED) {
                  internalSetState(new ServerStopTask(timeout), internalState, InternalState.PROCESS_STOPPING);
              } else {
                  transition(false);
              }
          }
      }
docs: Stop a managed server.