Skip to content

Conversation

@pmupkin
Copy link
Contributor

@pmupkin pmupkin commented Aug 23, 2025

Fixes #24526

Motivation

As reported in issue #24526, this is a flaky test caused by an array index out of bounds exception in findFailoverTo(), which leads to the failover logic failing. As a result, the test conditions can never be met, eventually causing a timeout.

Modifications

  • Fixed the array index out of bounds issue in SameAuthParamsLookupAutoClusterFailover.findFailoverTo() .
  • Corrected the comment for SameAuthParamsLookupAutoClusterFailoverTest.

Verifying this change

  • Make sure that the change passes the CI checks.

Does this pull request potentially affect one of the following parts:

If the box was checked, please highlight the changes

  • Dependencies (add or upgrade a dependency)
  • The public API
  • The schema
  • The default values of configurations
  • The threading model
  • The binary protocol
  • The REST endpoints
  • The admin CLI options
  • The metrics
  • Anything that affects deployment

Documentation

  • doc
  • doc-required
  • doc-not-needed
  • doc-complete

Matching PR in forked repository

PR in forked repository:

@github-actions github-actions bot added the doc-not-needed Your PR changes do not impact docs label Aug 23, 2025
@lhotari lhotari changed the title [fix][test]fix flaky SameAuthParamsLookupAutoClusterFailoverTest [fix][client] fix ArrayIndexOutOfBoundsException in SameAuthParamsLookupAutoClusterFailover Aug 25, 2025
Copy link
Member

@lhotari lhotari left a comment

Choose a reason for hiding this comment

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

LGTM, Thanks for fixing @pmupkin. I renamed the title since this fixes a production code issue.

@lhotari lhotari requested a review from poorbarcode August 25, 2025 08:18
@codecov-commenter
Copy link

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 74.31%. Comparing base (64137f6) to head (e0507ae).
⚠️ Report is 11 commits behind head on master.

Files with missing lines Patch % Lines
.../impl/SameAuthParamsLookupAutoClusterFailover.java 0.00% 0 Missing and 1 partial ⚠️
Additional details and impacted files

Impacted file tree graph

@@             Coverage Diff              @@
##             master   #24662      +/-   ##
============================================
+ Coverage     74.29%   74.31%   +0.02%     
- Complexity    33173    33188      +15     
============================================
  Files          1882     1884       +2     
  Lines        146854   146913      +59     
  Branches      16866    16874       +8     
============================================
+ Hits         109105   109185      +80     
+ Misses        29078    29054      -24     
- Partials       8671     8674       +3     
Flag Coverage Δ
inttests 26.86% <0.00%> (+0.16%) ⬆️
systests 23.37% <0.00%> (+0.12%) ⬆️
unittests 73.79% <0.00%> (-0.01%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
.../impl/SameAuthParamsLookupAutoClusterFailover.java 67.07% <0.00%> (-1.83%) ⬇️

... and 85 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@lhotari lhotari added this to the 4.1.0 milestone Aug 25, 2025
@lhotari lhotari merged commit 95dcb58 into apache:master Aug 25, 2025
57 checks passed
lhotari pushed a commit that referenced this pull request Aug 26, 2025
…kupAutoClusterFailover (#24662)

(cherry picked from commit 95dcb58)
lhotari pushed a commit that referenced this pull request Aug 26, 2025
…kupAutoClusterFailover (#24662)

(cherry picked from commit 95dcb58)
lhotari pushed a commit that referenced this pull request Aug 26, 2025
…kupAutoClusterFailover (#24662)

(cherry picked from commit 95dcb58)
nodece pushed a commit to ascentstream/pulsar that referenced this pull request Aug 26, 2025
manas-ctds pushed a commit to datastax/pulsar that referenced this pull request Aug 28, 2025
…kupAutoClusterFailover (apache#24662)

(cherry picked from commit 95dcb58)
(cherry picked from commit c966506)
ganesh-ctds pushed a commit to datastax/pulsar that referenced this pull request Aug 29, 2025
…kupAutoClusterFailover (apache#24662)

(cherry picked from commit 95dcb58)
(cherry picked from commit 41a9f2f)
srinath-ctds pushed a commit to datastax/pulsar that referenced this pull request Sep 3, 2025
…kupAutoClusterFailover (apache#24662)

(cherry picked from commit 95dcb58)
(cherry picked from commit 41a9f2f)
Technoboy- pushed a commit to Technoboy-/pulsar that referenced this pull request Sep 10, 2025
srinath-ctds pushed a commit to datastax/pulsar that referenced this pull request Sep 12, 2025
…kupAutoClusterFailover (apache#24662)

(cherry picked from commit 95dcb58)
(cherry picked from commit c966506)
nborisov pushed a commit to nborisov/pulsar that referenced this pull request Sep 12, 2025
KannarFr pushed a commit to CleverCloud/pulsar that referenced this pull request Sep 22, 2025
walkinggo pushed a commit to walkinggo/pulsar that referenced this pull request Oct 8, 2025
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.

Flaky-test: SameAuthParamsLookupAutoClusterFailoverTest.testAutoClusterFailover

4 participants