gpt4 book ai didi

ml.shifu.guagua.coordinator.zk.ZooKeeperUtils.startEmbedZooKeeper()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-13 12:41:58 26 4
gpt4 key购买 nike

本文整理了Java中ml.shifu.guagua.coordinator.zk.ZooKeeperUtils.startEmbedZooKeeper()方法的一些代码示例,展示了ZooKeeperUtils.startEmbedZooKeeper()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ZooKeeperUtils.startEmbedZooKeeper()方法的具体详情如下:
包路径:ml.shifu.guagua.coordinator.zk.ZooKeeperUtils
类名称:ZooKeeperUtils
方法名:startEmbedZooKeeper

ZooKeeperUtils.startEmbedZooKeeper介绍

[英]Start embed zookeeper server in a daemon thread.
[中]在守护进程线程中启动嵌入zookeeper服务器。

代码示例

代码示例来源:origin: ml.shifu/guagua-mapreduce

/**
 * Start zookeeper server in thread of master node.
 */
private String startZookeeperServer(String localHostName) {
  int embedZkClientPort = 0;
  try {
    embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
  } catch (IOException e) {
    throw new RuntimeException(e);
  }
  // 2. check if it is started.
  ZooKeeperUtils.checkIfEmbedZooKeeperStarted(embedZkClientPort);
  return localHostName + ":" + embedZkClientPort;
}

代码示例来源:origin: ShifuML/guagua

/**
 * Start zookeeper server in thread of master node.
 */
private String startZookeeperServer(String localHostName) {
  int embedZkClientPort = 0;
  try {
    embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
  } catch (IOException e) {
    throw new RuntimeException(e);
  }
  // 2. check if it is started.
  ZooKeeperUtils.checkIfEmbedZooKeeperStarted(embedZkClientPort);
  return localHostName + ":" + embedZkClientPort;
}

代码示例来源:origin: ml.shifu/guagua-yarn

/**
 * Start zookeeper server in thread of master node.
 */
private String startZookeeperServer(String localHostName) {
  int embedZkClientPort = 0;
  try {
    embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
  } catch (IOException e) {
    throw new RuntimeException(e);
  }
  // 2. check if it is started.
  ZooKeeperUtils.checkIfEmbedZooKeeperStarted(embedZkClientPort);
  return localHostName + ":" + embedZkClientPort;
}

代码示例来源:origin: ShifuML/guagua

/**
 * Start zookeeper server in thread of master node.
 */
private String startZookeeperServer(String localHostName) {
  int embedZkClientPort = 0;
  try {
    embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
  } catch (IOException e) {
    throw new RuntimeException(e);
  }
  // 2. check if it is started.
  ZooKeeperUtils.checkIfEmbedZooKeeperStarted(embedZkClientPort);
  return localHostName + ":" + embedZkClientPort;
}

代码示例来源:origin: ShifuML/guagua

embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
} catch (IOException e) {
  throw new RuntimeException(e);

代码示例来源:origin: ml.shifu/guagua-yarn

embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
} catch (IOException e) {
  throw new RuntimeException(e);

代码示例来源:origin: ml.shifu/guagua-mapreduce

embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
} catch (IOException e) {
  throw new RuntimeException(e);

代码示例来源:origin: ShifuML/guagua

embedZkClientPort = ZooKeeperUtils.startEmbedZooKeeper();
} catch (IOException e) {
  throw new RuntimeException(e);

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com