public abstract static class DominantResourceFairnessPolicy.DominantResourceFairnessComparator extends Object implements Comparator<Schedulable>
Schedulable
instances according to the
DRF policy. If neither instance is below min share, approximate fair share
ratios are compared. Subclasses of this class will do the actual work of
the comparison, specialized for the number of configured resource types.Constructor and Description |
---|
DominantResourceFairnessComparator() |
Modifier and Type | Method and Description |
---|---|
protected int |
compareAttribrutes(Schedulable s1,
Schedulable s2)
This method is used when apps are tied in fairness ratio.
|
void |
setFSContext(FSContext fsContext) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
compare, comparing, comparing, comparingDouble, comparingInt, comparingLong, equals, naturalOrder, nullsFirst, nullsLast, reversed, reverseOrder, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
protected FSContext fsContext
public void setFSContext(FSContext fsContext)
protected int compareAttribrutes(Schedulable s1, Schedulable s2)
s1
- the first item to compares2
- the second item to compareCopyright © 2008–2020 Apache Software Foundation. All rights reserved.