|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectnet.eduvax.grant.core.Node
net.eduvax.grant.core.LocalNode
net.eduvax.grant.simul.TestNode
class TestNode
Evaluation node. This node's goal is to help to evaluate Ant Engine selection. It is intended to use pausing test tasklet and simulates itself cpu load by another pause. This pause delay depends on node virtual capacity and can envolve to simulate real cpu load variations.
| Field Summary | |
|---|---|
(package private) NodeClient |
client
|
private int |
loadCost
delay to add for each running task. |
private int |
perfIndice
current perf indice. |
| Fields inherited from class net.eduvax.grant.core.LocalNode |
|---|
ANT_DEF_DELAY, candidate, STATE_FULL, STATE_HALTED, STATE_RUNNING, STATE_SHUTDOWN, STATE_STARTING, STATES_NAME |
| Constructor Summary | |
|---|---|
TestNode(java.lang.String n,
int p)
Creates new test node. |
|
| Method Summary | |
|---|---|
protected boolean |
checkLoad()
Fake load check loading. |
int |
execReportToClient(ExecReport er)
|
protected float |
getFeedback(ExecRequest er)
Do not feedback on schedule. |
float |
getLoadValue()
Compute "real" load for test node. |
float |
load()
computes CPU Load. |
protected void |
loadNodes(java.util.Hashtable nodeSet,
java.io.File nodesFile)
Fake rc file loading. |
void |
setClient(NodeClient nc)
|
void |
setLoadCost(int c)
Changes load cost. |
void |
setPerf(int p)
Changes performance indice value. |
| Methods inherited from class net.eduvax.grant.core.LocalNode |
|---|
addNode, dissipate, execReport, feedback, fitness, getFeedback, getKnownNodes, getTaskCount, handleEvent, removeNode, sendEvent, setMaxLoad, setSelector, shutdown, status, submitRequest |
| Methods inherited from class net.eduvax.grant.core.Node |
|---|
createNode, getFitness, getName, getRCDir, registerNodeFactory, setFitness |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private int perfIndice
private int loadCost
NodeClient client
| Constructor Detail |
|---|
public TestNode(java.lang.String n,
int p)
n - new node's namep - virtual cpu load. The node will pause p seconds when computing
cpu load (@see #load()) i.e. after each tasklet completion.| Method Detail |
|---|
public void setPerf(int p)
p - new perf indice value.public void setLoadCost(int c)
c - delay value in milliseconds.public float load()
load in class LocalNodepublic int execReportToClient(ExecReport er)
execReportToClient in class LocalNodepublic void setClient(NodeClient nc)
public float getLoadValue()
protected float getFeedback(ExecRequest er)
getFeedback in class LocalNodeer - execute request
protected void loadNodes(java.util.Hashtable nodeSet,
java.io.File nodesFile)
loadNodes in class LocalNodenodeSet - not used herenodesFile - not used hereprotected boolean checkLoad()
checkLoad in class LocalNode
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||