Skip to content

[KIP-932]: Implement api to acknowledge deserialization failure offsets - #5515

Open
Pratyush Ranjan (PratRanj07) wants to merge 1 commit into
masterfrom
dev_kip-932_implement_ack_deser_failures
Open

[KIP-932]: Implement api to acknowledge deserialization failure offsets#5515
Pratyush Ranjan (PratRanj07) wants to merge 1 commit into
masterfrom
dev_kip-932_implement_ack_deser_failures

Conversation

@PratRanj07

Copy link
Copy Markdown
Contributor

Implement api to acknowledge deserialization failure offsets

Copilot AI review requested due to automatic review settings June 20, 2026 23:39
@PratRanj07
Pratyush Ranjan (PratRanj07) requested a review from a team as a code owner June 20, 2026 23:39
@confluent-cla-assistant

Copy link
Copy Markdown

🎉 All Contributor License Agreements have been signed. Ready to merge.
Please push an empty commit if you would like to re-run the checks to verify CLA status for all contributors.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a share-consumer bulk API intended for higher-level client libraries to release (RELEASE) a set of offsets that failed client-side deserialization, enabling broker redelivery without using the per-message acknowledge APIs (which are gated in implicit ack mode).

Changes:

  • Introduces rd_kafka_topic_partition_set_offsets() to attach an offsets array to rd_kafka_topic_partition_t via its private glue.
  • Implements rd_kafka_share_acknowledge_deserialization_failure() to mark attached offsets as RELEASE (best-effort, with aggregated error reporting).
  • Adds integration tests covering explicit mode, implicit partial release behavior, and error surfacing.

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tests/0172-share_consumer_acknowledge.c Adds test cases validating bulk-release/redelivery semantics and error handling for the new API.
src/rdkafka.h Declares the new public APIs and documents intended usage for client libraries.
src/rdkafka_share_acknowledgement.c Implements the bulk deserialization-failure acknowledge/release operation.
src/rdkafka_partition.h Extends rd_kafka_topic_partition_private_t to hold an optional offsets array.
src/rdkafka_partition.c Implements offsets attach/clear, ensures deep-copy in partition copy/update paths, and frees offsets in private destroy.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/rdkafka.h
Comment on lines +3488 to +3490
rd_kafka_error_t *rd_kafka_share_acknowledge_deserialization_failure(
rd_kafka_share_t *rkshare,
const rd_kafka_topic_partition_list_t *partitions);
Comment on lines +1065 to +1067
rd_kafka_error_t *rd_kafka_share_acknowledge_deserialization_failure(
rd_kafka_share_t *rkshare,
const rd_kafka_topic_partition_list_t *partitions) {
Comment on lines +1131 to +1135
err = rd_kafka_share_find_ack_entry(
rkshare, rktpar->topic, rktpar->partition, offset,
&entry, &idx);
if (err)
goto record_err;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants