26#ifndef ROUTER_CLUSTER_METADATA_INCLUDED
27#define ROUTER_CLUSTER_METADATA_INCLUDED
87 const uint32_t router_id,
const std::string &hostname_override =
"") = 0;
103 const std::string &router_name,
const bool overwrite,
104 const std::string &hostname_override =
"") = 0;
107 const uint32_t router_id,
const std::string &cluster_id,
108 const std::string &target_cluster,
const std::string &rw_endpoint,
109 const std::string &ro_endpoint,
const std::string &rw_x_endpoint,
110 const std::string &ro_x_endpoint,
const std::string &username) = 0;
145 const std::string &new_accounts)
const = 0;
147 virtual std::vector<std::tuple<std::string, unsigned long>>
153 const std::string & ) {
204 const uint32_t router_id,
205 const std::string &hostname_override =
"")
override;
208 const uint32_t router_id,
const std::string &cluster_id,
209 const std::string &target_cluster,
const std::string &rw_endpoint,
210 const std::string &ro_endpoint,
const std::string &rw_x_endpoint,
211 const std::string &ro_x_endpoint,
const std::string &username)
override;
213 uint32_t
register_router(
const std::string &router_name,
const bool overwrite,
214 const std::string &hostname_override =
"")
override;
217 const std::string &new_accounts)
const override;
242 uint32_t router_id,
const std::string &hostname_override =
"")
override;
245 const uint32_t router_id,
const std::string &cluster_id,
246 const std::string &target_cluster,
const std::string &rw_endpoint,
247 const std::string &ro_endpoint,
const std::string &rw_x_endpoint,
248 const std::string &ro_x_endpoint,
const std::string &username)
override;
250 uint32_t
register_router(
const std::string &router_name,
const bool overwrite,
251 const std::string &hostname_override =
"")
override;
254 const std::string &new_accounts)
const override;
292 uint64_t
get_view_id(
const std::string &cluster_type_specific_id)
override;
295 const uint32_t router_id,
const std::string &cluster_id,
296 const std::string &target_cluster,
const std::string &rw_endpoint,
297 const std::string &ro_endpoint,
const std::string &rw_x_endpoint,
298 const std::string &ro_x_endpoint,
const std::string &username)
override;
328 const std::string & )
override;
333 uint32_t router_id,
const std::string &hostname_override =
"")
override;
336 const uint32_t router_id,
const std::string &cluster_id,
337 const std::string &target_cluster,
const std::string &rw_endpoint,
338 const std::string &ro_endpoint,
const std::string &rw_x_endpoint,
339 const std::string &ro_x_endpoint,
const std::string &username)
override;
341 uint32_t
register_router(
const std::string &router_name,
const bool overwrite,
342 const std::string &hostname_override =
"")
override;
345 const std::string &new_accounts)
const override;
Base class to allow multiple SocketOperations implementations (at least one "real" and one mock for t...
Definition: socket_operations.h:45
static SocketOperations * instance()
Definition: socket_operations.cc:42
Definition: mysql_session.h:153
Definition: instrumented_condition_variable.h:32
std::unique_ptr< ClusterMetadata > create_metadata(const MetadataSchemaVersion &schema_version, MySQLSession *mysql, const OptionsMap &options, mysql_harness::SocketOperationsBase *sockops)
Definition: cluster_metadata.cc:1208
ClusterType
Definition: cluster_metadata.h:141
std::map< std::string, std::string > OptionsMap
Definition: cluster_metadata.h:57
Definition: options.cc:49
#define ROUTER_LIB_EXPORT
Definition: router_export.h:15
Definition: cluster_metadata.h:40
bool is_primary
Definition: cluster_metadata.h:49
std::string get_cluster_type_specific_id() const
Definition: cluster_metadata.h:51
std::string cluster_type_specific_id
Definition: cluster_metadata.h:44
std::string cluster_id
Definition: cluster_metadata.h:42
std::vector< std::string > metadata_servers
Definition: cluster_metadata.h:41
std::string name
Definition: cluster_metadata.h:46