public class AssignmentFailure
extends java.lang.Object
When you call scheduleOnce()
to
schedule tasks, that method returns a SchedulingResult
. You can use that object's
getFailures()
method to get a List of
TaskAssignmentResult
objects that represent the status of each task you attempted to assign. Each of
those objects has a getFailures()
method with which you can get
a list of AssignmentFailure
objects describing any failures of this sort that made the task
scheduler unable to assign the task to a host.
Constructor and Description |
---|
AssignmentFailure(VMResource resource,
double asking,
double used,
double available,
java.lang.String message) |
Modifier and Type | Method and Description |
---|---|
double |
getAsking()
Returns the quantity of this target resource the task was requesting.
|
double |
getAvailable()
Returns the quantity of this resource that the target has free to be assigned to a new task or tasks.
|
java.lang.String |
getMessage()
Returns text message associated with this assignment failure.
|
VMResource |
getResource()
Returns which target resource this assignment failure is referring to.
|
double |
getUsed()
Returns the quantity of this resource that is already assigned on the target.
|
java.lang.String |
toString()
Returns a String representation of this assignment failure, with details about the resource that caused
the failure and its current level of allocation and availability on the target.
|
public AssignmentFailure(VMResource resource, double asking, double used, double available, java.lang.String message)
public VMResource getResource()
public double getAsking()
public double getUsed()
public double getAvailable()
public java.lang.String getMessage()
public java.lang.String toString()
toString
in class java.lang.Object