ARC SDK
DataDeliveryRemoteComm.h
1 #ifndef DATADELIVERYREMOTECOMM_H_
2 #define DATADELIVERYREMOTECOMM_H_
3 
4 #include <arc/XMLNode.h>
5 #include <arc/communication/ClientInterface.h>
6 #include <arc/message/MCC.h>
7 
8 #include "DataDeliveryComm.h"
9 
10 namespace DataStaging {
11 
13 
18  public:
22  virtual ~DataDeliveryRemoteComm();
23 
25  virtual void PullStatus();
26 
28  static bool CheckComm(DTR_ptr dtr, std::vector<std::string>& allowed_dirs);
29 
31  virtual operator bool() const { return valid; };
33  virtual bool operator!() const { return !valid; };
34 
35  private:
37  Arc::ClientSOAP* client;
39  std::string dtr_full_id;
43  int query_retries;
45  Arc::MCCConfig cfg;
47  Arc::URL endpoint;
49  int timeout;
50 
52  bool valid;
54  static Arc::Logger logger;
55 
57  void CancelDTR();
58 
61  void FillStatus(const Arc::XMLNode& node = Arc::XMLNode());
62 
64  bool SetupDelegation(Arc::XMLNode& op, const Arc::UserConfig& usercfg);
65 
67  void HandleQueryFault(const std::string& err="");
68 
69  };
70 
71 } // namespace DataStaging
72 
73 #endif /* DATADELIVERYREMOTECOMM_H_ */