CUBRID Engine
latest
|
#include <monitor_registration.hpp>
Classes | |
struct | registration |
Public Types | |
using | fetch_function = std::function< void(statistic_value *, fetch_mode)> |
Public Member Functions | |
monitor () | |
void | register_statistics (std::size_t statistics_count, const fetch_function &fetch_f, const std::vector< std::string > &names) |
template<class S > | |
void | register_statistics (const S &statistics, std::vector< std::string > &names) |
std::size_t | get_statistics_count (void) const |
std::size_t | get_registered_count (void) const |
const std::string & | get_statistic_name (std::size_t index) const |
std::size_t | get_statistic_values_memsize (void) const |
std::size_t | get_registrations_memsize (void) const |
statistic_value * | allocate_statistics_buffer (void) const |
void | fetch_global_statistics (statistic_value *destination) const |
void | fetch_transaction_statistics (statistic_value *destination) const |
void | fetch_statistics (statistic_value *destination, fetch_mode mode) const |
Private Member Functions | |
void | add_registration (std::size_t count, const fetch_function &fetch_f) |
void | check_name_count (void) const |
Private Attributes | |
std::size_t | m_total_statistics_count |
std::vector< std::string > | m_all_names |
std::vector< registration > | m_registrations |
Definition at line 65 of file monitor_registration.hpp.
using cubmonitor::monitor::fetch_function = std::function<void (statistic_value *, fetch_mode)> |
Definition at line 71 of file monitor_registration.hpp.
cubmonitor::monitor::monitor | ( | ) |
Definition at line 45 of file monitor_registration.cpp.
|
private |
Definition at line 124 of file monitor_registration.cpp.
References cubregex::count(), fetch_func, cubmonitor::monitor::registration::m_fetch_func, m_registrations, cubmonitor::monitor::registration::m_statistics_count, and m_total_statistics_count.
Referenced by register_statistics().
statistic_value * cubmonitor::monitor::allocate_statistics_buffer | ( | void | ) | const |
Definition at line 84 of file monitor_registration.cpp.
References get_statistics_count().
|
private |
Definition at line 118 of file monitor_registration.cpp.
References assert, m_all_names, and m_total_statistics_count.
Referenced by register_statistics().
void cubmonitor::monitor::fetch_global_statistics | ( | statistic_value * | destination | ) | const |
Definition at line 101 of file monitor_registration.cpp.
References cubmonitor::FETCH_GLOBAL, and fetch_statistics().
void cubmonitor::monitor::fetch_statistics | ( | statistic_value * | destination, |
fetch_mode | mode | ||
) | const |
Definition at line 90 of file monitor_registration.cpp.
References m_registrations.
Referenced by fetch_global_statistics(), and fetch_transaction_statistics().
void cubmonitor::monitor::fetch_transaction_statistics | ( | statistic_value * | destination | ) | const |
Definition at line 107 of file monitor_registration.cpp.
References fetch_statistics(), cubmonitor::FETCH_TRANSACTION_SHEET, cubmonitor::transaction_sheet_manager::get_sheet(), and cubmonitor::transaction_sheet_manager::INVALID_TRANSACTION_SHEET.
std::size_t cubmonitor::monitor::get_registered_count | ( | void | ) | const |
Definition at line 60 of file monitor_registration.cpp.
References m_registrations.
Referenced by get_registrations_memsize().
std::size_t cubmonitor::monitor::get_registrations_memsize | ( | void | ) | const |
Definition at line 78 of file monitor_registration.cpp.
References get_registered_count().
const std::string & cubmonitor::monitor::get_statistic_name | ( | std::size_t | index | ) | const |
Definition at line 66 of file monitor_registration.cpp.
References m_all_names.
std::size_t cubmonitor::monitor::get_statistic_values_memsize | ( | void | ) | const |
Definition at line 72 of file monitor_registration.cpp.
References get_statistics_count().
std::size_t cubmonitor::monitor::get_statistics_count | ( | void | ) | const |
Definition at line 54 of file monitor_registration.cpp.
References m_total_statistics_count.
Referenced by allocate_statistics_buffer(), and get_statistic_values_memsize().
void cubmonitor::monitor::register_statistics | ( | std::size_t | statistics_count, |
const fetch_function & | fetch_f, | ||
const std::vector< std::string > & | names | ||
) |
Definition at line 136 of file monitor_registration.cpp.
References add_registration(), assert, check_name_count(), and m_all_names.
Referenced by register_statistics(), cubmonitor::counter_timer_statistic< A, T >::register_to_monitor(), and cubmonitor::counter_timer_max_statistic< A, T, M >::register_to_monitor().
void cubmonitor::monitor::register_statistics | ( | const S & | statistics, |
std::vector< std::string > & | names | ||
) |
Definition at line 135 of file monitor_registration.hpp.
References mode, and register_statistics().
|
private |
Definition at line 122 of file monitor_registration.hpp.
Referenced by check_name_count(), get_statistic_name(), and register_statistics().
|
private |
Definition at line 124 of file monitor_registration.hpp.
Referenced by add_registration(), fetch_statistics(), and get_registered_count().
|
private |
Definition at line 120 of file monitor_registration.hpp.
Referenced by add_registration(), check_name_count(), and get_statistics_count().