Repository navigation
Make test_rabbitmq_default_mode_nack_on_parse_error detect a consumer channel wedged by basic.nack - #130649
Make test_rabbitmq_default_mode_nack_on_parse_error detect a consumer channel wedged by basic.nack#130649groeneai wants to merge 2 commits into
test_rabbitmq_default_mode_nack_on_parse_error detect a consumer channel wedged by basic.nack#130649Conversation
… channel Move contrib/AMQP-CPP from 4fccd7f to 5f4c447, the merge commit of ClickHouse/AMQP-CPP#9 on the fork's master. In AMQP-CPP, MethodFrame::synchronous() returns true and every asynchronous method frame a channel sends overrides it to false. BasicNackFrame did not, although AMQP 0-9-1 has no basic.nack-ok. ChannelImpl::send() therefore set the channel's _synchronous flag after a nack, and from then on every frame was queued locally instead of written to the socket, while send() kept reporting success. RabbitMQConsumer::nackMessages() sends the cumulative nack with AMQP::multiple whenever a batch fails to be pushed to the views (or consumption is aborted). After that the consumer's basic.ack frames, later rejects and the channel close were never transmitted: rows were inserted but stayed unacked on the broker, so they are delivered again after a reconnect. The new pin also contains ClickHouse/AMQP-CPP#11 (a nesting-depth limit for decoded field tables and arrays, src/field.cpp), which is the commit ClickHouse#130541 moves to. test_rabbitmq_default_mode_nack_on_parse_error now waits for two dead letters instead of one. In the test's default error mode each streaming iteration stops at the first message that fails to parse and nacks it with a cumulative basic.nack. ChannelImpl::send() writes a frame before it sets the flag, so the first nack always reaches the broker, and with the old pin every later one is queued and never sent. With the old pin the test gets exactly one dead letter and fails. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Internal second-model review
Final re-review of the amended commit: no findings. |
Pre-PR validation gate (click to expand)
Session id: cron:clickhouse-impl-slot-4:20261110-213900 |
|
Workflow [PR], commit [26ae582] Summary: ✅ AI ReviewSummaryThe current diff strengthens Final VerdictStatus: ✅ Approve |
Build profile diff (arm_release)Comparing ✅ No significant changes. Binary sizes
The official master build is compiled with Slowest function optimization changes (ThinLTO)Median per-function time ratio to the master baseline:
Compile time of recompiled translation units10 translation units recompiled, 11 s compile time in total, 10 of them have a recent master baseline. |
CI finish ledger - 2a20025Every failure below has an owner: a fixing PR (mine or external), or a full-effort fix task
Session id: cron:our-pr-ci-monitor:20261111-033007 |
|
Fixing PR for the The |
…d it ClickHouse#130541 moved contrib/AMQP-CPP to 5f4c447 on master (commit 8d85c7f), the same commit this PR moved it to, so the basic.nack fix no longer needs this PR. Set the gitlink back to the value of this branch's merge base (4fccd7f): the PR then changes only test_rabbitmq_default_mode_nack_on_parse_error, and merging it keeps master's 5f4c447. Co-Authored-By: Claude Opus 5.5 <[email protected]>
AMQP-CPP to fix a RabbitMQ consumer that stops acknowledging messages after a nacktest_rabbitmq_default_mode_nack_on_parse_error detect a consumer channel wedged by basic.nack
Related: #130541
Related: ClickHouse/AMQP-CPP#9
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Description
The
basic.nackfix this PR was opened for (ClickHouse/AMQP-CPP#9) reached master through #130541, which movedcontrib/AMQP-CPPto the same commit5f4c447. This PR no longer changes the pin; only the test change is left.test_rabbitmq_default_mode_nack_on_parse_errorasserted at least one dead letter, and that also passes when the consumer channel is wedged: the firstbasic.nackis written to the socket before the channel marks itself synchronous, and only the frames after it are never sent. The test now waits for two dead letters. With the pin from before #130541 (4fccd7f) it gets exactly one and fails (assert 1 >= 2); with5f4c447it passes (20/20 local runs).This guards later bumps of the submodule: the open #119509 moves the pin to
cfd37eb, whosesrc/basicnackframe.hhas nosynchronous()override, the same state as4fccd7f.🤖 Generated with Claude Code
Workflow [PR]
Sync PR [sync-upstream/pr/130649]