code: protected boolean stopEchoService() {
      return Optional.ofNullable(getEchoService()).map(localEchoService -> {
  
        localEchoService.shutdown();
  
        try {
          if (!localEchoService.awaitTermination(30, TimeUnit.SECONDS)) {
            localEchoService.shutdownNow();
  
            if (!localEchoService.awaitTermination(30, TimeUnit.SECONDS)) {
              getLogger().warning("Failed to shutdown EchoService");
            }
          }
        }
        catch (InterruptedException ignore) {
          Thread.currentThread().interrupt();
        }
  
        return localEchoService.isShutdown();
  
      }).orElse(false);
    }
docs: Stops the Echo Service, taking it offline and out-of-service.
  
  @return a boolean value indicating whether the Echo Service has been shutdown successfully.
  @see #getEchoService()