Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 6 additions & 4 deletions src/main/java/org/cloudsimplus/examples/costs/CostsExample1.java
Original file line number Diff line number Diff line change
Expand Up @@ -48,9 +48,8 @@
/**
* A simple example showing how to define datacenter resource utilization
* and individual VM's costs ($).
* It creates VMs that run some cloudlets.
* Some VMs will just be idle all the time and
* other ones won't be created due to lack of available Hosts.
* It creates VMs that run some cloudlets,
* while other VMs will just be idle all the time.
*
* @author Manoel Campos da Silva Filho
* @since CloudSim Plus 6.2.7
Expand Down Expand Up @@ -116,10 +115,13 @@ private CostsExample1() {

/**
* Creates a broker which is a software acting on behalf of a cloud customer to manage his/her VMs and Cloudlets.
* It disables VMs creation retry, this way, failed VMs will be just added to the {@link DatacenterBroker#getVmFailedList()}.
* It disables VM creation retry, so that VMs that can't be placed are just added to the {@link DatacenterBroker#getVmFailedList()}.
*/
private DatacenterBroker createBroker() {
final var broker = new DatacenterBrokerSimple(simulation);
//Disables VM creation retry, so that VMs that can't be placed are just added to the broker's failed VM list
broker.getVmCreation().setRetryDelay(-1);

//Destroys idle VMs after some time (in seconds)
broker.setVmDestructionDelay(0.2);
return broker;
Expand Down
Loading