![SWC-DB logo](logo.svg) |
SWC-DB
v0.5.12 C++ documentations
SWC-DB© (Super Wide Column Database) - High Performance Scalable Database (https://github.com/kashirin-alex/swc-db)
|
Go to the documentation of this file.
6 #ifndef swcdb_manager_MngrRole_h
7 #define swcdb_manager_MngrRole_h
13 namespace SWC {
namespace Manager {
64 void print(std::ostream& out);
78 uint32_t next, uint32_t total,
bool flw,
131 #endif // swcdb_manager_MngrRole_h
void managers_checker(uint32_t next, uint32_t total, bool flw)
const Comm::EndPoints m_local_endpoints
void update_manager_addr(uint64_t hash, const Comm::EndPoint &mngr_host)
asio::high_resolution_timer m_check_timer
Comm::EndPoint get_inchain_endpoint() const
void update_state(const Comm::EndPoint &endpoint, DB::Types::MngrState state)
void apply_role_changes()
const Config::Property::Value_int32_g::Ptr cfg_conn_fb_failures
asio::ip::tcp::endpoint EndPoint
std::shared_ptr< MngrStatus > Ptr
void get_states(MngrsStatus &states)
std::shared_ptr< IoContext > IoContextPtr
MngrRole & operator=(const MngrRole &)=delete
Core::MutexAtomic m_mutex_timer
const Config::Property::Value_int32_g::Ptr cfg_delay_fallback
MngrStatus::Ptr active_mngr(cid_t cid)
MngrStatus::Ptr get_host(const Comm::EndPoints &endpoints)
void schedule_checkin(uint32_t t_ms=10000)
const uint64_t m_local_token
void manager_checker(MngrStatus::Ptr host, uint32_t next, uint32_t total, bool flw, const Comm::ConnHandlerPtr &conn)
The SWC-DB C++ namespace 'SWC'.
const Config::Property::Value_uint16_g::Ptr cfg_conn_probes
Comm::client::ConnQueuePtr m_mngr_inchain
const Config::Property::Value_int32_g::Ptr cfg_conn_timeout
std::shared_ptr< ResponseCallback > Ptr
SWC_CAN_INLINE bool running() const noexcept
bool is_active_role(uint8_t role)
MngrRole(MngrRole &&)=delete
bool are_all_active(const client::Mngr::Groups::Vec &groups)
std::shared_ptr< ConnHandler > ConnHandlerPtr
std::unordered_map< uint64_t, Comm::EndPoint > m_mngrs_client_srv
MngrRole(const Comm::IoContextPtr &app_io, const Comm::EndPoints &endpoints)
MngrRole(const MngrRole &)=delete
void disconnection(const Comm::EndPoint &endpoint_server, const Comm::EndPoint &endpoint_client, bool srv=false)
const Config::Property::Value_int32_g::Ptr cfg_delay_updated
MngrStatus::Ptr active_mngr_role(uint8_t role)
void print(std::ostream &out)
bool is_active(cid_t cid)
Core::Atomic< uint8_t > m_local_active_role
void req_mngr_inchain(const Comm::client::ConnQueue::ReqBase::Ptr &req)
bool is_group_off(const MngrStatus::Ptr &other)
const Config::Property::Value_int32_g::Ptr cfg_req_timeout
client::Mngr::Groups::Vec m_local_groups
std::shared_mutex m_mutex
MngrStatus::Ptr get_highest_state_host(const MngrStatus::Ptr &other)
std::shared_ptr< ConnQueueReqBase > Ptr
Core::StateRunning m_checkin
void set_mngr_inchain(const Comm::ConnHandlerPtr &mngr)
const Config::Property::Value_int32_g::Ptr cfg_check_interval
MngrRole & operator=(MngrRole &&)=delete
std::shared_ptr< ConnQueue > ConnQueuePtr