Description
The relevant discussion is here - https://issues.apache.org/jira/browse/KAFKA-238?focusedCommentId=13191350&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-13191350 and on KAFKA-642
We have an api that gets cluster-wide metadata (getTopicmetdata) which we use for bootstraping knowledge about the cluster. But some things can only be fetched from the leader for the partition.
With replication, the metadata about log segments can only be returned by a broker that hosts that partition locally. It will be good to expose log segment metadata through a more general replica metadata API that in addition to returning offsets, also returns other metadata like - number of log segments, total size, last modified timestamp, highwater mark, and log end offset.
It would be good to do a wiki design on this and get consensus on that first since this would be a public api.