...
Discussion thread: Here
JIRA: KAFKA-7711
Please keep the discussion on the mailing list rather than commenting on the wiki (wiki discussions get unwieldy fast).PR: KAFKA-7569
Motivation
Currently the call to Producer.flush() can be hang there for indeterminate time.
...
Code Block | ||||
---|---|---|---|---|
| ||||
@Override public booleanvoid flush(Duration timeout) |
This API returns true normally if flush succeed in time, i.e all previously sent records have completed ; otherwise if times out before finish sending all records, this method returns false. an TimeoutException will be thrown.
Proposed Changes
Before this proposal, there is only one flush() API, which the caller will be blocked util all the pending batches(at the moment of calling flush()) succeed or exhaust all the retries.
...