Skip to content

Huawei Cloud DMS Kafka

Collect Huawei Cloud DMS Kafka Metrics

Configuration

Install Func

It is recommended to activate TrueWatch Integration - Extensions - DataFlux Func (Automata): All prerequisites are automatically installed, please proceed with the script installation.

If you need to deploy Func manually, refer to Manual Deployment of Func

Install Script

Note: Please prepare the Huawei Cloud AK in advance (for simplicity, you can grant the global read-only permission ReadOnlyAccess)

  1. Log in to the Func console, click 【Script Market】, enter the TrueWatch Script Market, and search for ID: integration_huaweicloud_kafka

  2. Click 【Install】, then enter the corresponding parameters: Huawei Cloud AK, SK, and account name

  3. Click 【Deploy Startup Script】, the system will automatically create the Startup script set and configure the corresponding startup script

  4. After enabling, you can see the corresponding automatic trigger configuration in 「Manage / Automatic Trigger Configuration」. Click 【Execute】 to immediately execute once without waiting for the scheduled time. Wait a moment, you can view the execution task records and corresponding logs

Verification

  1. In 「Manage / Automatic Trigger Configuration」, confirm whether the corresponding task has the automatic trigger configuration, and check the corresponding task records and logs for any exceptions
  2. In TrueWatch, check if there is asset information in 「Infrastructure - Resource Catalog」
  3. In TrueWatch, check if there is corresponding monitoring data in 「Metrics」

Metrics

Collect Huawei Cloud DMS Kafka Metrics, more metrics can be collected through configuration Huawei Cloud DMS Kafka Metrics Details

Instance Monitoring Metrics

Metric Name Metric Meaning Unit Dimensions
current_partitions This metric is used to count the number of partitions used in the Kafka instance Count instance_id
current_topics This metric is used to count the number of topics created in the Kafka instance Count instance_id
group_msgs This metric is used to count the total number of backlogged messages in all consumer groups in the Kafka instance Count instance_id

Node Monitoring Metrics

Metric Name Metric Meaning Unit Dimensions
broker_data_size This metric is used to count the current message data size of the node Byte instance_id
broker_messages_in_rate This metric is used to count the number of messages produced per second Count/s instance_id
broker_bytes_in_rate This metric is used to count the number of bytes produced per second Byte/s instance_id
broker_bytes_out_rate This metric is used to count the number of bytes consumed per second Byte/s instance_id
broker_public_bytes_in_rate This metric is used to count the public network access inflow traffic per second of the Broker node Byte/s instance_id
broker_public_bytes_out_rate This metric is used to count the public network access outflow traffic per second of the Broker node Byte/s instance_id
broker_fetch_mean This metric is used to count the average duration of consumer request processing of the Broker node ms instance_id
broker_produce_mean This metric is used to count the average duration of producer request processing ms instance_id
broker_cpu_core_load This metric is used to count the average load of each CPU core of the Kafka node virtual machine % instance_id
broker_disk_usage This metric is used to count the disk capacity usage rate of the Kafka node virtual machine % instance_id
broker_memory_usage This metric is used to count the memory usage rate of the Kafka node virtual machine % instance_id
broker_heap_usage This metric is used to count the heap memory usage rate of the Kafka process JVM of the Kafka node % instance_id
broker_alive This metric is used to indicate whether the Kafka node is alive 1: Alive 0: Offline instance_id
broker_connections This metric is used to count the current number of TCP connections of the Kafka node Count instance_id
broker_cpu_usage This metric is used to count the CPU usage rate of the Kafka node virtual machine % instance_id
broker_total_bytes_in_rate This metric is used to count the network access inflow traffic per second of the Broker node Byte/s instance_id
broker_total_bytes_out_rate This metric is used to count the network access outflow traffic per second of the Broker node Byte/s instance_id
broker_disk_read_rate This metric is used to count the disk read operation traffic Byte/s instance_id
broker_disk_write_rate This metric is used to count the disk write operation traffic Byte/s instance_id
network_bandwidth_usage This metric is used to count the network bandwidth utilization rate % instance_id

Consumer Group Monitoring Metrics

Metric Name Metric Meaning Unit Dimensions
messages_consumed This metric is used to count the number of messages already consumed by the current consumer group Count instance_id
messages_remained This metric is used to count the number of messages that can be consumed by the consumer group Count instance_id
topic_messages_remained This metric is used to count the number of messages that can be consumed by the consumer group in the specified queue Count instance_id
topic_messages_consumed This metric is used to count the number of messages already consumed by the consumer group in the specified queue Count instance_id
consumer_messages_remained This metric is used to count the number of messages that can be consumed by the consumer group Count instance_id
consumer_messages_consumed This metric is used to count the number of messages already consumed by the consumer group Count instance_id

Object

The collected Huawei Cloud Kafka object data structure can be seen in 「Infrastructure - Resource Catalog」

{
  "measurement": "huaweicloud_kafka",
  "tags": {      
    "RegionId"           : "cn-north-4",
    "charging_mode"      : "1",
    "connect_address"    : "192.168.0.161,192.168.0.126,192.168.0.31",
    "description"        : "",
    "engine"             : "kafka",
    "engine_version"     : "2.7",
    "instance_id"        : "beb33e02-xxxx-xxxx-xxxx-628a3994fd1f",
    "kafka_manager_user" : "",
    "name"               : "beb33e02-xxxx-xxxx-xxxx-628a3994fd1f",
    "port"               : "9092",
    "project_id"         : "f5f4c067d68xxxx86e173b18367bf",
    "resource_spec_code" : "",
    "service_type"       : "advanced",
    "specification"      : "kafka.2u4g.cluster.small * 3 broker",
    "status"             : "RUNNING",
    "storage_type"       : "hec",
    "user_id"            : "e4b27d49128e4bd0893b28d032a2e7c0",
    "user_name"          : "xxxx"
  },
  "fields": {
    "created_at"          : "1693203968959",
    "maintain_begin"      : "02:00:00",
    "maintain_end"        : "06:00:00",
    "storage_space"       : 186,
    "total_storage_space" : 300,
    "message"             : "{Instance JSON Data}"
  }
}

Note: The fields in tags and fields may change with subsequent updates

Tip 1: The value of tags.name is the instance ID, used as the unique identifier

Tip 2: The following fields are all JSON serialized strings