kafka exporter v1.0.0 發(fā)布: Prometheus官方推薦,新增多項特性

kakfa exporter v1.0.0于今日正式發(fā)布,Prometheus官方推薦,新增多項特性,歡迎大家使用,多提寶貴意見。

項目地址

Github: https://github.com/danielqsj/kafka_exporter
Docker Hub: https://hub.docker.com/r/danielqsj/kafka-exporter

項目狀態(tài)

自v0.2.0版本被Prometheus項目官方推薦以來,鏡像累計下載量已超過6.1k,已經(jīng)穩(wěn)定運行在多個平臺。

特點

kafka exporter 通過 Kafka Protocol Specification 收集 Brokers, Topics 以及 Consumer Groups的相關指標,使用簡單,運行高效,相比于以往通過kafka內置的腳本進行收集,由于沒有了JVM的運行開銷,指標收集時間從分鐘級別降到秒級別,便于大規(guī)模集群的監(jiān)控。

使用方法

詳見項目說明文檔。

指標

Brokers

Metrics details

Name Exposed informations
kafka_brokers Number of Brokers in the Kafka Cluster

Metrics output example

# HELP kafka_brokers Number of Brokers in the Kafka Cluster.
# TYPE kafka_brokers gauge
kafka_brokers 3

Topics

Metrics details

Name Exposed informations
kafka_topic_partitions Number of partitions for this Topic
kafka_topic_partition_current_offset Current Offset of a Broker at Topic/Partition
kafka_topic_partition_oldest_offset Oldest Offset of a Broker at Topic/Partition
kafka_topic_partition_in_sync_replica Number of In-Sync Replicas for this Topic/Partition
kafka_topic_partition_leader Leader Broker ID of this Topic/Partition
kafka_topic_partition_leader_is_preferred 1 if Topic/Partition is using the Preferred Broker
kafka_topic_partition_replicas Number of Replicas for this Topic/Partition
kafka_topic_partition_under_replicated_partition 1 if Topic/Partition is under Replicated

Metrics output example

# HELP kafka_topic_partitions Number of partitions for this Topic
# TYPE kafka_topic_partitions gauge
kafka_topic_partitions{topic="__consumer_offsets"} 50

# HELP kafka_topic_partition_current_offset Current Offset of a Broker at Topic/Partition
# TYPE kafka_topic_partition_current_offset gauge
kafka_topic_partition_current_offset{partition="0",topic="__consumer_offsets"} 0

# HELP kafka_topic_partition_oldest_offset Oldest Offset of a Broker at Topic/Partition
# TYPE kafka_topic_partition_oldest_offset gauge
kafka_topic_partition_oldest_offset{partition="0",topic="__consumer_offsets"} 0

# HELP kafka_topic_partition_in_sync_replica Number of In-Sync Replicas for this Topic/Partition
# TYPE kafka_topic_partition_in_sync_replica gauge
kafka_topic_partition_in_sync_replica{partition="0",topic="__consumer_offsets"} 3

# HELP kafka_topic_partition_leader Leader Broker ID of this Topic/Partition
# TYPE kafka_topic_partition_leader gauge
kafka_topic_partition_leader{partition="0",topic="__consumer_offsets"} 0

# HELP kafka_topic_partition_leader_is_preferred 1 if Topic/Partition is using the Preferred Broker
# TYPE kafka_topic_partition_leader_is_preferred gauge
kafka_topic_partition_leader_is_preferred{partition="0",topic="__consumer_offsets"} 1

# HELP kafka_topic_partition_replicas Number of Replicas for this Topic/Partition
# TYPE kafka_topic_partition_replicas gauge
kafka_topic_partition_replicas{partition="0",topic="__consumer_offsets"} 3

# HELP kafka_topic_partition_under_replicated_partition 1 if Topic/Partition is under Replicated
# TYPE kafka_topic_partition_under_replicated_partition gauge
kafka_topic_partition_under_replicated_partition{partition="0",topic="__consumer_offsets"} 0

Consumer Groups

Metrics details

Name Exposed informations
kafka_consumergroup_current_offset Current Offset of a ConsumerGroup at Topic/Partition
kafka_consumergroup_lag Current Approximate Lag of a ConsumerGroup at Topic/Partition

Metrics output example

# HELP kafka_consumergroup_current_offset Current Offset of a ConsumerGroup at Topic/Partition
# TYPE kafka_consumergroup_current_offset gauge
kafka_consumergroup_current_offset{consumergroup="KMOffsetCache-kafka-manager-3806276532-ml44w",partition="0",topic="__consumer_offsets"} -1

# HELP kafka_consumergroup_lag Current Approximate Lag of a ConsumerGroup at Topic/Partition
# TYPE kafka_consumergroup_lag gauge
kafka_consumergroup_lag{consumergroup="KMOffsetCache-kafka-manager-3806276532-ml44w",partition="0",topic="__consumer_offsets"} 1

Release Notes

v1.0.0

  • [FEATURE] Support TLS
  • [FEATURE] Support disable SASL handshake
  • [FEATURE] Support enable Sarama logging for detailed connection management events
  • [ENHANCEMENT] Provide specific string for Kafka logging, debugging, and auditing purposes
  • [BUGFIX] Fix multiple prometheus servers scraping competition issue
  • [BUGFIX] Fix overwrite configuration issue

v0.3.0

  • [FEATURE] Support kafka SASL/PLAIN authentication
  • [FEATURE] Support topic filter
  • [BUGFIX] Fix topics not sync when modifying topic list

v0.2.0

  • [CHANGE] Change default port to 9308
  • [ENHANCEMENT] Support multiple addresses for kafka servers

v0.1.0

  • Initial release
?著作權歸作者所有,轉載或內容合作請聯(lián)系作者
【社區(qū)內容提示】社區(qū)部分內容疑似由AI輔助生成,瀏覽時請結合常識與多方信息審慎甄別。
平臺聲明:文章內容(如有圖片或視頻亦包括在內)由作者上傳并發(fā)布,文章內容僅代表作者本人觀點,簡書系信息發(fā)布平臺,僅提供信息存儲服務。

相關閱讀更多精彩內容

  • 時隔1個半月,kakfa exporter v0.3.0于今日正式發(fā)布,歡迎大家試用。 項目地址 Github: ...
    danielqsj閱讀 7,981評論 2 8
  • Spring Cloud為開發(fā)人員提供了快速構建分布式系統(tǒng)中一些常見模式的工具(例如配置管理,服務發(fā)現(xiàn),斷路器,智...
    卡卡羅2017閱讀 136,612評論 19 139
  • ** 今天看了一下kafka官網(wǎng),嘗試著在自己電腦上安裝和配置,然后學一下官方document。** Introd...
    RainChang閱讀 5,154評論 1 30
  • 本文轉載自http://dataunion.org/?p=9307 背景介紹Kafka簡介Kafka是一種分布式的...
    Bottle丶Fish閱讀 5,588評論 0 34
  • 路面上的雪一層又一層的鋪著,腳踩在上面發(fā)出輕輕的響聲,然后腳底就會沾一層,走一步再沾一層,直到沾到厚厚的一壘,踩實...
    左左_2c02閱讀 235評論 0 0

友情鏈接更多精彩內容