CloudSimTags

public final class CloudSimTags

Contains various static command tags that indicate a type of action that needs to be undertaken by CloudSim entities when they receive or send events. NOTE: To avoid conflicts with other tags, CloudSim reserves numbers lower than 300 and the number 9600.

Author:Manzur Murshed, Rajkumar Buyya, Anthony Sulistio

Fields

CLOUDLET_CANCEL

public static final int CLOUDLET_CANCEL

Cancels a Cloudlet submitted in the Datacenter entity. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_FAIL

public static final int CLOUDLET_FAIL

Request a Cloudlet to be set as failed. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_FINISH

public static final int CLOUDLET_FINISH

Requests an indefinite-length Cloudlet (negative value) to be finished by setting its length as the current number of processed MI. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

Events with a negative tag have higher priority. In this case, if a message with this tag is sent, it means that the Cloudlet has to be finished by replacing its negative length with an actual positive value. Only after that, the processing of Cloudlets can be updated. That is way this event must be processed before other events.

CLOUDLET_KILL

public static final int CLOUDLET_KILL

Requests a Cloudlet to be cancelled. The Cloudlet can be cancelled under user request or because another Cloudlet on which this one was dependent died. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_PAUSE

public static final int CLOUDLET_PAUSE

Pauses a Cloudlet submitted in the Datacenter entity. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_PAUSE_ACK

public static final int CLOUDLET_PAUSE_ACK

Pauses a Cloudlet submitted in the Datacenter entity with an acknowledgement. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_READY

public static final int CLOUDLET_READY

Request a Cloudlet to be set as ready to start executing inside a VM. This event is sent by a DatacenterBroker to itself to define the time when a specific Cloudlet should start executing. This tag is commonly used when Cloudlets are created from a trace file such as a Google Cluster Trace.

When the status of a Cloudlet is set to Cloudlet.Status.READY, the Cloudlet can be selected to start running as soon as possible by a CloudletScheduler.

When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_RESUME

public static final int CLOUDLET_RESUME

Resumes a Cloudlet submitted in the Datacenter entity. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_RESUME_ACK

public static final int CLOUDLET_RESUME_ACK

Resumes a Cloudlet submitted in the Datacenter entity with an acknowledgement. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_RETURN

public static final int CLOUDLET_RETURN

Denotes the return of a finished Cloudlet back to the sender. This tag is normally used by Datacenter entity. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_SUBMIT

public static final int CLOUDLET_SUBMIT

Denotes the submission of a Cloudlet. This tag is normally used between a DatacenterBroker and Datacenter entity. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_SUBMIT_ACK

public static final int CLOUDLET_SUBMIT_ACK

Denotes the submission of a Cloudlet with an acknowledgement. This tag is normally used between DatacenterBroker and Datacenter entity. When an event of this type is sent, the SimEvent.getData() must be a Cloudlet object.

CLOUDLET_UPDATE_ATTRIBUTES

public static final int CLOUDLET_UPDATE_ATTRIBUTES

Request a Cloudlet to have its attributes changed. When an event of this type is sent, the SimEvent.getData() must be a Runnable that represents a no-argument and no-return function that will perform the Cloudlet attribute update. The Runnable most encapsulate everything needed to update the Cloudlet’s attributes, including the Cloudlet which will be updated.

Since the logic to update the attributes of a Cloudlet can be totally customized according to the researcher needs, there is no standard way to perform such an operation. As an example, you may want to reduce by half the number of PEs required by a Cloudlet from a list at a given time. This way, the Runnable function may be defined as a Lambda Expression as follows. Realize the cloudletList is considered to be accessible anywhere in the surrounding scope.

Runnable runnable = () -> cloudletList.forEach(cloudlet -> cloudlet.setNumberOfPes(cloudlet.getNumberOfPes()/2));

The runnable variable must be set as the data for the event to be sent with this tag.

DATACENTER_LIST_REQUEST

public static final int DATACENTER_LIST_REQUEST

Denotes a request from a broker to a CloudInformationService to get the list of all Datacenters, including the ones that can support advanced reservation.

DATACENTER_REGISTRATION_REQUEST

public static final int DATACENTER_REGISTRATION_REQUEST

Denotes a request from a Datacenter to register itself. This tag is normally used between CloudInformationService and Datacenter entities. When such a SimEvent is sent, the SimEvent.getData() must be a Datacenter object.

END_OF_SIMULATION

public static final int END_OF_SIMULATION

