ComputeServiceMessage.h
1 
11 #ifndef WRENCH_COMPUTESERVICEMESSAGE_H
12 #define WRENCH_COMPUTESERVICEMESSAGE_H
13 
14 #include <memory>
15 #include <vector>
16 #include "wrench/workflow/execution_events/FailureCause.h"
17 #include "wrench/services/ServiceMessage.h"
18 
19 namespace wrench {
20 
21  class StandardJob;
22 
23  class PilotJob;
24 
25  /***********************/
27  /***********************/
28 
33  protected:
34  ComputeServiceMessage(std::string name, double payload);
35  };
36 
37 
42  public:
43  ComputeServiceSubmitStandardJobRequestMessage(std::string answer_mailbox, StandardJob *,
44  std::map<std::string, std::string> &service_specific_args,
45  double payload);
46 
48  std::string answer_mailbox;
52  std::map<std::string, std::string> service_specific_args;
53  };
54 
59  public:
61  std::shared_ptr<FailureCause> failure_cause, double payload);
62 
68  bool success;
70  std::shared_ptr<FailureCause> failure_cause;
71  };
72 
77  public:
79 
84  };
85 
90  public:
91  ComputeServiceStandardJobFailedMessage(StandardJob *, ComputeService *, std::shared_ptr<FailureCause> cause,
92  double payload);
93 
99  std::shared_ptr<FailureCause> cause;
100  };
101 
106  public:
107  ComputeServiceTerminateStandardJobRequestMessage(std::string answer_mailbox, StandardJob *, double payload);
108 
110  std::string answer_mailbox;
113  };
114 
119  public:
121  std::shared_ptr<FailureCause> failure_cause, double payload);
122 
128  bool success;
130  std::shared_ptr<FailureCause> failure_cause;
131  };
132 
137  public:
138  ComputeServiceSubmitPilotJobRequestMessage(std::string answer_mailbox, PilotJob *, std::map<std::string, std::string> &service_specific_args, double payload);
139 
141  std::string answer_mailbox;
145  std::map<std::string, std::string> service_specific_args;
146  };
147 
152  public:
154  std::shared_ptr<FailureCause> cause,
155  double payload);
156 
162  bool success;
164  std::shared_ptr<FailureCause> failure_cause;
165  };
166 
167 
172  public:
174 
179  };
180 
185  public:
187 
192  };
193 
198  public:
200 
205  };
206 
211  public:
212  ComputeServiceTerminatePilotJobRequestMessage(std::string answer_mailbox, PilotJob *, double payload);
213 
215  std::string answer_mailbox;
218  };
219 
224  public:
226  std::shared_ptr<FailureCause> failure_cause, double payload);
227 
233  bool success;
235  std::shared_ptr<FailureCause> failure_cause;
236  };
237 
238 
243  public:
244  ComputeServiceResourceInformationRequestMessage(std::string answer_mailbox, double payload);
245 
247  std::string answer_mailbox;
248  };
249 
254  public:
255  ComputeServiceResourceInformationAnswerMessage(std::map<std::string, std::map<std::string, double>> info, double payload);
256 
258  std::map<std::string, std::map<std::string, double>> info;
259  };
260 
261 
262  /***********************/
264  /***********************/
265 
266 };
267 
268 
269 #endif //WRENCH_COMPUTESERVICEMESSAGE_H
Top-level class for messages received/sent by a ComputeService.
Definition: ComputeServiceMessage.h:32
A message sent by a ComputeService when a PilotJob has failed.
Definition: ComputeServiceMessage.h:197
PilotJob * job
The pilot job that has failed.
Definition: ComputeServiceMessage.h:202
StandardJob * job
The job that has completed.
Definition: ComputeServiceMessage.h:81
A message sent by a ComputeService in answer to a StandardJob termination request.
Definition: ComputeServiceMessage.h:118
A message sent by a ComputeService when a PilotJob has started its execution.
Definition: ComputeServiceMessage.h:171
A message sent by a ComputeService when a PilotJob has expired.
Definition: ComputeServiceMessage.h:184
A message sent by a ComputeService in answer to a resource information request.
Definition: ComputeServiceMessage.h:253
PilotJob * job
The submitted pilot job.
Definition: ComputeServiceMessage.h:158
StandardJob * job
The standard job to terminate.
Definition: ComputeServiceMessage.h:124
ComputeService * compute_service
The compute service on which the job has failed.
Definition: ComputeServiceMessage.h:97
std::map< std::string, std::map< std::string, double > > info
The resource information map.
Definition: ComputeServiceMessage.h:258
bool success
Whether to job submission was successful.
Definition: ComputeServiceMessage.h:68
A message sent by a ComputeService when a StandardJob has failed to execute.
Definition: ComputeServiceMessage.h:89
std::shared_ptr< FailureCause > cause
The cause of the failure.
Definition: ComputeServiceMessage.h:99
double payload
The message size in bytes.
Definition: SimulationMessage.h:39
StandardJob * job
The submitted job.
Definition: ComputeServiceMessage.h:50
A message sent to a ComputeService to submit a StandardJob for execution.
Definition: ComputeServiceMessage.h:41
PilotJob * job
The pilot job that has expired.
Definition: ComputeServiceMessage.h:189
std::string name
The message name.
Definition: SimulationMessage.h:37
std::shared_ptr< FailureCause > failure_cause
The cause of the failure, or nullptr on success.
Definition: ComputeServiceMessage.h:70
StandardJob * job
The job that has failed.
Definition: ComputeServiceMessage.h:95
A message sent by a ComputeService in answer to a StandardJob submission request. ...
Definition: ComputeServiceMessage.h:58
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
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
std::shared_ptr< FailureCause > failure_cause
The cause of the failure, or nullptr on success.
Definition: ComputeServiceMessage.h:235
A message sent by a ComputeService in answer to a PilotJob submission request.
Definition: ComputeServiceMessage.h:151
ComputeService * compute_service
The compute service to which the job was submitted.
Definition: ComputeServiceMessage.h:66
std::map< std::string, std::string > service_specific_args
Service specific arguments.
Definition: ComputeServiceMessage.h:52
PilotJob * job
The pilot job that has started.
Definition: ComputeServiceMessage.h:176
A message sent to a ComputeService to request information on its compute resources.
Definition: ComputeServiceMessage.h:242
PilotJob * job
The submitted pilot job.
Definition: ComputeServiceMessage.h:143
A message sent by a ComputeService in answer to a PilotJob termination request.
Definition: ComputeServiceMessage.h:223
StandardJob * job
The job to terminate.
Definition: ComputeServiceMessage.h:112
ComputeService * compute_service
The compute service on which the job has completed.
Definition: ComputeServiceMessage.h:83
ComputeService * compute_service
The compute service to which the job had been submitted.
Definition: ComputeServiceMessage.h:126
The compute service base class.
Definition: ComputeService.h:35
A message sent to a ComputeService to terminate a PilotJob previously submitted for execution...
Definition: ComputeServiceMessage.h:210
PilotJob * job
The job to terminate.
Definition: ComputeServiceMessage.h:217
ComputeServiceMessage(std::string name, double payload)
Constructor.
Definition: ComputeServiceMessage.cpp:21
Top-level class for messages received/sent by a Service.
Definition: ServiceMessage.h:27
std::string answer_mailbox
The mailbox to which the answer message should be sent.
Definition: ComputeServiceMessage.h:110
ComputeService * compute_service
The compute service to which the job had been submitted.
Definition: ComputeServiceMessage.h:231
bool success
Whether the job submission was successful or not.
Definition: ComputeServiceMessage.h:162
ComputeService * compute_service
The compute service on which the pilot job has expired.
Definition: ComputeServiceMessage.h:191
ComputeService * compute_service
The compute service on which the pilot job has started.
Definition: ComputeServiceMessage.h:178
std::string answer_mailbox
The mailbox to which the answer message should be sent.
Definition: ComputeServiceMessage.h:215
bool success
Whether to job termination was successful.
Definition: ComputeServiceMessage.h:128
std::shared_ptr< FailureCause > failure_cause
The cause of the failure, or nullptr on success.
Definition: ComputeServiceMessage.h:130
A message sent to a ComputeService to terminate a StandardJob previously submitted for execution...
Definition: ComputeServiceMessage.h:105
ComputeService * compute_service
The compute service on which the pilot job failed.
Definition: ComputeServiceMessage.h:204
std::string answer_mailbox
The mailbox to which the answer message should be sent.
Definition: ComputeServiceMessage.h:141
A message sent to a ComputeService to submit a PilotJob for execution.
Definition: ComputeServiceMessage.h:136
ComputeService * compute_service
The compute service to which the job was submitted.
Definition: ComputeServiceMessage.h:160
PilotJob * job
The job to terminate.
Definition: ComputeServiceMessage.h:229
std::map< std::string, std::string > service_specific_args
Service specific arguments.
Definition: ComputeServiceMessage.h:145
std::shared_ptr< FailureCause > failure_cause
The cause of the failure, or nullptr on success.
Definition: ComputeServiceMessage.h:164
std::string answer_mailbox
The mailbox to which the answer should be sent.
Definition: ComputeServiceMessage.h:247
A message sent by a ComputeService when a StandardJob has completed execution.
Definition: ComputeServiceMessage.h:76
std::string answer_mailbox
The mailbox to which the answer message should be sent.
Definition: ComputeServiceMessage.h:48
Definition: TerminalOutput.cpp:15
StandardJob * job
The standard job that was submitted.
Definition: ComputeServiceMessage.h:64
bool success
Whether to job termination was successful.
Definition: ComputeServiceMessage.h:233