CloudComputeService.h
119 void submitStandardJob(StandardJob *job, std::map<std::string, std::string> &service_specific_args) override;
121 void submitPilotJob(PilotJob *job, std::map<std::string, std::string> &service_specific_args) override;
143 std::shared_ptr<SimulationMessage> sendRequest(std::string &answer_mailbox, ComputeServiceMessage *message);
160 virtual void processStartVM(const std::string &answer_mailbox, const std::string &vm_name, const std::string &pm_name);
176 virtual void processBareMetalComputeServiceTermination(std::shared_ptr<BareMetalComputeService> cs, int exit_code);
194 std::map<std::string, std::pair<std::shared_ptr<S4U_VirtualMachine>, std::shared_ptr<BareMetalComputeService>>> vm_list;
201 std::string findHost(unsigned long desired_num_cores, double desired_ram, std::string desired_host);
static const std::string SUSPEND_VM_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the service to request a VM suspend.
Definition: CloudComputeServiceMessagePayload.h:40
static const std::string GET_EXECUTION_HOSTS_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the service in answer to a get execution hosts req...
Definition: CloudComputeServiceMessagePayload.h:26
static const std::string STOP_DAEMON_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the daemon to terminate it.
Definition: ServiceMessagePayload.h:31
virtual void destroyVM(const std::string &vm_name)
Destroy a VM.
Definition: CloudComputeService.cpp:344
std::map< std::string, unsigned long > used_cores_per_execution_host
Map of number of used cores at the hosts.
Definition: CloudComputeService.h:191
virtual bool isVMDown(const std::string &vm_name)
Method to check whether a VM is currently down.
Definition: CloudComputeService.cpp:487
static const std::string SUSPEND_VM_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the service in answer to a VM suspend request...
Definition: CloudComputeServiceMessagePayload.h:42
static const std::string SHUTDOWN_VM_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the service to request a VM shutdown.
Definition: CloudComputeServiceMessagePayload.h:32
static const std::string SUBMIT_PILOT_JOB_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent from the daemon to acknowledge a pilot job submission...
Definition: ComputeServiceMessagePayload.h:40
virtual void shutdownVM(const std::string &vm_name)
Shutdown an active VM.
Definition: CloudComputeService.cpp:193
virtual bool isVMSuspended(const std::string &vm_name)
Method to check whether a VM is currently running.
Definition: CloudComputeService.cpp:506
static const std::string SUBMIT_STANDARD_JOB_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the daemon to acknowledge a standard job submissio...
Definition: ComputeServiceMessagePayload.h:28
A cloud-based compute service that manages a set of physical hosts and controls access to their resou...
Definition: CloudComputeService.h:37
virtual void resumeVM(const std::string &vm_name)
Resume a suspended VM.
Definition: CloudComputeService.cpp:306
static const std::string START_VM_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the service in answer to a VM start request...
Definition: CloudComputeServiceMessagePayload.h:38
static const std::string RESUME_VM_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the service to request a VM resume.
Definition: CloudComputeServiceMessagePayload.h:44
static const std::string START_VM_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the service to request a VM start.
Definition: CloudComputeServiceMessagePayload.h:36
static const std::string GET_EXECUTION_HOSTS_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the service to request a get execution hosts...
Definition: CloudComputeServiceMessagePayload.h:24
std::map< std::string, std::pair< std::shared_ptr< S4U_VirtualMachine >, std::shared_ptr< BareMetalComputeService > > > vm_list
A map of VMs.
Definition: CloudComputeService.h:194
A pilot (i.e., non-standard) workflow job that can be submitted to a ComputeService by a WMS (via a J...
Definition: PilotJob.h:29
virtual void suspendVM(const std::string &vm_name)
Suspend a running VM.
Definition: CloudComputeService.cpp:269
A standard (i.e., non-pilot) workflow job that can be submitted to a ComputeService by a WMS (via a J...
Definition: StandardJob.h:38
A class that provides basic simulation methods. Once the simulation object has been explicitly or imp...
Definition: Simulation.h:45
static const std::string DESTROY_VM_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the service to request a VM destruction.
Definition: CloudComputeServiceMessagePayload.h:48
virtual std::string createVM(unsigned long num_cores, double ram_memory, std::map< std::string, std::string > property_list={}, std::map< std::string, double > messagepayload_list={})
Create a BareMetalComputeService VM (balances load on execution hosts)
Definition: CloudComputeService.cpp:123
static const std::string SUBMIT_PILOT_JOB_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the daemon to submit a pilot job.
Definition: ComputeServiceMessagePayload.h:38
static const std::string SHUTDOWN_VM_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the service in answer to a VM shutdown request...
Definition: CloudComputeServiceMessagePayload.h:34
std::vector< std::string > execution_hosts
List of execution host names.
Definition: CloudComputeService.h:185
virtual std::shared_ptr< BareMetalComputeService > startVM(const std::string &vm_name)
Start a VM.
Definition: CloudComputeService.cpp:232
static const std::string SUPPORTS_PILOT_JOBS
Whether the compute service supports pilot jobs (true or false)
Definition: ComputeServiceProperty.h:26
static const std::string VM_RESOURCE_ALLOCATION_ALGORITHM
The VM resource allocation algorithm by which VMs are started on physical hosts. Possible values are:...
Definition: CloudComputeServiceProperty.h:33
static const std::string RESUME_VM_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the service in answer to a VM resume request...
Definition: CloudComputeServiceMessagePayload.h:46
static const std::string VM_BOOT_OVERHEAD_IN_SECONDS
The overhead, in seconds, to boot a VM.
Definition: CloudComputeServiceProperty.h:24
std::vector< std::string > getExecutionHosts()
Get the list of execution hosts available to run VMs.
Definition: CloudComputeService.cpp:87
static const std::string RESOURCE_DESCRIPTION_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the daemon to ask it for information on its resour...
Definition: ComputeServiceMessagePayload.h:56
static const std::string CREATE_VM_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the service to request a VM creation.
Definition: CloudComputeServiceMessagePayload.h:28
static const std::string SUPPORTS_STANDARD_JOBS
Whether the compute service supports standard jobs (true or false)
Definition: ComputeServiceProperty.h:24
CloudComputeService(const std::string &hostname, std::vector< std::string > &execution_hosts, std::string scratch_space_mount_point, std::map< std::string, std::string > property_list={}, std::map< std::string, double > messagepayload_list={})
Constructor.
Definition: CloudComputeService.cpp:42
static const std::string DESTROY_VM_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the service in answer to a VM destruction request...
Definition: CloudComputeServiceMessagePayload.h:50
static const std::string SUBMIT_STANDARD_JOB_REQUEST_MESSAGE_PAYLOAD
The number of bytes in the control message sent to the daemon to submit a standard job...
Definition: ComputeServiceMessagePayload.h:26
std::map< std::string, double > used_ram_per_execution_host
Map of used RAM at the hosts.
Definition: CloudComputeService.h:188
virtual bool isVMRunning(const std::string &vm_name)
Method to check whether a VM is currently running.
Definition: CloudComputeService.cpp:468
static const std::string DAEMON_STOPPED_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the daemon to confirm it has terminated.
Definition: ServiceMessagePayload.h:33
static const std::string RESOURCE_DESCRIPTION_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the daemon to state information on its resources...
Definition: ComputeServiceMessagePayload.h:58
static const std::string CREATE_VM_ANSWER_MESSAGE_PAYLOAD
The number of bytes in the control message sent by the service in answer to a VM creation request...
Definition: CloudComputeServiceMessagePayload.h:30
Definition: Alarm.cpp:19