protected static class DefaultSchedulingPriorityStrategy.SimulatedUser extends Object
Modifier and Type | Field and Description |
---|---|
double |
guaranteedCpu |
double |
guaranteedMemory |
protected LinkedList<TopologyDetails> |
tds |
Constructor and Description |
---|
SimulatedUser(User other,
ISchedulingState cluster) |
Modifier and Type | Method and Description |
---|---|
TopologyDetails |
getNextHighest() |
double |
getScore(double availableCpu,
double availableMemory) |
protected double |
getScore(double availableCpu,
double availableMemory,
TopologyDetails td)
Get a score for the simulated user.
|
TopologyDetails |
simScheduleNextHighest() |
public final double guaranteedCpu
public final double guaranteedMemory
protected final LinkedList<TopologyDetails> tds
public SimulatedUser(User other, ISchedulingState cluster)
public TopologyDetails getNextHighest()
public TopologyDetails simScheduleNextHighest()
protected double getScore(double availableCpu, double availableMemory, TopologyDetails td)
Get a score for the simulated user. This is used to sort the users, by their highest priority topology. The only requirement is that if the user is over their guarantees, or there are no available resources the returned score will be > 0. If they are under their guarantee it must be negative.
availableCpu
- available CPU on the cluster.availableMemory
- available memory on the cluster.td
- the topology we are looking at.public double getScore(double availableCpu, double availableMemory)
Copyright © 2019 The Apache Software Foundation. All rights reserved.