Invoke the onDelta callbacks for zero deltas too
It turns out that datadog doesn't indicate that the delta is shrinking unless you report a zero value.
This commit is contained in:
parent
55008192f8
commit
a444f49b46
|
@ -68,11 +68,10 @@ class KafkaPoller extends Thread {
|
|||
TopicPartition tp = new TopicPartition(f.topic, p.partitionId)
|
||||
|
||||
this.consumersMap[tp].each { zk.ConsumerOffset c ->
|
||||
logger.debug("Values for ${c.groupName} on ${tp.topic}:${tp.partition}: ${offset} - ${c.offset}")
|
||||
Long delta = offset - c.offset
|
||||
if (delta > 0) {
|
||||
this.onDelta.each { Closure callback ->
|
||||
callback.call(c.groupName, tp, delta)
|
||||
}
|
||||
this.onDelta.each { Closure callback ->
|
||||
callback.call(c.groupName, tp, delta)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue