Tabnine Logo
ProportionalCapacityPreemptionPolicy.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
org.apache.hadoop.yarn.server.resourcemanager.monitor.capacity.ProportionalCapacityPreemptionPolicy
constructor

Best Java code snippets using org.apache.hadoop.yarn.server.resourcemanager.monitor.capacity.ProportionalCapacityPreemptionPolicy.<init> (Showing top 13 results out of 315)

origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 super.setup();
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 super.setup();
 rc = new DominantResourceCalculator();
 when(cs.getResourceCalculator()).thenReturn(rc);
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

ProportionalCapacityPreemptionPolicy buildPolicy(int[][] qData) {
 ProportionalCapacityPreemptionPolicy policy = new ProportionalCapacityPreemptionPolicy(
   rmContext, mCS, mClock);
 clusterResources = Resource.newInstance(
   leafAbsCapacities(qData[0], qData[7]), 0);
 ParentQueue mRoot = buildMockRootQueue(rand, qData);
 when(mCS.getRootQueue()).thenReturn(mRoot);
 setResourceAndNodeDetails();
 return policy;
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 rc = new DefaultResourceCalculator();
 super.setup();
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 super.setup();
 conf.setBoolean(
   CapacitySchedulerConfiguration.INTRAQUEUE_PREEMPTION_ENABLED, true);
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 super.setup();
 conf.setBoolean(
   CapacitySchedulerConfiguration.INTRAQUEUE_PREEMPTION_ENABLED, true);
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 super.setup();
 conf.setBoolean(
   CapacitySchedulerConfiguration.INTRAQUEUE_PREEMPTION_ENABLED, true);
 rc = new DominantResourceCalculator();
 when(cs.getResourceCalculator()).thenReturn(rc);
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 super.setup();
 conf.setBoolean(
   CapacitySchedulerConfiguration.INTRAQUEUE_PREEMPTION_ENABLED, true);
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

@Before
public void setup() {
 super.setup();
 conf.setBoolean(
   CapacitySchedulerConfiguration.PREEMPTION_SELECT_CANDIDATES_FOR_RESERVED_CONTAINERS,
   true);
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs, mClock);
}
origin: ch.cern.hadoop/hadoop-yarn-server-resourcemanager

