Werner Daehn created KAFKA-6818:
-----------------------------------
Summary: Efficient way to get last n rows via admin client
Key: KAFKA-6818
URL: https://issues.apache.org/jira/browse/KAFKA-6818
Project: Kafka
Issue Type: Improvement
Components: clients
Affects Versions: 1.1.0
Reporter: Werner Daehn
Peeking into the last records of a topic is quite common, e.g. for data
preview.
Doing that however can be quite difficult. Need to get the current offset for
each partition, seek to an earlier point so that the overall record count of
all partitions is n records in sum, handle when there are less than maxcount
records in the topic etc.
Would be nice if there is a simplified API for just that, maybe in the admin
client even.
List<TopicPayload> preview(String topicname, int maxcount);
As second API for getting all data since a timestamp would be nice as well.
Although this time the amount of data could be huge, hence not convinced it
would not be better a normal seek/attach operation.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)