当前位置: 首页>>代码示例>>Java>>正文


Java NMClientImpl类代码示例

本文整理汇总了Java中org.apache.hadoop.yarn.client.api.impl.NMClientImpl的典型用法代码示例。如果您正苦于以下问题:Java NMClientImpl类的具体用法?Java NMClientImpl怎么用?Java NMClientImpl使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。


NMClientImpl类属于org.apache.hadoop.yarn.client.api.impl包,在下文中一共展示了NMClientImpl类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: StormAMRMClient

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
public StormAMRMClient(ApplicationAttemptId appAttemptId,
                       @SuppressWarnings("rawtypes") Map storm_conf,
                       YarnConfiguration hadoopConf) {
  this.appAttemptId = appAttemptId;
  this.storm_conf = storm_conf;
  this.hadoopConf = hadoopConf;
  Integer pri = Utils.getInt(storm_conf.get(Config.MASTER_CONTAINER_PRIORITY));
  this.DEFAULT_PRIORITY.setPriority(pri);
  this.containers = new TreeSet<Container>();
  numSupervisors = new AtomicInteger(0);

  // start am nm client
  nmClient = (NMClientImpl) NMClient.createNMClient();
  nmClient.init(hadoopConf);
  nmClient.start();
}
 
开发者ID:yahoo,项目名称:storm-yarn,代码行数:17,代码来源:StormAMRMClient.java

示例2: serviceStop

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
@Override
protected void serviceStop() throws Exception {
  if (stopped.getAndSet(true)) {
    // return if already stopped
    return;
  }
  if (eventDispatcherThread != null) {
    eventDispatcherThread.interrupt();
    try {
      eventDispatcherThread.join();
    } catch (InterruptedException e) {
      LOG.error("The thread of " + eventDispatcherThread.getName() +
                " didn't finish normally.", e);
    }
  }
  if (threadPool != null) {
    threadPool.shutdownNow();
  }
  if (client != null) {
    // If NMClientImpl doesn't stop running containers, the states doesn't
    // need to be cleared.
    if (!(client instanceof NMClientImpl) ||
        ((NMClientImpl) client).getCleanupRunningContainers().get()) {
      if (containers != null) {
        containers.clear();
      }
    }
    client.stop();
  }
  super.serviceStop();
}
 
开发者ID:naver,项目名称:hadoop,代码行数:32,代码来源:NMClientAsyncImpl.java

示例3: StormAMRMClient

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
public StormAMRMClient(ApplicationAttemptId appAttemptID, @SuppressWarnings("rawtypes") Map storm_conf,
		YarnConfiguration hadoopConf) {
	this.appAttemptId = appAttemptID;
    this.storm_conf = storm_conf;
    this.hadoopConf = hadoopConf;
    Integer pri = Utils.getInt(storm_conf.get(Config.MASTER_CONTAINER_PRIORITY));
    this.DEFAULT_PRIORITY.setPriority(pri);
    this.containers = new TreeSet<Container>();
    numSupervisors = new AtomicInteger(0);

    // start am nm client
    nmClient = (NMClientImpl) NMClient.createNMClient();
    nmClient.init(hadoopConf);
    nmClient.start();
}
 
开发者ID:zhangjunfang,项目名称:jstorm-0.9.6.3-,代码行数:16,代码来源:StormAMRMClient.java

示例4: createNMClient

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
/**
 * Create a new instance of NMClient.
 */
@Public
public static NMClient createNMClient() {
  NMClient client = new NMClientImpl();
  return client;
}
 
开发者ID:naver,项目名称:hadoop,代码行数:9,代码来源:NMClient.java

示例5: NMClientAsyncImpl

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
public NMClientAsyncImpl(String name, CallbackHandler callbackHandler) {
  this(name, new NMClientImpl(), callbackHandler);
}
 
开发者ID:naver,项目名称:hadoop,代码行数:4,代码来源:NMClientAsyncImpl.java

示例6: NMClientAsync

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
protected NMClientAsync(String name, CallbackHandler callbackHandler) {
  this (name, new NMClientImpl(), callbackHandler);
}
 
开发者ID:naver,项目名称:hadoop,代码行数:4,代码来源:NMClientAsync.java

示例7: NMClientAsyncImpl

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
public NMClientAsyncImpl(
    String name, AbstractCallbackHandler callbackHandler) {
  this(name, new NMClientImpl(), callbackHandler);
}
 
开发者ID:aliyun-beta,项目名称:aliyun-oss-hadoop-fs,代码行数:5,代码来源:NMClientAsyncImpl.java

示例8: NMClientAsync

import org.apache.hadoop.yarn.client.api.impl.NMClientImpl; //导入依赖的package包/类
protected NMClientAsync(
    String name, AbstractCallbackHandler callbackHandler) {
  this (name, new NMClientImpl(), callbackHandler);
}
 
开发者ID:aliyun-beta,项目名称:aliyun-oss-hadoop-fs,代码行数:5,代码来源:NMClientAsync.java


注:本文中的org.apache.hadoop.yarn.client.api.impl.NMClientImpl类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。