[
https://issues.apache.org/jira/browse/KAFKA-16304?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jun Rao resolved KAFKA-16304.
-----------------------------
Fix Version/s: 4.5.0
Assignee: Mykyta Bozhenko
Resolution: Fixed
merged the PR to trunk
> Disk I/O error does not offline log directory while handling Fetch requests
> ---------------------------------------------------------------------------
>
> Key: KAFKA-16304
> URL: https://issues.apache.org/jira/browse/KAFKA-16304
> Project: Kafka
> Issue Type: Bug
> Affects Versions: 3.6.1, 3.7.0
> Reporter: Gaurav Narula
> Assignee: Mykyta Bozhenko
> Priority: Critical
> Fix For: 4.5.0
>
>
> The Fetch API handler delays reading of record batches from disk using
> {{FileRecords::writeTo}} until the bytes are ready to be sent to the wire.
> Therefore, a disk I/O error that happens while reading the log segment in
> either {{SslTransportLayer::transferFrom}} or
> {{PlaintextTransportLayer::transferFrom}} does not cause the log directory to
> be offlined. Instead, we assume that such an {{IOException}} can only occur
> because of network related causes and close the socket instead
> [[0]|https://github.com/apache/kafka/blob/7ac50a86113c9a489667451eecf61b6ab80870db/clients/src/main/java/org/apache/kafka/common/network/Selector.java#L610]
>
> [[1]|https://github.com/apache/kafka/blob/7ac50a86113c9a489667451eecf61b6ab80870db/clients/src/main/java/org/apache/kafka/common/network/Selector.java#L629]
> We should disambiguate between IOExceptions due to network and disk
> operations and offline the log directory in case of the latter as we do for
> other disk related failures.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)