You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Elkhan Eminov (Jira)" <ji...@apache.org> on 2022/07/27 08:50:00 UTC

[jira] [Created] (KAFKA-14112) Expose replication-offset-lag Mirror metric

Elkhan Eminov created KAFKA-14112:
-------------------------------------

             Summary: Expose replication-offset-lag Mirror metric
                 Key: KAFKA-14112
                 URL: https://issues.apache.org/jira/browse/KAFKA-14112
             Project: Kafka
          Issue Type: Improvement
          Components: mirrormaker
            Reporter: Elkhan Eminov
            Assignee: Elkhan Eminov


The offset lag is the difference of the last replicated record's source offset and the end offset of the source.
The offset lag is a difference (LRO-LEO), but its constituents calculated at different point of time and place
 * LEO shall be calculated during source task's poll loop (ready to get it from the consumer)
 * LRO shall be kept in an in-memory "cache", that is updated during the task's producer callback

LRO is initialized when task is started, from the offset store. The difference shall be calculated when the freshest LEO acquired
in the poll loop. The calculated amount shall be defined as a MirrorMaker metric.

This would describe to amount of "to be replicated" number of records for a certain topic-partition.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)