Skip to content

Commit

Permalink
Update kafka_exporter.go
Browse files Browse the repository at this point in the history
Addressing comments
  • Loading branch information
sciclon2 authored Mar 16, 2024
1 parent 7166dce commit e4cca9c
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions kafka_exporter.go
Original file line number Diff line number Diff line change
Expand Up @@ -569,10 +569,6 @@ func (e *Exporter) collect(ch chan<- prometheus.Metric) {
return
}
for _, group := range describeGroups.Groups {
if group.ProtocolType != "consumer" {
klog.Warningf("Group '%v' is using a protocol type other than 'consumer'. It may not be compatible with functions relying on consumer group protocols.", group.GroupId)
continue
}
offsetFetchRequest := sarama.OffsetFetchRequest{ConsumerGroup: group.GroupId, Version: 1}
if e.offsetShowAll {
for topic, partitions := range offset {
Expand All @@ -585,7 +581,7 @@ func (e *Exporter) collect(ch chan<- prometheus.Metric) {
assignment, err := member.GetMemberAssignment()
if err != nil {
klog.Errorf("Cannot get GetMemberAssignment of group member %v : %v", member, err)
return
continue
}
for topic, partions := range assignment.Topics {
for _, partition := range partions {
Expand Down

0 comments on commit e4cca9c

Please sign in to comment.