26#ifndef ROUTER_IO_COMPONENT_INCLUDED
27#define ROUTER_IO_COMPONENT_INCLUDED
49 std::list<IoThread> &
io_threads() {
return io_threads_; }
77 thread_lifecycle_ = std::move(lifecycle);
93 const std::string &backend_name);
132 if (--io_comp_.users_ == 0) {
153 std::atomic<int> users_{};
static mysql_service_status_t init()
Component initialization.
Definition: audit_api_message_emit.cc:575
Definition: io_component.h:118
IoComponent & io_comp_
Definition: io_component.h:138
Workguard(IoComponent &io_comp)
Definition: io_component.h:120
Workguard & operator=(Workguard &&)=delete
Workguard(const Workguard &)=delete
Workguard & operator=(const Workguard &)=delete
Workguard(Workguard &&)=delete
~Workguard()
Definition: io_component.h:131
net::executor_work_guard< net::io_context::executor_type > io_ctx_work_guard_
Definition: io_component.h:139
Definition: io_component.h:47
void set_thread_lifecycle(IoThreadLifecycle lifecycle)
Set callbacks invoked from each I/O worker thread.
Definition: io_component.h:76
std::unique_ptr< net::io_context > io_ctx_
Definition: io_component.h:151
void reset_thread_lifecycle()
Definition: io_component.h:80
IoThreadLifecycle thread_lifecycle_
Definition: io_component.h:156
std::unique_ptr< IoThread > routing_acceptor_io_thread_
Definition: io_component.h:149
std::list< IoThread > & io_threads()
Definition: io_component.h:49
std::string backend_name() const
Definition: io_component.h:116
std::string backend_name_
Definition: io_component.h:155
std::list< IoThread > io_threads_
Definition: io_component.h:147
Definition: executor.h:452
Definition: io_context.h:61
Definition: expected.h:286
IoComponentErrc
Definition: io_component.h:40
IO_COMPONENT_EXPORT std::error_code make_error_code(IoComponentErrc ec)
Definition: io_component.cc:54
#define IO_COMPONENT_EXPORT
Definition: io_component_export.h:15
static void run(mysql_harness::PluginFuncEnv *)
Definition: io_plugin.cc:199
static void stop(mysql_harness::PluginFuncEnv *)
Definition: mysql_rest_service_plugin.cc:413
std::string HARNESS_EXPORT reset()
get 'reset attributes' ESC sequence.
Definition: vt100.cc:37
executor_work_guard< Executor > make_work_guard(const Executor &ex)
Definition: executor.h:496
Definition: io_thread.h:42