blob: ec61ec5ac4c7f4671579155ef5cf1e5ea6d34b7b [file] [log] [blame]
# Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license agreements. See the NOTICE file distributed with
# this work for additional information regarding copyright ownership.
# The ASF licenses this file to You under the Apache License, Version 2.0
# (the "License"); you may not use this file except in compliance with
# the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# This will parse a textual representation of a duration. The formats
# accepted are based on the ISO-8601 duration format {@code PnDTnHnMn.nS}
# with days considered to be exactly 24 hours.
# <p>
# Examples:
# <pre>
# "PT20.345S" -- parses as "20.345 seconds"
# "PT15M" -- parses as "15 minutes" (where a minute is 60 seconds)
# "PT10H" -- parses as "10 hours" (where an hour is 3600 seconds)
# "P2D" -- parses as "2 days" (where a day is 24 hours or 86400 seconds)
# "P2DT3H4M" -- parses as "2 days, 3 hours and 4 minutes"
# "P-6H3M" -- parses as "-6 hours and +3 minutes"
# "-P6H3M" -- parses as "-6 hours and -3 minutes"
# "-P-6H+3M" -- parses as "+6 hours and -3 minutes"
# </pre>
filter: "{ tags -> tags.job_name == 'rocketmq-monitoring' }" # The OpenTelemetry job name
expSuffix: tag({tags -> tags.cluster = 'rocketmq::' + tags.cluster}).service(['cluster'], Layer.ROCKETMQ)
metricPrefix: meter_rocketmq_cluster
metricsRules:
- name: messages_produced_today
exp: rocketmq_brokeruntime_msg_put_total_today_now.sum((['cluster']))-rocketmq_brokeruntime_msg_puttotal_yesterdaymorning.sum(['cluster'])
- name: messages_consumed_today
exp: rocketmq_brokeruntime_msg_gettotal_today_now.sum(['cluster'])-rocketmq_brokeruntime_msg_gettotal_yesterdaymorning.sum(['cluster'])
- name: total_producer_tps
exp: rocketmq_producer_tps.sum(['cluster'])
- name: total_consumer_tps
exp: rocketmq_consumer_tps.sum(['cluster'])
- name: producer_message_size
exp: rocketmq_producer_message_size.sum(['cluster']).downsampling(MAX)
- name: consumer_message_size
exp: rocketmq_consumer_message_size.sum(['cluster']).downsampling(MAX)
- name: messages_produced_until_yesterday
exp: rocketmq_brokeruntime_msg_puttotal_yesterdaymorning.sum(['cluster'])
- name: messages_consumed_until_yesterday
exp: rocketmq_brokeruntime_msg_gettotal_yesterdaymorning.sum(['cluster'])
- name: max_consumer_latency
exp: rocketmq_group_get_latency_by_storetime.max(['cluster','broker','topic','group'])
- name: max_commitLog_disk_ratio
exp: rocketmq_brokeruntime_commitlog_disk_ratio.max(['cluster','brokerIP'])*100
- name: commitLog_disk_ratio
exp: rocketmq_brokeruntime_commitlog_disk_ratio.sum(['cluster','brokerIP'])*100
- name: pull_threadPool_queue_head_wait_time
exp: rocketmq_brokeruntime_pull_threadpoolqueue_headwait_timemills.sum(['cluster','brokerIP'])
- name: send_threadPool_queue_head_wait_time
exp: rocketmq_brokeruntime_send_threadpoolqueue_headwait_timemills.sum(['cluster','brokerIP'])
- name: topic_count
exp: rocketmq_producer_offset.count(['cluster','topic'])
- name: broker_count
exp: rocketmq_producer_offset.count(['cluster','broker'])