Skip to content

Commit 30f2a9c

Browse files
committed
PR #4908: Fix assignment lost, on illegal generation, during a commit
1 parent 53fb83d commit 30f2a9c

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

src/rdkafka_cgrp.c

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3803,7 +3803,12 @@ static void rd_kafka_cgrp_op_handle_OffsetCommit(rd_kafka_t *rk,
38033803
break;
38043804

38053805
case RD_KAFKA_RESP_ERR_ILLEGAL_GENERATION:
3806-
/* Revoke assignment and rebalance on illegal generation */
3806+
/* Revoke assignment and rebalance on illegal generation,
3807+
* only if not rebalancing, because a new generation id
3808+
* can be received soon after this error. */
3809+
if (RD_KAFKA_CGRP_REBALANCING(rkcg))
3810+
break;
3811+
38073812
rk->rk_cgrp->rkcg_generation_id = -1;
38083813
rd_kafka_cgrp_revoke_all_rejoin_maybe(
38093814
rkcg, rd_true /*assignment is lost*/,

0 commit comments

Comments
 (0)