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


Java NMLivelinessMonitor.start方法代码示例

本文整理汇总了Java中org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor.start方法的典型用法代码示例。如果您正苦于以下问题:Java NMLivelinessMonitor.start方法的具体用法?Java NMLivelinessMonitor.start怎么用?Java NMLivelinessMonitor.start使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor的用法示例。


在下文中一共展示了NMLivelinessMonitor.start方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: setUp

import org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor; //导入方法依赖的package包/类
@Before
public void setUp() {
  Configuration conf = new Configuration();
  // Dispatcher that processes events inline
  Dispatcher dispatcher = new InlineDispatcher();
  RMContext context = new RMContextImpl(dispatcher, null,
      null, null, null, null, null, null, null, null);
  dispatcher.register(SchedulerEventType.class,
      new InlineDispatcher.EmptyEventHandler());
  dispatcher.register(RMNodeEventType.class,
      new NodeEventDispatcher(context));
  NMLivelinessMonitor nmLivelinessMonitor = new TestNmLivelinessMonitor(
      dispatcher);
  nmLivelinessMonitor.init(conf);
  nmLivelinessMonitor.start();
  NodesListManager nodesListManager = new NodesListManager(context);
  nodesListManager.init(conf);
  RMContainerTokenSecretManager containerTokenSecretManager =
      new RMContainerTokenSecretManager(conf);
  containerTokenSecretManager.start();
  NMTokenSecretManagerInRM nmTokenSecretManager =
      new NMTokenSecretManagerInRM(conf);
  nmTokenSecretManager.start();
  resourceTrackerService = new ResourceTrackerService(context,
      nodesListManager, nmLivelinessMonitor, containerTokenSecretManager,
      nmTokenSecretManager);
  
  resourceTrackerService.init(conf);
  resourceTrackerService.start();
}
 
开发者ID:naver,项目名称:hadoop,代码行数:31,代码来源:TestNMExpiry.java

示例2: setUp

import org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor; //导入方法依赖的package包/类
@Before
public void setUp() {
  Configuration conf = new Configuration();
  // Dispatcher that processes events inline
  Dispatcher dispatcher = new InlineDispatcher();

  dispatcher.register(RMNodeEventType.class,
      new TestRMNodeEventDispatcher());

  RMContext context = new RMContextImpl(dispatcher, null,
      null, null, null, null, null, null, null, null);
  dispatcher.register(SchedulerEventType.class,
      new InlineDispatcher.EmptyEventHandler());
  dispatcher.register(RMNodeEventType.class,
      new NodeEventDispatcher(context));
  NMLivelinessMonitor nmLivelinessMonitor = new NMLivelinessMonitor(
      dispatcher);
  nmLivelinessMonitor.init(conf);
  nmLivelinessMonitor.start();
  NodesListManager nodesListManager = new NodesListManager(context);
  nodesListManager.init(conf);
  RMContainerTokenSecretManager containerTokenSecretManager =
      new RMContainerTokenSecretManager(conf);
  containerTokenSecretManager.start();
  NMTokenSecretManagerInRM nmTokenSecretManager =
      new NMTokenSecretManagerInRM(conf);
  nmTokenSecretManager.start();
  resourceTrackerService = new ResourceTrackerService(context,
      nodesListManager, nmLivelinessMonitor, containerTokenSecretManager,
      nmTokenSecretManager);
  
  resourceTrackerService.init(conf);
  resourceTrackerService.start();
}
 
开发者ID:naver,项目名称:hadoop,代码行数:35,代码来源:TestNMReconnect.java

示例3: setUp

import org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor; //导入方法依赖的package包/类
@Before
public void setUp() {
  Configuration conf = new Configuration();
  // Dispatcher that processes events inline
  dispatcher = new InlineDispatcher();

  dispatcher.register(RMNodeEventType.class,
      new TestRMNodeEventDispatcher());

  context = new RMContextImpl(dispatcher, null,
      null, null, null, null, null, null, null, null);
  dispatcher.register(SchedulerEventType.class,
      new InlineDispatcher.EmptyEventHandler());
  dispatcher.register(RMNodeEventType.class,
      new NodeEventDispatcher(context));
  NMLivelinessMonitor nmLivelinessMonitor = new NMLivelinessMonitor(
      dispatcher);
  nmLivelinessMonitor.init(conf);
  nmLivelinessMonitor.start();
  NodesListManager nodesListManager = new NodesListManager(context);
  nodesListManager.init(conf);
  RMContainerTokenSecretManager containerTokenSecretManager =
      new RMContainerTokenSecretManager(conf);
  containerTokenSecretManager.start();
  NMTokenSecretManagerInRM nmTokenSecretManager =
      new NMTokenSecretManagerInRM(conf);
  nmTokenSecretManager.start();
  resourceTrackerService = new ResourceTrackerService(context,
      nodesListManager, nmLivelinessMonitor, containerTokenSecretManager,
      nmTokenSecretManager);
  
  resourceTrackerService.init(conf);
  resourceTrackerService.start();
}
 
开发者ID:aliyun-beta,项目名称:aliyun-oss-hadoop-fs,代码行数:35,代码来源:TestNMReconnect.java

示例4: setUp

