|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IRmJob
This class represents a job inside the scheduler.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface org.apache.uima.ducc.rm.scheduler.SchedConstants |
|---|
SchedConstants.EvictionPolicy, SchedConstants.Policy |
| Field Summary |
|---|
| Fields inherited from interface org.apache.uima.ducc.rm.scheduler.SchedConstants |
|---|
COMPONENT_NAME, DEFAULT_INIT_STABILITY_COUNT, DEFAULT_INSTANCES, DEFAULT_MAX_INSTANCES, DEFAULT_MAX_PROCESSES, DEFAULT_NODE_METRICS_RATE, DEFAULT_PRIORITY, DEFAULT_PROCESSES, DEFAULT_SCHEDULING_RATE, DEFAULT_SCHEDULING_RATIO, DEFAULT_SHARE_WEIGHT, DEFAULT_STABILITY_COUNT |
| Method Summary | |
|---|---|
void |
assignShare(Share s)
Scheduler found us a new toy, make it pending until it's given to job manager. |
int |
calculateCap(int order,
int basis)
|
void |
cancelPending(Share s)
Cancel a pending assignment, part of defrag |
void |
clearPendingRemoves()
And finally, dump the pending shrinkage. |
void |
clearRecoveredShares()
Shares recovered, clear the structures. |
void |
clearShares()
Used during scheduling cycle only, keep track of number of shares given out to this job. |
int |
countInstances()
|
int |
countNShares()
Find number of nShares this machine has assigned already. |
int |
countNSharesGiven()
|
int |
countNSharesLost()
|
int |
countQSharesGiven()
|
Comparator<org.apache.uima.ducc.rm.scheduler.IEntity> |
getApportionmentSorter()
|
HashMap<Share,Share> |
getAssignedShares()
Get the actual shares that are assigned to this job. |
String |
getClassName()
|
org.apache.uima.ducc.transport.event.common.IDuccTypes.DuccType |
getDuccType()
|
long |
getFriendlyId()
|
int[] |
getGivenByOrder()
|
org.apache.uima.ducc.common.utils.id.DuccId |
getId()
|
int |
getJobCap()
This returns the largest number that can actually be used, which will be either the share cap itself, or nProcess / nThreads, in quantum shares. |
Map<Machine,Machine> |
getMachines()
|
int |
getMaxShares()
|
int |
getMemory()
|
int |
getMinShares()
|
String |
getName()
|
HashMap<Share,Share> |
getPendingRemoves()
Return the reclaimed shares. |
HashMap<Share,Share> |
getPendingShares()
Newly allocated shares that have not been dispatched. |
int |
getPureFairShare()
|
HashMap<Share,Share> |
getRecoveredShares()
Get the shares that are scheduled for (job) recovery. |
String |
getRefusalReason()
|
ResourceClass |
getResourceClass()
|
SchedConstants.Policy |
getSchedulingPolicy()
|
int |
getSchedulingPriority()
|
int |
getShareOrder()
|
Map<Machine,Map<Share,Share>> |
getSharesByMachine()
For defrag, we want to know what machines a job is running on. |
int |
getShareWeight()
|
long |
getTimestamp()
|
User |
getUser()
|
String |
getUserName()
|
int |
getUserPriority()
|
int[] |
getWantedByOrder()
|
void |
init()
read the props file and set inital values for internal fields |
void |
initJobCap()
|
void |
initWantedByOrder(ResourceClass rc)
|
boolean |
isCompleted()
|
boolean |
isDormant()
|
boolean |
isExpanded()
What is result of latest scheduling epoch? |
boolean |
isInitialized()
|
boolean |
isPendingShare(Share s)
|
boolean |
isRefused()
|
boolean |
isReservation()
|
boolean |
isShrunken()
|
boolean |
isStable()
|
void |
markComplete()
The job is compolete but may linger a bit because of the defrag code. |
int |
nQuestions()
Number of questions submitted. |
int |
nQuestionsRemaining()
Number of questions still to be answered. |
int |
nThreads()
|
String |
printShares()
Logging and debugging - nice to know what my assigned shares are. |
HashMap<Share,Share> |
promoteShares()
We're dispatching, move machines to active list, and clear pending list. |
void |
recoverShare(Share s)
Set a share for recovery. |
void |
refuse(String refusal)
Can't schedudle this nohow. |
void |
removeAllShares()
Clear the job, it has no resources of any form. |
void |
removeShare(Share share)
I've shrunk or this share has nothing left to do. |
void |
setClassName(String n)
|
void |
setDuccType(org.apache.uima.ducc.transport.event.common.IDuccTypes.DuccType dt)
|
void |
setGivenByOrder(int[] gbo)
|
boolean |
setInitWait(boolean w)
|
void |
setJobName(String name)
|
void |
setMaxShares(int s)
|
void |
setMemory(int memory)
|
void |
setMinShares(int s)
|
void |
setNInstances(int m)
|
void |
setNQuestions(int allq,
int remainingq,
double time_per_item)
|
void |
setPureFairShare(int s)
|
void |
setReservation()
|
void |
setResourceClass(ResourceClass cl)
Save ref to the class we are in, and init class-based structures. |
void |
setShareOrder(int s)
Scheduler looks at job memory and decides what its share order is. |
void |
setThreads(int threads)
|
void |
setTimestamp(long t)
|
void |
setUser(User u)
|
void |
setUserName(String n)
|
void |
setUserPriority(int p)
|
int |
shrinkByInvestment(int shares,
int order,
boolean force,
org.apache.uima.ducc.rm.scheduler.NodePool np)
|
void |
shrinkByOne(Share share)
Pick a share, any share, and remove it from active. |
int |
shrinkByOrderByMachine(int shares,
int order,
boolean force,
org.apache.uima.ducc.rm.scheduler.NodePool np)
Eviction policies, configurable. |
| Method Detail |
|---|
void init()
org.apache.uima.ducc.common.utils.id.DuccId getId()
long getFriendlyId()
String getName()
void setJobName(String name)
void setResourceClass(ResourceClass cl)
int nQuestions()
void setNQuestions(int allq,
int remainingq,
double time_per_item)
int nQuestionsRemaining()
void setReservation()
boolean isReservation()
boolean setInitWait(boolean w)
void clearShares()
int countNSharesGiven()
int countQSharesGiven()
int countNSharesLost()
int shrinkByOrderByMachine(int shares,
int order,
boolean force,
org.apache.uima.ducc.rm.scheduler.NodePool np)
int shrinkByInvestment(int shares,
int order,
boolean force,
org.apache.uima.ducc.rm.scheduler.NodePool np)
HashMap<Share,Share> getAssignedShares()
HashMap<Share,Share> getPendingShares()
HashMap<Share,Share> getRecoveredShares()
HashMap<Share,Share> promoteShares()
Map<Machine,Map<Share,Share>> getSharesByMachine()
Map<Machine,Machine> getMachines()
void assignShare(Share s)
void recoverShare(Share s)
void cancelPending(Share s)
boolean isExpanded()
boolean isStable()
boolean isShrunken()
boolean isDormant()
boolean isPendingShare(Share s)
void removeAllShares()
void markComplete()
boolean isCompleted()
void removeShare(Share share)
void shrinkByOne(Share share)
HashMap<Share,Share> getPendingRemoves()
void clearPendingRemoves()
void clearRecoveredShares()
int countNShares()
void refuse(String refusal)
String getRefusalReason()
boolean isRefused()
void setShareOrder(int s)
int getShareOrder()
int getJobCap()
void initJobCap()
String getUserName()
void setUserName(String n)
User getUser()
void setUser(User u)
long getTimestamp()
void setTimestamp(long t)
int getUserPriority()
void setUserPriority(int p)
String getClassName()
void setClassName(String n)
int getSchedulingPriority()
SchedConstants.Policy getSchedulingPolicy()
ResourceClass getResourceClass()
int countInstances()
void setNInstances(int m)
int nThreads()
void setThreads(int threads)
int getMemory()
void setMemory(int memory)
String printShares()
int getMaxShares()
int getMinShares()
void setMaxShares(int s)
void setMinShares(int s)
void setPureFairShare(int s)
int getPureFairShare()
void setDuccType(org.apache.uima.ducc.transport.event.common.IDuccTypes.DuccType dt)
org.apache.uima.ducc.transport.event.common.IDuccTypes.DuccType getDuccType()
boolean isInitialized()
int getShareWeight()
void initWantedByOrder(ResourceClass rc)
int[] getWantedByOrder()
int[] getGivenByOrder()
void setGivenByOrder(int[] gbo)
int calculateCap(int order,
int basis)
Comparator<org.apache.uima.ducc.rm.scheduler.IEntity> getApportionmentSorter()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||