|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.ourgrid.mygrid.scheduler.BlackListManager
public class BlackListManager
This entity is responsible to maintain the Black List, the list of
Gum
s that will not eb assigned to a Request
after some failures. The Black List Manager
will follow some
rules as described bellow :
Dentro de um mesmo job, uma máquina poderá falhar n vezes, onde n = min(T,
|J|) e T = definido pelo usuário.
Constructor Summary | |
---|---|
BlackListManager()
Cretes a new EBBlackListManager |
|
BlackListManager(int maxFailsPerJobToEnterInBL)
Cretes a new EBBlackListManager |
Method Summary | |
---|---|
boolean |
canThisGumRunThisTask(int jobID,
GumID gumID,
int taskID)
Returns true if no replicas of this task has been failed, false otherwise. |
int |
executionFailed(int jobID,
GumID gumID,
int taskID)
Adds an entry to BlackList registry. |
protected java.util.Set<BlackListEntry> |
getBlackListedMachines(int jobID)
Used in tests. |
int |
getMaxBLFails()
|
int |
getRemainingBLFails(int jobID,
GumID gumID)
The number of remaining failed task executions to this Gum enter in the job black list. |
void |
initiateBlackListForJob(int jobId,
int jobSize)
Init data structures to manage the black list of this job. |
boolean |
isGumBlacklistedForEntireJob(int jobId,
GumID gumID)
Return true if the Gum has had failed min( jobSize, maxBLFails ) tasks of the job, false otherwise. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public BlackListManager()
EBBlackListManager
public BlackListManager(int maxFailsPerJobToEnterInBL)
EBBlackListManager
maxFailsPerJobToEnterInBL
- Default maximum number of failues befor
the gum is blacklisted for a job.Method Detail |
---|
public int executionFailed(int jobID, GumID gumID, int taskID)
jobID
- The request id thats this black list is associated togumID
- The "Black Listed" GumID
protected java.util.Set<BlackListEntry> getBlackListedMachines(int jobID)
public int getMaxBLFails()
public int getRemainingBLFails(int jobID, GumID gumID)
jobID
- The identification of the JobgumID
- The identification of the Gum
public boolean canThisGumRunThisTask(int jobID, GumID gumID, int taskID)
jobID
- The identification of the JobgumID
- The identification of the GumtaskID
- The identification of the Task
public void initiateBlackListForJob(int jobId, int jobSize)
executionFailed
method can result in a
NullPointerException
if the the data structures was not
already initiated.
jobId
- The identification of the jobjobSize
- The number of Tasks of the jobpublic boolean isGumBlacklistedForEntireJob(int jobId, GumID gumID)
jobId
- The identification of the JobgumID
- The identification of the Gum
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |