WRENCH  1.10
Cyberinfrastructure Simulation Workbench
Overview Installation Getting Started WRENCH 101 WRENCH 102
FileRegistryMessage.h
1 
11 #ifndef WRENCH_FILEREGISTRYMESSAGE_H
12 #define WRENCH_FILEREGISTRYMESSAGE_H
13 
14 
15 #include <iostream>
16 #include <wrench/services/ServiceMessage.h>
17 #include <wrench/workflow/WorkflowFile.h>
18 #include <wrench/services/network_proximity/NetworkProximityService.h>
19 #include <wrench/services/storage/StorageService.h>
20 
21 namespace wrench {
22 
23  /***********************/
25  /***********************/
26 
30  class FileRegistryMessage : public ServiceMessage {
31  protected:
32  FileRegistryMessage(std::string name, double payload);
33 
34  };
35 
39  class FileRegistryFileLookupRequestMessage : public FileRegistryMessage {
40  public:
41  FileRegistryFileLookupRequestMessage(std::string answer_mailbox, WorkflowFile *file, double payload);
42 
44  std::string answer_mailbox;
46  WorkflowFile *file;
47  };
48 
52  class FileRegistryFileLookupAnswerMessage : public FileRegistryMessage {
53  public:
54  FileRegistryFileLookupAnswerMessage(WorkflowFile *file, std::set<std::shared_ptr<FileLocation>> locations,
55  double payload);
56 
58  WorkflowFile *file;
60  std::set<std::shared_ptr<FileLocation>> locations;
61  };
62 
67  class FileRegistryFileLookupByProximityRequestMessage : public FileRegistryMessage {
68  public:
69  FileRegistryFileLookupByProximityRequestMessage(std::string answer_mailbox, WorkflowFile *file,
70  std::string reference_host,
71  std::shared_ptr<NetworkProximityService> network_proximity_service,
72  double payload);
73 
75  std::string answer_mailbox;
77  WorkflowFile *file;
85  std::string reference_host;
86 
90  std::shared_ptr<NetworkProximityService> network_proximity_service;
91  };
92 
97  class FileRegistryFileLookupByProximityAnswerMessage : public FileRegistryMessage {
98  public:
99  FileRegistryFileLookupByProximityAnswerMessage(WorkflowFile *file,
100  std::string reference_host,
101  std::map<double, std::shared_ptr<FileLocation>> locations,
102  double payload);
103 
105  WorkflowFile *file;
113  std::string reference_host;
118  std::map<double, std::shared_ptr<FileLocation>> locations;
119  };
120 
124  class FileRegistryRemoveEntryRequestMessage : public FileRegistryMessage {
125  public:
126  FileRegistryRemoveEntryRequestMessage(std::string answer_mailbox, WorkflowFile *file,
127  std::shared_ptr<FileLocation> location, double payload);
128 
130  std::string answer_mailbox;
132  WorkflowFile *file;
134  std::shared_ptr<FileLocation> location;
135  };
136 
140  class FileRegistryRemoveEntryAnswerMessage : public FileRegistryMessage {
141  public:
142  FileRegistryRemoveEntryAnswerMessage(bool success, double payload);
143 
145  bool success;
146  };
147 
151  class FileRegistryAddEntryRequestMessage : public FileRegistryMessage {
152  public:
153  FileRegistryAddEntryRequestMessage(std::string answer_mailbox, WorkflowFile *file,
154  std::shared_ptr<FileLocation> location, double payload);
155 
157  std::string answer_mailbox;
159  WorkflowFile *file;
161  std::shared_ptr<FileLocation> location;
162  };
163 
167  class FileRegistryAddEntryAnswerMessage : public FileRegistryMessage {
168  public:
169  FileRegistryAddEntryAnswerMessage(double payload);
170  };
171 
172  /***********************/
174  /***********************/
175 };
176 
177 
178 #endif //WRENCH_FILEREGISTRYMESSAGE_H
wrench
Definition: Alarm.cpp:20