vamossagar12 commented on a change in pull request #9756:
URL: https://github.com/apache/kafka/pull/9756#discussion_r553472551



##########
File path: 
raft/src/main/java/org/apache/kafka/raft/internals/BatchAccumulator.java
##########
@@ -37,6 +37,7 @@
     private final Time time;
     private final SimpleTimer lingerTimer;
     private final int lingerMs;
+    private final int minFlushSize;

Review comment:
       The way I thought about it is to still keep it configurable and keep it 
within the bounds of maxBatchSize. With that, the users would have the option 
of being able to flush more frequently based on size if it suits them and not 
wait for time bound flushes. We should still ensure a lower bound for this 
config otherwise, the fsyncs can become too frequent which can have adverse 
effects. I agree, setting it higher than `maxBatchSize` also might not be too 
useful as that might potentially lead to delayed fsyncs if in case the linger 
time has also been set to a higher value.
   
   Having said that, IMO it might be useful to keep minFlushSize configurable 
which gives the users more knobs to control the behaviour based upon their 
needs(even though more knobs sometimes can mean more confusion). Do you think 
it makes sense?




----------------------------------------------------------------
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.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to