New issue 24 by tanya33k...@gmail.com: HarddriveStorage confused
http://code.google.com/p/cloudsim/issues/detail?id=24
What steps will reproduce the problem?
Through reading the source code of CloudSim,an issue confused me for a long
time,in the HarddriveStorage class,in getFile method
obj.setTransactionTime(seekTime + transferTime) why not
obj.setTransactionTime(seekTime + transferTime+latency)
best regards.
Please provide any additional information below.
public File getFile(String fileName) {
// check first whether file name is valid or not
File obj = null;
if (fileName == null || fileName.length() == 0) {
Log.printLine(name + ".getFile(): Warning - invalid " + "file name.");
return obj;
}
Iterator<File> it = fileList.iterator();
int size = 0;
int index = 0;
boolean found = false;
File tempFile = null;
// find the file in the disk
while (it.hasNext()) {
tempFile = it.next();
size += tempFile.getSize();
if (tempFile.getName().equals(fileName)) {
found = true;
obj = tempFile;
break;
}
index++;
}
// if the file is found, then determine the time taken to get it
if (found) {
obj = fileList.get(index);
double seekTime = getSeekTime(size);
double transferTime = getTransferTime(obj.getSize());
// total time for this operation
obj.setTransactionTime(seekTime + transferTime);
}
return obj;
}
Comment #1 on issue 24 by rodrigo.calheiros: HarddriveStorage confused
http://code.google.com/p/cloudsim/issues/detail?id=24
In the case of a local hard disk, we assume a very small latency,
negligible for simulation purposes (we measure simulation in seconds, hard
disk latencies tend to be smaller than 10ms).
Comment #2 on issue 24 by rodrigo.calheiros: HarddriveStorage confused
http://code.google.com/p/cloudsim/issues/detail?id=24
(No comment was entered for this change.)