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

Andrew Schofield resolved KAFKA-20315.
--------------------------------------
    Fix Version/s: 4.4.0
       Resolution: Fixed

> Add test for single in-flight poll event logic in async/share consumer
> ----------------------------------------------------------------------
>
>                 Key: KAFKA-20315
>                 URL: https://issues.apache.org/jira/browse/KAFKA-20315
>             Project: Kafka
>          Issue Type: Test
>          Components: clients, consumer
>            Reporter: Lianet Magrans
>            Assignee: Nilesh Kumar
>            Priority: Minor
>              Labels: newbie
>             Fix For: 4.4.0
>
>
> The async and share consumer send a single poll event to the background when 
> there is a call to consumer.poll. Even though there may be continuous calls 
> to poll (triggered internally from the do-while within consumer.poll, or 
> externally if the app continously calls consumer.poll), the intention is to 
> not generate a new poll event as long as the inflight hasn't completed or 
> expired.
> New event created here only:
> [https://github.com/apache/kafka/blob/2f2d9b0172ec6bfee6d332ff8b7cd39f2660a964/clients/src/main/java/org/apache/kafka/clients/consumer/internals/AsyncKafkaConsumer.java#L903]
> Seems there is no unit test coverage for inflight management, which should be 
> helpful to catch regressions (if by mistake we revert to sending too many 
> poll events). 
> Found this test gap while reviewing the changes for ShareConsumer 
> [https://github.com/apache/kafka/pull/21757#pullrequestreview-3954153888]
> This is good beginner Jira to get into the new consumer and share consumer 
> threading model



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

Reply via email to