#include <swcdb/manager/AppContext.h>
Public Types | |
typedef std::shared_ptr< AppContext > | Ptr |
Public Types inherited from SWC::Comm::AppContext | |
typedef std::shared_ptr< AppContext > | Ptr |
Public Member Functions | |
AppContext () | |
void | init (const std::string &host, const Comm::EndPoints &endpoints) override |
void | set_srv (Comm::server::SerializedServer::Ptr srv) |
virtual | ~AppContext () noexcept |
void | handle_established (Comm::ConnHandlerPtr conn) override |
void | handle_disconnect (Comm::ConnHandlerPtr conn) noexcept override |
void | handle (Comm::ConnHandlerPtr conn, const Comm::Event::Ptr &ev) override |
void | net_bytes_sent (const Comm::ConnHandlerPtr &conn, size_t b) noexcept override |
void | net_bytes_received (const Comm::ConnHandlerPtr &conn, size_t b) noexcept override |
void | net_accepted (const Comm::EndPoint &endpoint, bool secure) noexcept override |
void | shutting_down (const std::error_code &ec, const int &sig) |
void | stop () override |
Public Member Functions inherited from SWC::Comm::AppContext | |
SWC_CAN_INLINE | AppContext (Config::Property::Value_enum_g::Ptr a_cfg_encoder) noexcept |
AppContext (AppContext &&)=delete | |
AppContext (const AppContext &)=delete | |
AppContext & | operator= (AppContext &&)=delete |
AppContext & | operator= (const AppContext &)=delete |
Private Attributes | |
Comm::server::SerializedServer::Ptr | m_srv |
Metric::Reporting::Ptr | m_metrics |
Additional Inherited Members | |
Public Attributes inherited from SWC::Comm::AppContext | |
const Config::Property::Value_enum_g::Ptr | cfg_encoder |
Definition at line 42 of file AppContext.h.
typedef std::shared_ptr<AppContext> SWC::Manager::AppContext::Ptr |
Definition at line 45 of file AppContext.h.
|
inline |
Definition at line 47 of file AppContext.h.
References SWC::FS::fs_type(), SWC::Env::Clients::get(), SWC::Env::Clients::init(), SWC::Env::FsInterface::init(), SWC::client::Clients::make(), SWC::Comm::IoContext::make(), and SWC::Env::Config::settings().
|
inlinevirtualnoexcept |
Reimplemented from SWC::Comm::AppContext.
Definition at line 111 of file AppContext.h.
|
inlineoverridevirtual |
Implements SWC::Comm::AppContext.
Definition at line 127 of file AppContext.h.
References SWC::Comm::Protocol::Rgr::COLUMN_COMPACT, SWC::Comm::Protocol::Mngr::Handler::column_compact(), SWC::Comm::Protocol::Mngr::COLUMN_GET, SWC::Comm::Protocol::Mngr::Handler::column_get(), SWC::Comm::Protocol::Mngr::COLUMN_LIST, SWC::Comm::Protocol::Mngr::Handler::column_list(), SWC::Comm::Protocol::Mngr::COLUMN_MNG, SWC::Comm::Protocol::Mngr::Handler::column_mng(), SWC::Comm::Protocol::Mngr::COLUMN_UPDATE, SWC::Comm::Protocol::Mngr::DO_ECHO, SWC::Comm::Protocol::Mngr::Handler::do_echo(), m_metrics, SWC::Comm::Protocol::Mngr::MNGR_ACTIVE, SWC::Comm::Protocol::Mngr::Handler::mngr_active(), SWC::Comm::Protocol::Mngr::MNGR_STATE, SWC::Comm::Protocol::Common::Handler::not_implemented(), SWC::Env::Mngr::post(), SWC::Comm::Protocol::Mngr::RANGE_CREATE, SWC::Comm::Protocol::Mngr::RANGE_REMOVE, SWC::Comm::Protocol::Mngr::RANGE_UNLOADED, SWC::Comm::Protocol::Mngr::Handler::range_unloaded(), SWC::Comm::Protocol::Rgr::REPORT, SWC::Comm::Protocol::Mngr::RGR_GET, SWC::Comm::Protocol::Mngr::Handler::rgr_get(), SWC::Comm::Protocol::Mngr::RGR_MNG_ID, SWC::Comm::Protocol::Mngr::RGR_UPDATE, and SWC::Env::Mngr::role().
|
inlineoverridevirtualnoexcept |
Implements SWC::Comm::AppContext.
Definition at line 119 of file AppContext.h.
References SWC::Manager::MngrRole::disconnection(), m_metrics, m_srv, and SWC::Env::Mngr::role().
|
inlineoverridevirtual |
Implements SWC::Comm::AppContext.
Definition at line 113 of file AppContext.h.
|
inlineoverridevirtual |
Reimplemented from SWC::Comm::AppContext.
Definition at line 84 of file AppContext.h.
References SWC::Env::Mngr::init(), SWC::Env::Mngr::io(), m_metrics, SWC::Env::Mngr::metrics_track(), SWC::Env::Config::settings(), and shutting_down().
|
inlineoverridevirtualnoexcept |
Reimplemented from SWC::Comm::AppContext.
Definition at line 237 of file AppContext.h.
References m_metrics.
|
inlineoverridevirtualnoexcept |
Reimplemented from SWC::Comm::AppContext.
Definition at line 231 of file AppContext.h.
References m_metrics.
|
inlineoverridevirtualnoexcept |
Reimplemented from SWC::Comm::AppContext.
Definition at line 225 of file AppContext.h.
References m_metrics.
|
inline |
Definition at line 107 of file AppContext.h.
References m_srv.
|
inline |
Definition at line 243 of file AppContext.h.
References SWC::Env::Mngr::io(), SWC::LOG_INFO, m_srv, shutting_down(), SWC_CAN_INLINE, SWC_LOG, SWC_LOGF, and SWC_QUICK_EXIT.
Referenced by init(), and shutting_down().
|
inlineoverridevirtual |
Reimplemented from SWC::Comm::AppContext.
Definition at line 276 of file AppContext.h.
References SWC::Env::Clients::get(), SWC::Env::FsInterface::interface(), SWC::Env::Mngr::io(), m_metrics, m_srv, SWC::Env::Clients::reset(), SWC::Env::FsInterface::reset(), SWC::Env::Mngr::reset(), and SWC::Env::Mngr::stop().
|
private |
Definition at line 309 of file AppContext.h.
Referenced by handle(), handle_disconnect(), handle_established(), init(), net_accepted(), net_bytes_received(), net_bytes_sent(), and stop().
|
private |
Definition at line 308 of file AppContext.h.
Referenced by handle_disconnect(), handle_established(), set_srv(), shutting_down(), and stop().