Denotes the end of simulation. Despite it has a negative value, it isn’t a priority event.

FAILURE

public static final int FAILURE

Defines the base tag to be used for failure events such as failure of hosts or VMs.

HOST_ADD

public static final int HOST_ADD

Defines the tag that represents a request to a Datacenter to add a Host or list of Hosts to a Datacenter. The SimEvent.getData() must be a Host to be added to to the Datacenter where the message is being sent to. The source of such events is the CloudInformationService.

HOST_FAILURE

public static final int HOST_FAILURE

Defines the tag that represents a request to generate a host failure.

HOST_REMOVE

public static final int HOST_REMOVE

Defines the tag that represents a request to a Datacenter to remove a Host or list of Hosts from a Datacenter. The SimEvent.getData() must be the ID of the Host that will be removed from the Datacenter they belong to. For this event, it’s used the ID instead of the Host itself because the Host instance with the specified ID should be looked into the Datacenter Host list in order to remove it. A Host should be removed in case of maintenance or failure but there isn’t such a distinction yet, so a failure is simulated to remove the Host. The source of such events is the CloudInformationService.

ICMP_PKT_RETURN

public static final int ICMP_PKT_RETURN

This tag is used to return the ping request back to sender.

ICMP_PKT_SUBMIT

public static final int ICMP_PKT_SUBMIT

This tag is used by an entity to send ping requests.

NETWORK_EVENT_DOWN

public static final int NETWORK_EVENT_DOWN

NETWORK_EVENT_HOST

public static final int NETWORK_EVENT_HOST

NETWORK_EVENT_SEND

public static final int NETWORK_EVENT_SEND

NETWORK_EVENT_UP

public static final int NETWORK_EVENT_UP

NETWORK_HOST_REGISTER

public static final int NETWORK_HOST_REGISTER

REGISTER_REGIONAL_CIS

public static final int REGISTER_REGIONAL_CIS

Denotes a request to register a CloudInformationService entity as a regional CIS. When such a SimEvent is sent, the SimEvent.getData() must be a CloudInformationService object.

REQUEST_REGIONAL_CIS

public static final int REQUEST_REGIONAL_CIS

Denotes a request to get a list of other regional CIS entities from the system CIS entity.

VM_CREATE

public static final int VM_CREATE

Denotes a request to create a new VM in a Datacenter without requiring and acknowledgement to be sent back to the sender.

VM_CREATE_ACK

public static final int VM_CREATE_ACK

Denotes a request to create a new VM in a Datacenter with acknowledgement information sent by the Datacenter, where the SimEvent.getData() of the reply event is a Vm object. To check if the VM was in fact created inside the requested Datacenter one has only to call Vm.isCreated().

VM_DESTROY

public static final int VM_DESTROY

Denotes a request to destroy a VM in a Datacenter. When an event of this type is sent, the SimEvent.getData() must be a Vm object.

VM_DESTROY_ACK

public static final int VM_DESTROY_ACK

Denotes a request to destroy a new VM in a Datacenter with acknowledgement information sent by the Datacener. When an event of this type is sent, the SimEvent.getData() must be a Vm object.

VM_MIGRATE

public static final int VM_MIGRATE

Denotes a request to migrate a new VM in a Datacenter. When an event of this type is sent, the SimEvent.getData() must be a Map.Entry<Vm, Host> representing to which Host a VM must be migrated.

VM_MIGRATE_ACK

public static final int VM_MIGRATE_ACK

Denotes a request to migrate a new VM in a Datacenter with acknowledgement information sent by the Datacenter. When an event of this type is sent, the SimEvent.getData() must be a Map.Entry<Vm, Host> representing to which Host a VM must be migrated.

VM_UPDATE_CLOUDLET_PROCESSING

public static final int VM_UPDATE_CLOUDLET_PROCESSING

Denotes an internal event generated in a Datacenter to notify itself to update the processing of cloudlets. When an event of this type is sent, the SimEvent.getData() can be a Host object to indicate that just the Cloudlets running in VMs inside such a Host must be updated. The Host is an optional parameter which if omitted, means that all Hosts from the Datacenter will have its cloudlets updated.

VM_VERTICAL_SCALING

public static final int VM_VERTICAL_SCALING

Defines the tag to be used to request vertical scaling of VM resources such as Ram, Bandwidth or Pe. When an event of this type is sent, the SimEvent.getData() must be a VerticalVmScaling object.