[fix][broker] Add double-check for non-durable cursor creation - #24643
Merged
nodece merged 1 commit intoAug 20, 2025
Conversation
Signed-off-by: Zixuan Liu <nodeces@gmail.com>
nodece
requested review from
BewareMyPower,
codelipenghui,
dao-jun,
lhotari and
poorbarcode
August 19, 2025 11:00
4 tasks
Member
Author
|
/pulsarbot rerun-failure-checks |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #24643 +/- ##
============================================
- Coverage 74.32% 74.26% -0.07%
+ Complexity 33180 33155 -25
============================================
Files 1882 1882
Lines 146855 146862 +7
Branches 16867 16869 +2
============================================
- Hits 109152 109063 -89
- Misses 29038 29124 +86
- Partials 8665 8675 +10
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
lhotari
pushed a commit
that referenced
this pull request
Aug 26, 2025
Signed-off-by: Zixuan Liu <nodeces@gmail.com> (cherry picked from commit e642e17)
lhotari
pushed a commit
that referenced
this pull request
Aug 26, 2025
Signed-off-by: Zixuan Liu <nodeces@gmail.com> (cherry picked from commit e642e17)
lhotari
pushed a commit
that referenced
this pull request
Aug 26, 2025
Signed-off-by: Zixuan Liu <nodeces@gmail.com> (cherry picked from commit e642e17)
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Aug 28, 2025
ganesh-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Aug 29, 2025
srinath-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Sep 3, 2025
srinath-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Sep 12, 2025
KannarFr
pushed a commit
to CleverCloud/pulsar
that referenced
this pull request
Sep 22, 2025
…e#24643) Signed-off-by: Zixuan Liu <nodeces@gmail.com>
walkinggo
pushed a commit
to walkinggo/pulsar
that referenced
this pull request
Oct 8, 2025
…e#24643) Signed-off-by: Zixuan Liu <nodeces@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
In race conditions, multiple threads could attempt to create the same non-durable cursor simultaneously.
Adding a double-check ensures that if a cursor is already created by another thread while waiting in the synchronized block, the existing cursor is returned instead of creating a new one. This preserves thread safety and avoids duplicate cursor creation.
Modifications
Documentation
docdoc-requireddoc-not-neededdoc-complete