incubator-pegasus icon indicating copy to clipboard operation
incubator-pegasus copied to clipboard

Feature(new_metrics): migrate meta metrics

Open empiredan opened this issue 2 years ago • 0 comments

The meta-related metrics migrated to new framework will be attached to server entity. All involved classes are put as below.


Following metrics are the members of server_state (server_state.cpp), which is created at the construction of meta_service:

Variables Types/Computations
_dead_partition_count Gauge
_unreadable_partition_count Gauge
_unwritable_partition_count Gauge
_writable_ill_partition_count Gauge
_healthy_partition_count Gauge
_recent_update_config_count increase(Counter)
_recent_partition_change_unwritable_count increase(Counter)
_recent_partition_change_writable_count increase(Counter)

Following metrics are the members of greedy_load_balancer (greedy_load_balancer.cpp), which is created at meta_service::start():

Variables Types/Computations
_balance_operation_count Gauge
_recent_balance_move_primary_count increase(Counter)
_recent_balance_copy_primary_count increase(Counter)
_recent_balance_copy_secondary_count increase(Counter)

Following metrics are the member of meta_service (meta_service.cpp), which is created at the construction of meta_service_app:

Variables Types/Computations
_recent_disconnect_count increase(Counter)
_unalive_nodes_count Gauge
_alive_nodes_count Gauge

Following metrics are the member of policy_context and created at policy_context::start() (meta_service.cpp). policy_context is created at meta_service::start() once cold backup is enabled:

Variables Types/Computations
_counter_policy_recent_backup_duration_ms Gauge

Following metrics are the member of partition_guardian (meta_service.cpp), which is created at meta_service::start() :

Variables Types/Computations
_recent_choose_primary_fail_count increase(Counter)

empiredan avatar Jan 29 '23 07:01 empiredan