code: public final void shutdown() throws IOException {
      if (this.shutdown) {
        return;
      }
      this.shutdown0();
      this.shutdown = true;
      this.connector.shuttingDown();
      this.connector.quitAllSessions();
      this.connector.stop();
      this.memcachedHandler.stop();
      XMemcachedMbeanServer.getInstance().shutdown();
      if (AddrUtil.isEnableShutDownHook() && !this.isHutdownHookCalled) {
        try {
          Runtime.getRuntime().removeShutdownHook(this.shutdownHookThread);
        } catch (Exception e) {
          // ignore;
        }
      }
    }
docs: /*
  (non-Javadoc)
  
  @see net.rubyeye.xmemcached.MemcachedClient#shutdown()