You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Feature] Add two metrics rocketmq_active_topic_number and rocketmq_active_subscription_number #8223
The existing observable system of this project lacks broker-side monitoring of the number of topic and subscription group.
Describe the Solution You'd Like
Add two metrics rocketmq_active_topic_number and rocketmq_active_subscription_number as following:
Type
Name
Unit
Description
Label
Gauge
rocketmq_active_topic_number
count
The number of current topics
cluster,node_type,node_id
Gauge
rocketmq_active_subscription_number
count
The number of current subscription group
cluster,node_type,node_id
Describe Alternatives You've Considered
Anticipated use of gauge type metric
Gauge: A metric that can be incremented or decremented, used to describe the current state of a particular indicator, such as the remaining system memory.
Add metric variables to the BrokerMetricsManager class: activeTopicNum, activeSubGroupNum
Add corresponding constants to the BrokerMetricsConstant class
Build corresponding metrics inside the initStatsMetrics method of the BrokerMetricsManager class
Write a gauge update callback function that refreshes periodically
a. Call this.brokerController.topicConfigManager.getTopicConfigTable().size() to retrieve the number of topics.
b. Call brokerController.getSubscriptionGroupManager().getSubscriptionGroupTable().size() to obtain the number of subscription groups.
Here you can only get the total number of topics and subscription groups, but cannot determine whether these topics and subscription groups are active. Would it be more accurate to call it rocketmq_total_topic_number & rocketmq_total_subscription_number?
Activity
humkum commentedon May 30, 2024
Here you can only get the total number of topics and subscription groups, but cannot determine whether these topics and subscription groups are active. Would it be more accurate to call it rocketmq_total_topic_number & rocketmq_total_subscription_number?
[ISSUE #8223] Add two metrics rocketmq_topic_number and rocketmq_cons…
[ISSUE #8223] Add two metrics rocketmq_topic_number and rocketmq_cons…