-
Notifications
You must be signed in to change notification settings - Fork 3.7k
Closed
Labels
type/bugThe PR fixed a bug or issue reported a bugThe PR fixed a bug or issue reported a bug
Description
Describe the bug
Both PartitionedConsumerImpl and ConsumerImpl have member variable unAckedMessageTrackerPtr_ (class UnAckedMessageTrackerEnabled), and PartitionedConsumerImpl is composed of ConsumerImpl. If the acknowledgement times out, they will send redeliverMessages repeatedly, MultiTopicsConsumerImpl has same problem.
see #8606 (comment)
To Reproduce
- subscribe a partitioned topic and set UnAckedMessagesTimeoutMs
Consumer consumer;
ConsumerConfiguration consumerConf;
consumerConf.setUnAckedMessagesTimeoutMs(11000); // must >= 10000
consumerConf.setTickDurationInMs(11000);
Result result = client.subscribe("my-topic", "consumer-1", consumerConf, consumer);- recevie a msg from partitioned topic and not do acknowledge
Message msg;
consumer.recevie(msg)
sleep(20000);- sleep 20000ms to trigger
redeliverMessagesrepeatedly
sleep(20000);Expected behavior
Only one redeliverUnacknowledgedMessages should be sent in PartitionedConsumerImpl
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
type/bugThe PR fixed a bug or issue reported a bugThe PR fixed a bug or issue reported a bug