Skip to content

{186543087}: cdb2api: Don't retry on pooled connections to the failin… - #6306

Merged
chands10 merged 1 commit into
bloomberg:mainfrom
chands10:retries
Oct 7, 2026
Merged

chands10 merged 1 commit into
bloomberg:mainfrom
chands10:retries

Conversation

@chands10

@chands10 chands10 commented Oct 7, 2026

Copy link
Copy Markdown
Contributor

…g node

When a query is dropped (e.g. by an incoherent node) or rejected, the retry asked sockpool for any connection under the tier's typestr, which can hand back another connection to the same node. Every attempt could land on that node until the retries ran out with "Maximum number of retries done".

Set is_rejected on these retries, as legacy cdb2api does, so the retry connects to the chosen host instead. Also reset node_seq and hosts_connected only after reject handling, so a reject retry moves on to the next node rather than restarting the search.

Add a test that fills sockpool with connections to one replicant, makes it incoherent, and checks that a query reaches another node within a few attempts.

…g node

When a query is dropped (e.g. by an incoherent node) or rejected, the retry
asked sockpool for any connection under the tier's typestr, which can hand
back another connection to the same node. Every attempt could land on that
node until the retries ran out with "Maximum number of retries done".

Set is_rejected on these retries, as legacy cdb2api does, so the retry
connects to the chosen host instead. Also reset node_seq and hosts_connected
only after reject handling, so a reject retry moves on to the next node
rather than restarting the search.

Add a test that fills sockpool with connections to one replicant, makes it
incoherent, and checks that a query reaches another node within a few
attempts.

Signed-off-by: Salil Chandra <schandra107@bloomberg.net>

@roborivers roborivers 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.

Cbuild submission: Success ✓.
Regression testing: Success ✓.

The first 10 failing tests are:
comdb2sys_queueodh_generated [db unavailable at finish]
comdb2sys [db unavailable at finish] **quarantined**
consumer_non_atomic_default_consumer_generated **quarantined**

@chands10
chands10 merged commit 1b72fc9 into bloomberg:main Oct 7, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants