WRENCH  1.11
Cyberinfrastructure Simulation Workbench
Overview Installation Getting Started WRENCH 101 WRENCH 102
CloudComputeServiceMessage.h
1 
11 #ifndef WRENCH_CLOUDSERVICEMESSAGE_H
12 #define WRENCH_CLOUDSERVICEMESSAGE_H
13 
14 #include <vector>
15 #include "wrench/services/compute/bare_metal/BareMetalComputeService.h"
16 
17 #include "wrench/services/compute/ComputeServiceMessage.h"
18 
19 namespace wrench {
20 
21  class ComputeService;
22 
23  /***********************/
25  /***********************/
26 
31  protected:
33  };
34 
39  public:
41 
43  simgrid::s4u::Mailbox *answer_mailbox;
44  };
45 
50  public:
52 
54  std::vector<std::string> execution_hosts;
55  };
56 
61  public:
63  unsigned long num_cores,
64  double ram_memory,
65  std::string desired_vm_name,
66  WRENCH_PROPERTY_COLLECTION_TYPE property_list,
67  WRENCH_MESSAGE_PAYLOADCOLLECTION_TYPE messagepayload_list,
68  double payload);
69 
70  public:
72  simgrid::s4u::Mailbox *answer_mailbox;
74  unsigned long num_cores;
76  double ram_memory;
78  std::string desired_vm_name;
80  WRENCH_PROPERTY_COLLECTION_TYPE property_list;
82  WRENCH_MESSAGE_PAYLOADCOLLECTION_TYPE messagepayload_list;
83  };
84 
89  public:
91  std::shared_ptr<FailureCause> failure_cause, double payload);
92 
94  bool success;
96  std::string vm_name;
98  std::shared_ptr<FailureCause> failure_cause;
99  };
100 
105  public:
107  const std::string &vm_name,
110  double payload);
111 
112  public:
114  simgrid::s4u::Mailbox *answer_mailbox;
116  std::string vm_name;
121  };
122 
127  public:
128  CloudComputeServiceShutdownVMAnswerMessage(bool success, std::shared_ptr<FailureCause> failure_cause,
129  double payload);
130 
132  bool success;
134  std::shared_ptr<FailureCause> failure_cause;
135  };
136 
141  public:
143  const std::string &vm_name,
144  const std::string &pm_name,
145  double payload);
146 
147  public:
149  simgrid::s4u::Mailbox *answer_mailbox;
151  std::string vm_name;
153  std::string pm_name;
154  };
155 
160  public:
162  std::shared_ptr<BareMetalComputeService> cs,
163  std::shared_ptr<FailureCause> failure_cause,
164  double payload);
165 
167  bool success;
169  std::shared_ptr<BareMetalComputeService> cs;
171  std::shared_ptr<FailureCause> failure_cause;
172  };
173 
178  public:
180  const std::string &vm_name,
181  double payload);
182 
183  public:
185  simgrid::s4u::Mailbox *answer_mailbox;
187  std::string vm_name;
188  };
189 
194  public:
196  std::shared_ptr<FailureCause> failure_cause,
197  double payload);
198 
200  bool success;
202  std::shared_ptr<FailureCause> failure_cause;
203  };
204 
209  public:
210  CloudComputeServiceResumeVMRequestMessage(simgrid::s4u::Mailbox *mailbox,
211  const std::string &vm_name,
212  double payload);
213 
214  public:
216  simgrid::s4u::Mailbox *answer_mailbox;
218  std::string vm_name;
219  };
220 
225  public:
227  std::shared_ptr<FailureCause> failure_cause,
228  double payload);
229 
231  bool success;
233  std::shared_ptr<FailureCause> failure_cause;
234  };
235 
236 
241  public:
243  const std::string &vm_name,
244  double payload);
245 
246  public:
248  simgrid::s4u::Mailbox *answer_mailbox;
250  std::string vm_name;
251  };
252 
257  public:
259  std::shared_ptr<FailureCause> failure_cause,
260  double payload);
261 
263  bool success;
265  std::shared_ptr<FailureCause> failure_cause;
266  };
267 
268  /***********************/
270  /***********************/
271 }
272 
273 #endif //WRENCH_CLOUDSERVICEMESSAGE_H
wrench::CloudComputeServiceDestroyVMAnswerMessage
A message sent by a CloudComputeService in answer to a VM destroy request.
Definition: CloudComputeServiceMessage.h:256
wrench::CloudComputeServiceStartVMRequestMessage::vm_name
std::string vm_name
The name of the VM to start.
Definition: CloudComputeServiceMessage.h:151
wrench::CloudComputeServiceDestroyVMRequestMessage
A message sent to a CloudComputeService to request a VM destruction.
Definition: CloudComputeServiceMessage.h:240
wrench::CloudComputeServiceDestroyVMRequestMessage::answer_mailbox
simgrid::s4u::Mailbox * answer_mailbox
The mailbox to which the answer message should be sent.
Definition: CloudComputeServiceMessage.h:248
wrench::CloudComputeServiceCreateVMRequestMessage
A message sent to a CloudComputeService to request a VM creation.
Definition: CloudComputeServiceMessage.h:60
wrench::CloudComputeServiceCreateVMAnswerMessage::CloudComputeServiceCreateVMAnswerMessage
CloudComputeServiceCreateVMAnswerMessage(bool success, std::string &vm_name, std::shared_ptr< FailureCause > failure_cause, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:100
wrench::CloudComputeServiceSuspendVMAnswerMessage
A message sent by a CloudComputeService in answer to a VM suspend request.
Definition: CloudComputeServiceMessage.h:193
wrench::CloudComputeServiceCreateVMAnswerMessage
A message sent by a CloudComputeService in answer to a VM creation request.
Definition: CloudComputeServiceMessage.h:88
wrench::CloudComputeServiceStartVMAnswerMessage::success
bool success
Whether the VM start was successful or not.
Definition: CloudComputeServiceMessage.h:167
wrench::ComputeService::TerminationCause
TerminationCause
Job termination cause enum.
Definition: ComputeService.h:67
wrench::CloudComputeServiceCreateVMRequestMessage::ram_memory
double ram_memory
The VM RAM memory_manager_service capacity (0 means "use all memory_manager_service available on the ...
Definition: CloudComputeServiceMessage.h:76
wrench::ComputeServiceMessage
Top-level class for messages received/sent by a ComputeService.
Definition: ComputeServiceMessage.h:32
wrench::CloudComputeServiceCreateVMAnswerMessage::vm_name
std::string vm_name
The VM name if success.
Definition: CloudComputeServiceMessage.h:96
wrench::CloudComputeServiceShutdownVMRequestMessage::vm_name
std::string vm_name
The name of the new VM host.
Definition: CloudComputeServiceMessage.h:116
wrench::CloudComputeServiceShutdownVMAnswerMessage::CloudComputeServiceShutdownVMAnswerMessage
CloudComputeServiceShutdownVMAnswerMessage(bool success, std::shared_ptr< FailureCause > failure_cause, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:143
wrench::CloudComputeServiceCreateVMRequestMessage::desired_vm_name
std::string desired_vm_name
The desired name for the VM ("" means "pick for me")
Definition: CloudComputeServiceMessage.h:78
wrench::CloudComputeServiceDestroyVMAnswerMessage::failure_cause
std::shared_ptr< FailureCause > failure_cause
The failure cause (or nullptr if success)
Definition: CloudComputeServiceMessage.h:265
wrench::CloudComputeServiceShutdownVMRequestMessage::termination_cause
ComputeService::TerminationCause termination_cause
Termination cause (in case failure notifications are sent)
Definition: CloudComputeServiceMessage.h:120
wrench::CloudComputeServiceDestroyVMAnswerMessage::CloudComputeServiceDestroyVMAnswerMessage
CloudComputeServiceDestroyVMAnswerMessage(bool success, std::shared_ptr< FailureCause > failure_cause, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:290
wrench::CloudComputeServiceMessage::CloudComputeServiceMessage
CloudComputeServiceMessage(double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:22
wrench::CloudComputeServiceStartVMRequestMessage
A message sent to a CloudComputeService to request a VM start.
Definition: CloudComputeServiceMessage.h:140
wrench::CloudComputeServiceResumeVMRequestMessage::vm_name
std::string vm_name
The name of the VM host.
Definition: CloudComputeServiceMessage.h:218
wrench::CloudComputeServiceStartVMRequestMessage::pm_name
std::string pm_name
The name of the physical host on which to start the VM (or "" if up to the service")
Definition: CloudComputeServiceMessage.h:153
wrench::CloudComputeServiceResumeVMRequestMessage
A message sent to a CloudComputeService to request a VM resume.
Definition: CloudComputeServiceMessage.h:208
wrench::CloudComputeServiceStartVMAnswerMessage::cs
std::shared_ptr< BareMetalComputeService > cs
The VM's compute service.
Definition: CloudComputeServiceMessage.h:169
wrench::CloudComputeServiceStartVMAnswerMessage
A message sent by a CloudComputeService in answer to a VM start request.
Definition: CloudComputeServiceMessage.h:159
wrench
Definition: Action.cpp:28
wrench::CloudComputeServiceSuspendVMAnswerMessage::success
bool success
Whether the VM suspend was successful or not.
Definition: CloudComputeServiceMessage.h:200
wrench::CloudComputeServiceShutdownVMRequestMessage::answer_mailbox
simgrid::s4u::Mailbox * answer_mailbox
The mailbox to which the answer message should be sent.
Definition: CloudComputeServiceMessage.h:114
wrench::CloudComputeServiceShutdownVMAnswerMessage::success
bool success
Whether the VM shutdown was successful or not.
Definition: CloudComputeServiceMessage.h:132
wrench::CloudComputeServiceResumeVMAnswerMessage
A message sent by a CloudComputeService in answer to a VM resume request.
Definition: CloudComputeServiceMessage.h:224
wrench::CloudComputeServiceResumeVMAnswerMessage::success
bool success
Whether the VM resume was successful or not.
Definition: CloudComputeServiceMessage.h:231
wrench::CloudComputeServiceGetExecutionHostsRequestMessage::CloudComputeServiceGetExecutionHostsRequestMessage
CloudComputeServiceGetExecutionHostsRequestMessage(simgrid::s4u::Mailbox *answer_mailbox, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:34
wrench::CloudComputeServiceStartVMAnswerMessage::CloudComputeServiceStartVMAnswerMessage
CloudComputeServiceStartVMAnswerMessage(bool success, std::shared_ptr< BareMetalComputeService > cs, std::shared_ptr< FailureCause > failure_cause, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:182
wrench::CloudComputeServiceGetExecutionHostsRequestMessage::answer_mailbox
simgrid::s4u::Mailbox * answer_mailbox
The mailbox to which a reply should be sent.
Definition: CloudComputeServiceMessage.h:43
wrench::SimulationMessage::payload
double payload
The message name.
Definition: SimulationMessage.h:40
wrench::CloudComputeServiceSuspendVMRequestMessage
A message sent to a CloudComputeService to request a VM suspend.
Definition: CloudComputeServiceMessage.h:177
wrench::CloudComputeServiceShutdownVMRequestMessage
A message sent to a CloudComputeService to request a VM shutdown.
Definition: CloudComputeServiceMessage.h:104
wrench::CloudComputeServiceResumeVMRequestMessage::CloudComputeServiceResumeVMRequestMessage
CloudComputeServiceResumeVMRequestMessage(simgrid::s4u::Mailbox *mailbox, const std::string &vm_name, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:233
wrench::CloudComputeServiceShutdownVMRequestMessage::send_failure_notifications
bool send_failure_notifications
Whether to send failure notifications.
Definition: CloudComputeServiceMessage.h:118
wrench::CloudComputeServiceSuspendVMRequestMessage::vm_name
std::string vm_name
The name of the new VM host.
Definition: CloudComputeServiceMessage.h:187
wrench::CloudComputeServiceResumeVMRequestMessage::answer_mailbox
simgrid::s4u::Mailbox * answer_mailbox
The mailbox to which the answer message should be sent.
Definition: CloudComputeServiceMessage.h:216
wrench::CloudComputeServiceSuspendVMAnswerMessage::CloudComputeServiceSuspendVMAnswerMessage
CloudComputeServiceSuspendVMAnswerMessage(bool success, std::shared_ptr< FailureCause > failure_cause, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:219
wrench::CloudComputeServiceCreateVMRequestMessage::messagepayload_list
WRENCH_MESSAGE_PAYLOADCOLLECTION_TYPE messagepayload_list
A message payload list for the bare_metal_standard_jobs that will run on the VM ({} means "use all de...
Definition: CloudComputeServiceMessage.h:82
wrench::CloudComputeServiceDestroyVMRequestMessage::CloudComputeServiceDestroyVMRequestMessage
CloudComputeServiceDestroyVMRequestMessage(simgrid::s4u::Mailbox *answer_mailbox, const std::string &vm_name, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:269
wrench::CloudComputeServiceSuspendVMRequestMessage::CloudComputeServiceSuspendVMRequestMessage
CloudComputeServiceSuspendVMRequestMessage(simgrid::s4u::Mailbox *answer_mailbox, const std::string &vm_name, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:198
wrench::CloudComputeServiceCreateVMRequestMessage::CloudComputeServiceCreateVMRequestMessage
CloudComputeServiceCreateVMRequestMessage(simgrid::s4u::Mailbox *answer_mailbox, unsigned long num_cores, double ram_memory, std::string desired_vm_name, WRENCH_PROPERTY_COLLECTION_TYPE property_list, WRENCH_MESSAGE_PAYLOADCOLLECTION_TYPE messagepayload_list, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:72
wrench::CloudComputeServiceShutdownVMAnswerMessage::failure_cause
std::shared_ptr< FailureCause > failure_cause
The cause of the failure, or nullptr on success.
Definition: CloudComputeServiceMessage.h:134
wrench::CloudComputeServiceCreateVMRequestMessage::num_cores
unsigned long num_cores
The number of cores the service can use (0 means "use as many as there are cores on the host")
Definition: CloudComputeServiceMessage.h:74
wrench::CloudComputeServiceResumeVMAnswerMessage::failure_cause
std::shared_ptr< FailureCause > failure_cause
The failure cause (or nullptr if success)
Definition: CloudComputeServiceMessage.h:233
wrench::CloudComputeServiceDestroyVMAnswerMessage::success
bool success
Whether the VM suspend was successful or not.
Definition: CloudComputeServiceMessage.h:263
wrench::CloudComputeServiceStartVMAnswerMessage::failure_cause
std::shared_ptr< FailureCause > failure_cause
The failure cause (or nullptr if success)
Definition: CloudComputeServiceMessage.h:171
wrench::CloudComputeServiceMessage
Top-level class for messages received/sent by a CloudComputeService.
Definition: CloudComputeServiceMessage.h:30
wrench::CloudComputeServiceStartVMRequestMessage::answer_mailbox
simgrid::s4u::Mailbox * answer_mailbox
The mailbox to which the answer message should be sent.
Definition: CloudComputeServiceMessage.h:149
wrench::CloudComputeServiceResumeVMAnswerMessage::CloudComputeServiceResumeVMAnswerMessage
CloudComputeServiceResumeVMAnswerMessage(bool success, std::shared_ptr< FailureCause > failure_cause, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:254
wrench::CloudComputeServiceSuspendVMRequestMessage::answer_mailbox
simgrid::s4u::Mailbox * answer_mailbox
The mailbox to which the answer message should be sent.
Definition: CloudComputeServiceMessage.h:185
wrench::CloudComputeServiceShutdownVMRequestMessage::CloudComputeServiceShutdownVMRequestMessage
CloudComputeServiceShutdownVMRequestMessage(simgrid::s4u::Mailbox *answer_mailbox, const std::string &vm_name, bool send_failure_notifications, ComputeService::TerminationCause termination_cause, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:118
wrench::CloudComputeServiceSuspendVMAnswerMessage::failure_cause
std::shared_ptr< FailureCause > failure_cause
The failure cause (or nullptr if success)
Definition: CloudComputeServiceMessage.h:202
wrench::CloudComputeServiceGetExecutionHostsAnswerMessage::execution_hosts
std::vector< std::string > execution_hosts
The list of execution hosts.
Definition: CloudComputeServiceMessage.h:54
wrench::CloudComputeServiceShutdownVMAnswerMessage
A message sent by a CloudComputeService in answer to a VM shutdown request.
Definition: CloudComputeServiceMessage.h:126
wrench::CloudComputeServiceStartVMRequestMessage::CloudComputeServiceStartVMRequestMessage
CloudComputeServiceStartVMRequestMessage(simgrid::s4u::Mailbox *answer_mailbox, const std::string &vm_name, const std::string &pm_name, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:158
wrench::CloudComputeServiceCreateVMRequestMessage::answer_mailbox
simgrid::s4u::Mailbox * answer_mailbox
The mailbox to which the answer message should be sent.
Definition: CloudComputeServiceMessage.h:72
wrench::CloudComputeServiceGetExecutionHostsAnswerMessage
A message sent by a CloudComputeService in answer to a list of execution hosts request.
Definition: CloudComputeServiceMessage.h:49
wrench::CloudComputeServiceDestroyVMRequestMessage::vm_name
std::string vm_name
The name of the VM host.
Definition: CloudComputeServiceMessage.h:250
wrench::CloudComputeServiceGetExecutionHostsAnswerMessage::CloudComputeServiceGetExecutionHostsAnswerMessage
CloudComputeServiceGetExecutionHostsAnswerMessage(std::vector< std::string > &execution_hosts, double payload)
Constructor.
Definition: CloudComputeServiceMessage.cpp:53
wrench::CloudComputeServiceGetExecutionHostsRequestMessage
A message sent to a CloudComputeService to request the list of its execution hosts.
Definition: CloudComputeServiceMessage.h:38
wrench::CloudComputeServiceCreateVMAnswerMessage::failure_cause
std::shared_ptr< FailureCause > failure_cause
The cause of the failure, or nullptr on success.
Definition: CloudComputeServiceMessage.h:98
wrench::CloudComputeServiceCreateVMAnswerMessage::success
bool success
Whether the VM creation was successful or not.
Definition: CloudComputeServiceMessage.h:94
wrench::CloudComputeServiceCreateVMRequestMessage::property_list
WRENCH_PROPERTY_COLLECTION_TYPE property_list
A property list for the bare_metal_standard_jobs that will run on the VM ({} means "use all defaults"...
Definition: CloudComputeServiceMessage.h:80