|
From: Alexandre S. <al...@ue...> - 2012-03-27 20:14:17
|
Dear GridSim users,
one of my colleagues is using GridSim. She is developing a specific
broker and has obtained good results so far.
Thanks the development team for GridSim, by the way...
We have now, however, a problem because we want use close-to-real numbers.
In some points we can define time related parameters such as channel
baud rates, MIPS, and so far... We assumed first that the base time unit
was "seconds" based on some comments in the Example codes. But, browsing
SimJava and GridSim documentation we have noticed slightly different
references regarding time: (abstract) "time units", seconds and
miliseconds as references.
Here is the specific problem: in some points we have to define delays:
1) super.gridSimHold(20);
==> Are we delaying 20 seconds? 20 milliseconds? or simply 20 time units?
2) super.send(get_id(), 60.0*60.0, GridSimTags.BROKER_TICK);
==> In the line bellow, the event engine will delay 60*60 seconds before
queuing the event or 60 minutes?
Ok. We can assume an abstract time unit.
But I think that these delays have to be consistent with the other
parameteres (baud rate, processor MIPS) and this with the size of a
"Gridlet to be executed in a GridResource (unit: in MI)"... That is, if
the base time is an abstract time unit, how the time-dependant parameter
are coherent? I am assuming that all time is based on the SimGrid time
base (obtained by the clock() method).
Examples:
a) In the AllocationPolicy, inside the checkGridletCompletion method we
have:
if (gridletInExecList_.size() > 0) {
super.sendInternalEvent(60.0*60.0);
}
There is a comment about turning the simulation more realistic, if you
reduce the parameter. But does it affect the actual time span of the
Gridlet or is it just a granularity problem?
b) In the createGridlet method (in many examples) there is a int
runTime parameter that afterwards generates:
int len = runTime * rating; // calculate a job length for each PE
which is used afterward to greate a Gridlet:
Gridlet gl = new Gridlet(id, len, fileSize, size, vo, user_id,0,id);
==> is "len" a time unit? What time unit?
c) In GridSImCore the constructure can receive a double baudRate
parameter, whitch is used to invoke the initNetwork method.
I gess the baudRate parameter is always specified using bits per
seconds... So, shouldn't all other time-related parameter follow this?
Another question, not time related.
Our broker needs to cancel a Gridlet (actually we cancel it in the
Resource but our broker maintains a reference to it and resume it
afterwards sending it again to the Resource ...). We have two ways to do
this:
we can invoke a method on the AllocationPolicy object attached to the
Resource or we can send an event asking this.
Ex.: super.scheduler_.gridletCancel(gridletSuspensoID,
gridletSuspensoUserID);
Question, the difference is only the transporting mechanism, the
cancellation method is the same, isnt it? And, the cancellation actually
purges the Gridlet from the Resource? And how about the execution time
registered in the Gridlet? What happens? There is an inclusion in the
Gridlet code which deals with this problem (but was coded considering
the Gridled wouldn't "leave" the Resource... our case is a little bit
different.
Best regards,
-- Alexandre Sztajnberg
|