Package org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair

Examples of org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.AllocationFileLoaderService


  public void refreshDefaultQueue(Configuration conf, String userName)
      throws IOException {
    String requestedQueue = YarnConfiguration.DEFAULT_QUEUE_NAME;
    final AtomicReference<AllocationConfiguration> allocConf = new AtomicReference<AllocationConfiguration>();

    AllocationFileLoaderService allocsLoader = new AllocationFileLoaderService();
    allocsLoader.init(conf);
    allocsLoader.setReloadListener(new AllocationFileLoaderService.Listener() {
      @Override
      public void onReload(AllocationConfiguration allocs) {
        allocConf.set(allocs);
      }
    });
    try {
      allocsLoader.reloadAllocations();
    } catch (Exception ex) {
      throw new IOException("Failed to load queue allocations", ex);
    }
    if (allocConf.get() == null) {
      allocConf.set(new AllocationConfiguration(conf));
View Full Code Here

TOP

Related Classes of org.apache.hadoop.yarn.server.resourcemanager.scheduler.fair.AllocationFileLoaderService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.