|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object gov.bnl.star.offline.scheduler.policy.ClusterAssignmentByPercentagePolicy
public class ClusterAssignmentByPercentagePolicy
This policy takes the assignment from another policy, and decides to which cluster to assign them according to the percentage. For each job, a random number is generated between 0 and 1. If the number is less than the percentage set, the job will be forwarded. The number of jobs forwarded, then, is not strictly the percentage set. It will be for large number.
Constructor Summary | |
---|---|
ClusterAssignmentByPercentagePolicy()
|
Method Summary | |
---|---|
java.util.List |
assignTargetMachine(Request request)
Decides how and where to run the job according to its requirements. |
Policy |
getPolicy()
Getter for property policy. |
java.lang.String |
getPrimaryCluster()
Getter for property primaryCluster. |
java.lang.String |
getQueueToRedirect()
Getter for property queueToRedirect. |
double |
getRedirectedPercentage()
Getter for property redirectedPercentage. |
java.lang.String |
getSecondaryCluster()
Getter for property secondaryCluster. |
void |
setPolicy(Policy policy)
Setter for property policy. |
void |
setPrimaryCluster(java.lang.String primaryCluster)
Setter for property primaryCluster. |
void |
setQueueToRedirect(java.lang.String queueToRedirect)
Setter for property queueToRedirect. |
void |
setRedirectedPercentage(double redirectedPercentage)
Setter for property redirectedPercentage. |
void |
setSecondaryCluster(java.lang.String secondaryCluster)
Setter for property secondaryCluster. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ClusterAssignmentByPercentagePolicy()
Method Detail |
---|
public java.util.List assignTargetMachine(Request request)
Policy
The Policy is allowed to query the farm status, use the catalog and trigger file movements. It can slice the job into more than one process, according to, for example, where the input files are located.
assignTargetMachine
in interface Policy
request
- the job description and its requirementspublic Policy getPolicy()
public void setPolicy(Policy policy)
policy
- New value of property policy.public java.lang.String getPrimaryCluster()
public void setPrimaryCluster(java.lang.String primaryCluster)
primaryCluster
- New value of property primaryCluster.public java.lang.String getSecondaryCluster()
public void setSecondaryCluster(java.lang.String secondaryCluster)
secondaryCluster
- New value of property secondaryCluster.public java.lang.String getQueueToRedirect()
public void setQueueToRedirect(java.lang.String queueToRedirect)
queueToRedirect
- New value of property queueToRedirect.public double getRedirectedPercentage()
public void setRedirectedPercentage(double redirectedPercentage)
redirectedPercentage
- New value of property redirectedPercentage.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |