|
GridSim 5.0 beta | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Object Thread Sim_entity GridSimCore GridSim Workload
public class Workload
The main purpose of this class is to create a realistic simulation environment where your jobs are competing with others. In other words, the grid resource might not be available at certain times. In addition, the arrival time of jobs are also captured in the trace file.
This class dispatches jobs to a grid resource according to the workload model provided. That is, the workload model can generate jobs according to various distributions, or read the job information from a log file.
NOTE THAT:
GridSim.init(int, Calendar, boolean)
Workload(String, double, double, int, String, WorkloadModel)
instead.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class Thread |
---|
Thread.State, Thread.UncaughtExceptionHandler |
Field Summary |
---|
Fields inherited from class GridSim |
---|
GRIDSIM_VERSION_STRING, PAUSE |
Fields inherited from class GridSimCore |
---|
input, NETWORK_TYPE, output |
Fields inherited from class Thread |
---|
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
Constructor Summary | |
---|---|
Workload(String name,
double baudRate,
double propDelay,
int MTU,
String resourceName,
WorkloadModel model)
Create a new Workload object with the network extension. |
|
Workload(String name,
Link link,
String resourceName,
WorkloadModel model)
Create a new Workload object with the network extension. |
|
Workload(String name,
String resourceName,
WorkloadModel model)
Create a new Workload object without using the network extension. |
Method Summary | |
---|---|
void |
body()
Generates jobs according to provided model when the simulation starts. |
ArrayList<Gridlet> |
getGridletList()
Gets a list of completed jobs |
Methods inherited from class GridSimCore |
---|
finalizeGridSimulation, getLink, getPingResult, isNetworked, ping, ping, ping, ping, pingBlockingCall, pingBlockingCall, pingBlockingCall, pingBlockingCall, send, send, send, send, send, send, setBackgroundTraffic, setBackgroundTraffic, terminateIOEntities |
Methods inherited from class Thread |
---|
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
Methods inherited from class Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
---|
public Workload(String name, String resourceName, WorkloadModel model) throws Exception
name
- this entity nameresourceName
- the resource namemodel
- the workload model to be used for generating the jobs
Exception
- this happens when creating this entity before
initialising GridSim package or this entity name is
null
or empty
IllegalArgumentException
- this happens for the following conditions:
public Workload(String name, double baudRate, double propDelay, int MTU, String resourceName, WorkloadModel model) throws Exception
name
- this entity namebaudRate
- baud rate of this link (bits/s)propDelay
- Propagation delay of the Link in milli secondsMTU
- Maximum Transmission Unit of the Link in bytes.
Packets which are larger than the MTU should be split
up into MTU size units.
For example, a 1024 byte packet trying to cross a 576
byte MTU link should get split into 2 packets of 576
bytes and 448 bytes.resourceName
- the resource namemodel
- the workload model to be used for generating the jobs
Exception
- this happens when creating this entity before
initialising GridSim package or this entity name is
null
or empty
IllegalArgumentException
- this happens for the following conditions:
public Workload(String name, Link link, String resourceName, WorkloadModel model) throws Exception
name
- this entity namelink
- the link that will be used to connect this Workload
to another entity or a Router.resourceName
- the resource namemodel
- the workload model to be used for generating the jobs
Exception
- this happens when creating this entity before
initialising GridSim package or this entity name is
null
or empty
IllegalArgumentException
- this happens for the following conditions:
Method Detail |
---|
public void body()
getGridletList()
body
in class Sim_entity
public ArrayList<Gridlet> getGridletList()
IllegalStateException
- if this method is invoked before the
simulation completes
|
GridSim 5.0 beta | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |