Skip to content

MINOR: Update kafka-console-share-consumer to pass in delivery count. #19447

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

ShivsundarR
Copy link
Collaborator

What

  • There was a bug in ConsoleShareConsumer where the delivery count received in the ShareFetchResponse was not sent to the formatter to be shown to the user. PR fixes the bug by passing in the delivery count in a different constructor for ConsumerRecord.
  • Added unit test to verify the change.
  • Tested using the kafka-console-share-consumer.sh tool as well.
➜  kafka git:(minor-fix-console-share-consumer) ✗ bin/kafka-console-share-consumer.sh --bootstrap-server localhost:9092 --topic T1 --property print.offset=true --property print.delivery=true
[2025-04-11 16:05:42,824] WARN Share groups and KafkaShareConsumer are part of the early access of KIP-932 and MUST NOT be used in production. (org.apache.kafka.clients.consumer.internals.ShareConsumerDelegateCreator)
[2025-04-11 16:05:43,009] WARN [ShareConsumer clientId=console-share-consumer, groupId=console-share-consumer] The metadata response from the cluster reported a recoverable issue with correlation id 28 : {T1=UNKNOWN_TOPIC_OR_PARTITION} (org.apache.kafka.clients.NetworkClient)
Offset:0	Delivery:1	1
Offset:1	Delivery:1	2
Offset:2	Delivery:1	3
Offset:3	Delivery:1	4
Offset:4	Delivery:1	5
Offset:5	Delivery:1	6

@github-actions github-actions bot added triage PRs from the community tools small Small PRs labels Apr 11, 2025
@AndrewJSchofield AndrewJSchofield added KIP-932 Queues for Kafka ci-approved and removed triage PRs from the community labels Apr 11, 2025
@AndrewJSchofield AndrewJSchofield merged commit 88a6402 into apache:trunk Apr 11, 2025
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ci-approved KIP-932 Queues for Kafka small Small PRs tools
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants