You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Lianet Magrans (Jira)" <ji...@apache.org> on 2026/06/10 18:05:00 UTC

[jira] [Resolved] (KAFKA-18862) Review testHeartbeatResponseOnErrorHandling duplicate logic in ShareHeartbeatRequestManagerTest

     [ https://issues.apache.org/jira/browse/KAFKA-18862?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Lianet Magrans resolved KAFKA-18862.
------------------------------------
    Fix Version/s: 4.4.0
       Resolution: Fixed

> Review testHeartbeatResponseOnErrorHandling duplicate logic in ShareHeartbeatRequestManagerTest
> -----------------------------------------------------------------------------------------------
>
>                 Key: KAFKA-18862
>                 URL: https://issues.apache.org/jira/browse/KAFKA-18862
>             Project: Kafka
>          Issue Type: Test
>            Reporter: Lianet Magrans
>            Assignee: Nilesh Kumar
>            Priority: Minor
>             Fix For: 4.4.0
>
>
> HB response handling is done by the same logic for consumers and shareConsumers (implemented in AbstractHeartbeatRequestManager onResponse and 
> onErrorResponse), but is tested twice, in the ConsumerHeartbeatRequestManagerTest#
> testHeartbeatResponseOnErrorHandling and in the ShareHeartbeatRequestManagerTest in a func with the same name. 
> [https://github.com/apache/kafka/blob/df5839a9f43fd0e66e553a468ea04c0999778a78/clients/src/test/java/org/apache/kafka/clients/consumer/internals/ShareHeartbeatRequestManagerTest.java#L368C17-L368C53]
> The test in Share consumer is redundant, and has stayed outdated as the error handling evolves and the Consumer test is updated (doesn't seem to make sense to maintain a duplicate of the test in Share for covering the same logic).
> We should review and avoid a duplicated test that is just staying outdated. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)