/** * @param e Error. */ private void stop0(Throwable e) { if (!stop.compareAndSet(false, true)) return; ZkRuntimeState rtState = this.rtState; if (rtState.zkClient != null && rtState.locNodeZkPath != null && rtState.zkClient.connected()) { try { rtState.zkClient.deleteIfExistsNoRetry(rtState.locNodeZkPath, -1); } catch (Exception err) { if (log.isDebugEnabled()) log.debug("Failed to delete local node's znode on stop: " + err); } } IgniteCheckedException err = new IgniteCheckedException("Node stopped."); synchronized (stateMux) { connState = ConnectionState.STOPPED; rtState.onCloseStart(err); } IgniteUtils.shutdownNow(ZookeeperDiscoveryImpl.class, utilityPool, log); busyLock.block(); busyLock.unblock(); joinFut.onDone(e); ZookeeperClient zkClient = rtState.zkClient; if (zkClient != null) zkClient.close(); finishFutures(err); }
IgniteUtils.shutdownNow(ServerImpl.class, utilityPool, log);
IgniteUtils.shutdownNow(ServerImpl.class, utilityPool, log);