10 #ifndef WRENCH_BATSCHEDNETWORKLISTENER_H
11 #define WRENCH_BATSCHEDNETWORKLISTENER_H
13 #include "wrench/services/Service.h"
14 #include "BatchComputeServiceProperty.h"
19 class BatchComputeService;
25 #ifdef ENABLE_BATSCHED
29 class BatschedNetworkListener:
public Service {
33 BatschedNetworkListener(std::string hostname, std::shared_ptr<BatchComputeService> batch_service,
34 simgrid::s4u::Mailbox *batch_service_mailbox, std::string sched_port,
35 std::string data_to_send,WRENCH_PROPERTY_COLLECTION_TYPE property_list = {});
37 WRENCH_PROPERTY_COLLECTION_TYPE default_property_values = {
40 WRENCH_MESSAGE_PAYLOADCOLLECTION_TYPE default_messagepayload_values = {
43 BatschedNetworkListener(std::string, std::shared_ptr<BatchComputeService> batch_service, simgrid::s4u::Mailbox *batch_service_mailbox, std::string sched_port,
44 std::string data_to_send, WRENCH_PROPERTY_COLLECTION_TYPE property_list, std::string suffix);
48 std::string self_port;
49 std::string sched_port;
50 std::string data_to_send;
51 std::string reply_received;
52 std::shared_ptr<BatchComputeService> batch_service;
53 simgrid::s4u::Mailbox *batch_service_mailbox;
55 void sendExecuteMessageToBatchComputeService(simgrid::s4u::Mailbox *answer_mailbox, std::string execute_job_reply_data);
56 void sendQueryAnswerMessageToBatchComputeService(
double estimated_waiting_time);
60 #else // ENABLE_BATSCHED
75 #endif //WRENCH_BATSCHEDNETWORKLISTENER_H