Class PreemptionCandidatesSelector

java.lang.Object
org.apache.hadoop.yarn.server.resourcemanager.monitor.capacity.PreemptionCandidatesSelector
Direct Known Subclasses:
FifoCandidatesSelector, IntraQueueCandidatesSelector, QueuePriorityContainerCandidateSelector, ReservedContainerCandidatesSelector

public abstract class PreemptionCandidatesSelector extends Object
  • Field Details

  • Method Details

    • selectCandidates

      public abstract Map<org.apache.hadoop.yarn.api.records.ApplicationAttemptId,Set<RMContainer>> selectCandidates(Map<org.apache.hadoop.yarn.api.records.ApplicationAttemptId,Set<RMContainer>> selectedCandidates, org.apache.hadoop.yarn.api.records.Resource clusterResource, org.apache.hadoop.yarn.api.records.Resource totalPreemptedResourceAllowed)
      Get preemption candidates from computed resource sharing and already selected candidates.
      Parameters:
      selectedCandidates - already selected candidates from previous policies
      clusterResource - total resource
      totalPreemptedResourceAllowed - how many resources allowed to be preempted in this round. Should be updated(in-place set) after the call
      Returns:
      merged selected candidates.
    • getMaximumKillWaitTimeMs

      public long getMaximumKillWaitTimeMs()
    • setMaximumKillWaitTime

      public void setMaximumKillWaitTime(long maximumKillWaitTime)