WRENCH  1.11
Cyberinfrastructure Simulation Workbench
Overview Installation Getting Started WRENCH 101 WRENCH 102
ActionExecutionServiceMessage.h
1 
11 #ifndef WRENCH_ACTION_ACTION_EXECUTION_SERVICE_MESSAGE_H
12 #define WRENCH_ACTION_ACTION_EXECUTION_SERVICE_MESSAGE_H
13 
14 #include <vector>
15 
16 #include "wrench/services/helper_services/action_execution_service/ActionExecutionService.h"
17 #include "wrench/services/ServiceMessage.h"
18 
19 namespace wrench {
20 
21  class Action;
22 
23  class ActionExecutor;
24 
25  /***********************/
27  /***********************/
28 
32  class ActionExecutionServiceMessage : public SimulationMessage {
33  protected:
34  ActionExecutionServiceMessage( double payload);
35  };
36 
40  class ActionExecutionServiceSubmitActionRequestMessage : public ActionExecutionServiceMessage {
41  public:
42  ActionExecutionServiceSubmitActionRequestMessage(
43  simgrid::s4u::Mailbox *reply_mailbox,
44  std::shared_ptr<Action> action,
45  double payload);
46 
48  std::shared_ptr<Action> action;
50  simgrid::s4u::Mailbox *reply_mailbox;
51  };
52 
56  class ActionExecutionServiceSubmitActionAnswerMessage : public ActionExecutionServiceMessage {
57  public:
58  ActionExecutionServiceSubmitActionAnswerMessage(
59  bool success,
60  std::shared_ptr<FailureCause> cause,
61  double payload);
62 
64  bool success;
66  std::shared_ptr<FailureCause> cause;
67  };
68 
72  class ActionExecutionServiceTerminateActionRequestMessage : public ActionExecutionServiceMessage {
73  public:
74  ActionExecutionServiceTerminateActionRequestMessage(
75  simgrid::s4u::Mailbox *reply_mailbox,
76  std::shared_ptr<Action> action,
77  ComputeService::TerminationCause termination_cause,
78  double payload);
79 
81  simgrid::s4u::Mailbox *reply_mailbox;
83  std::shared_ptr<Action> action;
85  ComputeService::TerminationCause termination_cause;
86  };
87 
91  class ActionExecutionServiceTerminateActionAnswerMessage : public ActionExecutionServiceMessage {
92  public:
93  ActionExecutionServiceTerminateActionAnswerMessage(
94  bool success,
95  std::shared_ptr<FailureCause> cause,
96  double payload);
97 
99  bool success;
101  std::shared_ptr<FailureCause> cause;
102  };
103 
107  class ActionExecutionServiceActionDoneMessage : public ActionExecutionServiceMessage {
108  public:
109  ActionExecutionServiceActionDoneMessage(
110  std::shared_ptr<Action> action,
111  double payload);
112 
114  std::shared_ptr<Action> action;
115  };
116 
117 
118 
119  /***********************/
121  /***********************/
122 };
123 
124 #endif //WRENCH_ACTION_ACTION_EXECUTION_SERVICE_MESSAGE_H
wrench
Definition: Action.cpp:28