3 #ifndef STREAMBASE_NMCLIENT_H
4 #define STREAMBASE_NMCLIENT_H
6 #include "StreamBase.hpp"
8 #include "Exceptions.hpp"
10 #include "StreamProperties.hpp"
11 #include "StreamBaseURI.hpp"
12 #include "StreamBaseConstants.hpp"
13 #include "ClientSettings.hpp"
15 SB_INTERNAL_FWD(Admin)
32 StreamBaseAdminClient(
const std::vector<StreamBaseURI>& uris = StreamBaseURI::vectorFromEnvironment());
37 StreamBaseAdminClient(
const std::vector<StreamBaseURI>& uris,
sb::ClientSettings &settings);
40 virtual ~StreamBaseAdminClient();
43 std::string shutdown();
46 std::string shutdown(
const std::string &name) ;
49 void shutdownOperators(std::vector<std::string> &operatorNames) ;
52 void suspendOperators(std::vector<std::string> &operatorNames) ;
55 void restartOperators(std::vector<std::string> &operatorNames) ;
58 void suspend(
const std::string &name) ;
61 void restartContainer(
const std::string &name) ;
64 void resume(
const std::string &name) ;
67 void resumeOperators(std::vector<std::string> &operatorNames) ;
70 void getOperatorProperties(
const std::string &operatorName, std::vector<std::string> &result) ;
73 std::string getOperatorProperty(
const std::string &operatorName,
const std::string &propertyName) ;
76 void setOperatorProperty(
const std::string &operatorName,
const std::string &propertyName,
const std::string &value) ;
83 void takeException() ;
90 void modifyApplication(
const std::string &application);
98 std::vector<std::string> addContainer(
const std::string &containerName,
const std::string &applicationText,
const std::vector<std::string> &options);
106 std::vector<std::string> addDeploy(
const std::string &applicationText,
107 const std::vector<std::string> &options = std::vector<std::string>());
114 std::vector<std::string> removeContainer(
const std::string &containerName,
115 const std::vector<std::string> &options = std::vector<std::string>());
122 std::vector<std::string> modifyContainer(
const std::string &containerName,
const std::vector<std::string> &options);
128 void listConnections(std::vector<std::string>& result,
const std::vector<std::string> &option = std::vector<std::string>());
132 void killConnection(
const std::string &connectionId, std::vector<std::string> &status);
135 void killAllConnections(std::vector<std::string> &status);
138 std::vector<std::string> manageJdbcConnections(
const std::vector<std::string> &options);
144 void setRuntimeParam(
const std::string ¶mName,
const std::string ¶mValue,
145 const std::string &operatorName =
"");
146 #endif //DOXYGEN_SKIP
150 LeadershipStatus getLeadershipStatus();
155 void setLeadershipStatus(LeadershipStatus leadershipStatus);
161 void drain(
const std::string &containerName) ;
167 return _clientSettings;
173 StreamBaseAdminClient(
const StreamBaseAdminClient&);
176 StreamBaseAdminClient& operator = (
const StreamBaseAdminClient&);
178 std::vector<StreamBaseURI> _uris;
179 std::shared_ptr<sb_internal::Admin> _admin;