You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Andreas Kohn (Jira)" <ji...@apache.org> on 2019/08/30 12:39:00 UTC

[jira] [Created] (KAFKA-8850) fetch.min.bytes documentation could be misunderstood

Andreas Kohn created KAFKA-8850:
-----------------------------------

             Summary: fetch.min.bytes documentation could be misunderstood
                 Key: KAFKA-8850
                 URL: https://issues.apache.org/jira/browse/KAFKA-8850
             Project: Kafka
          Issue Type: Improvement
          Components: documentation
            Reporter: Andreas Kohn


The current documentation for `fetch.min.bytes` says:
> The minimum amount of data the server should return for a fetch request. _If insufficient data is available the request will wait for that much data to accumulate before answering the request._ The default setting of 1 byte means that fetch requests are answered as soon as a single byte of data is available or the fetch request times out waiting for data to arrive. Setting this to something greater than 1 will cause the server to wait for larger amounts of data to accumulate which can improve server throughput a bit at the cost of some additional latency.

The highlighted sentence made me believe that Kafka would start waiting, and _as soon as enough data was available would stop waiting and return_. In reality the behavior is that Kafka will check for enough data,  and if there isn't will wait the full `fetch.max.wait.ms` time.

I would propose rewording the sentence to make that clearer, for example:
"If insufficient data is available the request will wait for `fetch.max.wait.ms` before answering the request."




--
This message was sent by Atlassian Jira
(v8.3.2#803003)