[
https://issues.apache.org/jira/browse/KAFKA-10613?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17214839#comment-17214839
]
Guozhang Wang edited comment on KAFKA-10613 at 10/15/20, 5:07 PM:
------------------------------------------------------------------
When we introduce the new version 4 in list-offsets in
https://cwiki.apache.org/confluence/display/KAFKA/KIP-320%3A+Allow+fetchers+to+detect+and+handle+log+truncation#KIP320:Allowfetcherstodetectandhandlelogtruncation-ListOffsets
I think, but we did not get it since it would only affect old clients.
was (Author: guozhang):
When we introduce the new version 4 in list-offsets I think, but we did not get
it since it would only affect old clients.
> Broker should not set leader epoch if the list-offset request version < 4
> -------------------------------------------------------------------------
>
> Key: KAFKA-10613
> URL: https://issues.apache.org/jira/browse/KAFKA-10613
> Project: Kafka
> Issue Type: Bug
> Components: core
> Affects Versions: 2.1.0, 2.2.0, 2.3.0, 2.4.0, 2.5.0, 2.6.0
> Reporter: Guozhang Wang
> Assignee: Guozhang Wang
> Priority: Major
> Fix For: 2.7.0
>
>
> The list-offset response added a new field in version 4:
> {code}
> { "name": "LeaderEpoch", "type": "int32", "versions": "4+" }
> {code}
> And the compiled code would throw UnsupportedVersionException if that field
> is not default (-1) with version < 4. However, on the broker side we forget
> to add the logic to not setting this field based on the request version. This
> would cause old versioned clients' list-offset call to always get
> UnsupportedVersionException and an empty result would be returned.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)