Skip to content

Commit

Permalink
Increased flexver request size for Metadata request to include topic_…
Browse files Browse the repository at this point in the history
…id size (#4453)

Co-authored-by: Emanuele Sabellico <esabellico@confluent.io>
Co-authored-by: Milind L <milindl@users.noreply.github.com>
  • Loading branch information
3 people authored Sep 29, 2023
1 parent 788cd0c commit bd2afcf
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/rdkafka_request.c
Original file line number Diff line number Diff line change
Expand Up @@ -2231,9 +2231,11 @@ rd_kafka_MetadataRequest0(rd_kafka_broker_t *rkb,
ApiVersion = rd_kafka_broker_ApiVersion_supported(
rkb, RD_KAFKAP_Metadata, 0, metadata_max_version, &features);

rkbuf = rd_kafka_buf_new_flexver_request(rkb, RD_KAFKAP_Metadata, 1,
4 + (50 * topic_cnt) + 1,
ApiVersion >= 9);
rkbuf = rd_kafka_buf_new_flexver_request(
rkb, RD_KAFKAP_Metadata, 1,
4 + (66 /* 50 for topic name and 16 for topic id */ * topic_cnt) +
1,
ApiVersion >= 9);

if (!reason)
reason = "";
Expand Down

0 comments on commit bd2afcf

Please sign in to comment.