import org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor; //导入方法依赖的package包/类
@Before
public void setUp() {
  Configuration conf = new Configuration();
  // Dispatcher that processes events inline
  Dispatcher dispatcher = new InlineDispatcher();
  RMContext context = new RMContextImpl(dispatcher, null,
      null, null, null, null, null, null, null);
  dispatcher.register(SchedulerEventType.class,
      new InlineDispatcher.EmptyEventHandler());
  dispatcher.register(RMNodeEventType.class,
      new NodeEventDispatcher(context));
  NMLivelinessMonitor nmLivelinessMonitor = new TestNmLivelinessMonitor(
      dispatcher);
  nmLivelinessMonitor.init(conf);
  nmLivelinessMonitor.start();
  NodesListManager nodesListManager = new NodesListManager(context);
  nodesListManager.init(conf);
  RMContainerTokenSecretManager containerTokenSecretManager =
      new RMContainerTokenSecretManager(conf);
  containerTokenSecretManager.start();
  NMTokenSecretManagerInRM nmTokenSecretManager =
      new NMTokenSecretManagerInRM(conf);
  nmTokenSecretManager.start();
  resourceTrackerService = new ResourceTrackerService(context,
      nodesListManager, nmLivelinessMonitor, containerTokenSecretManager,
      nmTokenSecretManager);
  
  resourceTrackerService.init(conf);
  resourceTrackerService.start();
}
 
开发者ID:ict-carch,项目名称:hadoop-plus,代码行数:31,代码来源:TestNMExpiry.java

示例5: setUp

import org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor; //导入方法依赖的package包/类
@Before
public void setUp() throws IOException {
  Configuration conf = new Configuration();
  RMStorageFactory.setConfiguration(conf);
  YarnAPIStorageFactory.setConfiguration(conf);
  DBUtility.InitializeDB();
  // Dispatcher that processes events inline
  dispatcher = new InlineDispatcher();

  dispatcher.register(RMNodeEventType.class,
      new TestRMNodeEventDispatcher());

  context = new RMContextImpl(dispatcher, null,
      null, null, null, null, null, null, null, null);
  dispatcher.register(SchedulerEventType.class,
      new InlineDispatcher.EmptyEventHandler());
  dispatcher.register(RMNodeEventType.class,
      new NodeEventDispatcher(context));
  NMLivelinessMonitor nmLivelinessMonitor = new NMLivelinessMonitor(
      dispatcher);
  nmLivelinessMonitor.init(conf);
  nmLivelinessMonitor.start();
  NodesListManager nodesListManager = new NodesListManager(context);
  nodesListManager.init(conf);
  RMContainerTokenSecretManager containerTokenSecretManager =
      new RMContainerTokenSecretManager(conf);
  containerTokenSecretManager.start();
  NMTokenSecretManagerInRM nmTokenSecretManager =
      new NMTokenSecretManagerInRM(conf);
  nmTokenSecretManager.start();
  resourceTrackerService = new ResourceTrackerService(context,
      nodesListManager, nmLivelinessMonitor, containerTokenSecretManager,
      nmTokenSecretManager);
  
  resourceTrackerService.init(conf);
  resourceTrackerService.start();
}
 
开发者ID:hopshadoop,项目名称:hops,代码行数:38,代码来源:TestNMReconnect.java

示例6: getPrivateResourceTrackerService

import org.apache.hadoop.yarn.server.resourcemanager.NMLivelinessMonitor; //导入方法依赖的package包/类
private ResourceTrackerService getPrivateResourceTrackerService(
    Dispatcher privateDispatcher, ResourceManager rm,
    SleepHandler sleepHandler) {
  Configuration conf = getConf();

  RMContext privateContext =
      new RMContextImpl(privateDispatcher, null, null, null, null, null, null,
          null, null, null);
  privateContext.setNodeLabelManager(Mockito.mock(RMNodeLabelsManager.class));

  privateDispatcher.register(SchedulerEventType.class, sleepHandler);
  privateDispatcher.register(SchedulerEventType.class,
      rm.getResourceScheduler());
  privateDispatcher.register(RMNodeEventType.class,
      new ResourceManager.NodeEventDispatcher(privateContext));
  ((Service) privateDispatcher).init(conf);
  ((Service) privateDispatcher).start();
  NMLivelinessMonitor nmLivelinessMonitor =
      new NMLivelinessMonitor(privateDispatcher);
  nmLivelinessMonitor.init(conf);
  nmLivelinessMonitor.start();
  NodesListManager nodesListManager = new NodesListManager(privateContext);
  nodesListManager.init(conf);
  RMContainerTokenSecretManager containerTokenSecretManager =
      new RMContainerTokenSecretManager(conf);
  containerTokenSecretManager.start();
  NMTokenSecretManagerInRM nmTokenSecretManager =
      new NMTokenSecretManagerInRM(conf);
  nmTokenSecretManager.start();
  ResourceTrackerService privateResourceTrackerService =
      new ResourceTrackerService(privateContext, nodesListManager,
          nmLivelinessMonitor, containerTokenSecretManager,
          nmTokenSecretManager);
  privateResourceTrackerService.init(conf);
  privateResourceTrackerService.start();
  rm.getResourceScheduler().setRMContext(privateContext);
  return privateResourceTrackerService;
}
 
开发者ID:hopshadoop,项目名称:hops,代码行数:39,代码来源:TestAbstractYarnScheduler.java


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