ahuang98 commented on code in PR #21028:
URL: https://github.com/apache/kafka/pull/21028#discussion_r2687995233
##########
raft/src/main/java/org/apache/kafka/raft/RaftLog.java:
##########
@@ -58,8 +58,26 @@ public interface RaftLog extends AutoCloseable {
/**
* Read a set of records within a range of offsets.
+ * maxTotalRecordsSizeBytes specifies a "soft" max for total byte size of
the records to read.
*/
- LogFetchInfo read(long startOffsetInclusive, Isolation isolation);
+ LogFetchInfo read(long startOffsetInclusive, Isolation isolation, int
maxTotalRecordsSizeBytes);
+
+ /**
+ * Configures a soft max for total size of bytes read via default read
function implementation.
+ * Reads which are called from Fetch requests have a configured soft-max
at the Quorum level (KIP-1219).
+ * Most reads are, however, intended to be from a disk based raft log to
memory.
+ * The default is intended for local reads with only reads intended to be
transmitted as a response to fetch using
+ * the non-default implementation.
Review Comment:
I felt a bit tripped up reading this - "default intended for non-default
implementation", "local reads with only reads intended" - wonder if we can
phrase this differently
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]