ProportionalCapacityPreemptionPolicy buildPolicy(int[][] qData) {
 ProportionalCapacityPreemptionPolicy policy =
  new ProportionalCapacityPreemptionPolicy(conf, rmContext, mCS, mClock);
 clusterResources =
   Resource.newInstance(leafAbsCapacities(qData[0], qData[7]), 0);
 ParentQueue mRoot = buildMockRootQueue(rand, qData);
 when(mCS.getRootQueue()).thenReturn(mRoot);
 setResourceAndNodeDetails();
 return policy;
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

public void buildEnv(String labelsConfig, String nodesConfig,
  String queuesConfig, String appsConfig,
  boolean useDominantResourceCalculator) throws IOException {
 if (useDominantResourceCalculator) {
  when(cs.getResourceCalculator()).thenReturn(
    new DominantResourceCalculator());
 }
 mockNodeLabelsManager(labelsConfig);
 mockSchedulerNodes(nodesConfig);
 for (NodeId nodeId : nodeIdToSchedulerNodes.keySet()) {
  when(cs.getSchedulerNode(nodeId)).thenReturn(
    nodeIdToSchedulerNodes.get(nodeId));
 }
 List<FiCaSchedulerNode> allNodes = new ArrayList<>(
   nodeIdToSchedulerNodes.values());
 when(cs.getAllNodes()).thenReturn(allNodes);
 ParentQueue root = mockQueueHierarchy(queuesConfig);
 when(cs.getRootQueue()).thenReturn(root);
 when(cs.getClusterResource()).thenReturn(clusterResource);
 mockApplications(appsConfig);
 policy = new ProportionalCapacityPreemptionPolicy(rmContext, cs,
   mClock);
}
origin: ch.cern.hadoop/hadoop-yarn-server-resourcemanager

ProportionalCapacityPreemptionPolicy buildPolicy(int[][] qData,
  String[][] resData, boolean useDominantResourceCalculator) {
 if (useDominantResourceCalculator) {
  when(mCS.getResourceCalculator()).thenReturn(
    new DominantResourceCalculator());
 }
 ProportionalCapacityPreemptionPolicy policy = new ProportionalCapacityPreemptionPolicy(
   conf, rmContext, mCS, mClock);
 clusterResources = leafAbsCapacities(parseResourceDetails(resData[0]),
   qData[2]);
 ParentQueue mRoot = buildMockRootQueue(rand, resData, qData);
 when(mCS.getRootQueue()).thenReturn(mRoot);
 setResourceAndNodeDetails();
 return policy;
}
origin: org.apache.hadoop/hadoop-yarn-server-resourcemanager

ProportionalCapacityPreemptionPolicy buildPolicy(int[][] qData,
  String[][] resData, boolean useDominantResourceCalculator) {
 if (useDominantResourceCalculator) {
  when(mCS.getResourceCalculator()).thenReturn(
    new DominantResourceCalculator());
 }
 ProportionalCapacityPreemptionPolicy policy =
   new ProportionalCapacityPreemptionPolicy(rmContext, mCS, mClock);
 clusterResources = leafAbsCapacities(parseResourceDetails(resData[0]),
   qData[2]);
 ParentQueue mRoot = buildMockRootQueue(rand, resData, qData);
 when(mCS.getRootQueue()).thenReturn(mRoot);
 setResourceAndNodeDetails();
 return policy;
}
org.apache.hadoop.yarn.server.resourcemanager.monitor.capacityProportionalCapacityPreemptionPolicy<init>

Popular methods of ProportionalCapacityPreemptionPolicy

  • cloneQueues
    This method walks a tree of CSQueue and clones the portion of the state relevant for preemption in T
  • containerBasedPreemptOrKill
    This method selects and tracks containers to be preemptionCandidates. If a container is in the targe
  • init
  • logToCSV
  • sortContainers
    Compare by reversed priority order first, and then reversed containerId order
  • computeFixpointAllocation
    Given a set of queues compute the fix-point distribution of unassigned resources among them. As pend
  • computeIdealResourceDistribution
    This method computes (for a single level in the tree, passed as a List) the ideal assignment of reso
  • editSchedule
  • getContainersToPreempt
    Based a resource preemption target drop reservations of containers and if necessary select container
  • getMostUnderservedQueues
  • getNonLabeledResources
    This method returns all non labeled resources.
  • getResourceCalculator
  • getNonLabeledResources,
  • getResourceCalculator,
  • isLabeledContainer,
  • preemptAMContainers,
  • preemptFrom,
  • recursivelyComputeIdealAssignment,
  • resetCapacity,
  • setNodeLabels,
  • addTempQueuePartition

Popular in Java

  • Start an intent from android
  • setContentView (Activity)
  • startActivity (Activity)
  • putExtra (Intent)
  • FlowLayout (java.awt)
    A flow layout arranges components in a left-to-right flow, much like lines of text in a paragraph. F
  • Calendar (java.util)
    Calendar is an abstract base class for converting between a Date object and a set of integer fields
  • Locale (java.util)
    Locale represents a language/country/variant combination. Locales are used to alter the presentatio
  • DataSource (javax.sql)
    An interface for the creation of Connection objects which represent a connection to a database. This
  • StringUtils (org.apache.commons.lang)
    Operations on java.lang.String that arenull safe. * IsEmpty/IsBlank - checks if a String contains
  • Project (org.apache.tools.ant)
    Central representation of an Ant project. This class defines an Ant project with all of its targets,
  • Top plugins for WebStorm
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now