[improve][ml]Release idle offloaded read handle only the ref count is 0 - #24381
Merged
lhotari merged 1 commit intoJun 5, 2025
Merged
Conversation
lhotari
approved these changes
Jun 5, 2025
lhotari
left a comment
Member
There was a problem hiding this comment.
LGTM, great work @poorbarcode
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #24381 +/- ##
============================================
+ Coverage 73.57% 74.26% +0.68%
+ Complexity 32624 32241 -383
============================================
Files 1877 1867 -10
Lines 139502 145267 +5765
Branches 15299 16610 +1311
============================================
+ Hits 102638 107881 +5243
+ Misses 28908 28852 -56
- Partials 7956 8534 +578
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
4 tasks
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 12, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit 639521b)
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 12, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit dcbe23f)
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 12, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit 639521b)
4 tasks
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 12, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit 639521b)
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 13, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit 639521b)
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 13, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit 639521b)
manas-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 13, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit dcbe23f)
srinath-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 16, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit 639521b)
srinath-ctds
pushed a commit
to datastax/pulsar
that referenced
this pull request
Jun 16, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5) (cherry picked from commit dcbe23f)
nodece
pushed a commit
to nodece/pulsar
that referenced
this pull request
Jun 18, 2025
… 0 (apache#24381) (cherry picked from commit 21406b5)
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
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
#19783 introduced a feature: release idle offloaded ledger handle to release the direct memory occupied. But it left a potential issue, which has been discussed here, and it can happen this way
ledgerHandle.readAsynctouch(), updatelastAccessTimestampexecutor.queueexecutoris very busy, leading to delayed executions ofledgerHandle.readAsyncledgerHandle.readAsyncexecute eventually, but the ledger handle has been closedSince users can modify the threshold of marking the ledger handle as
idleby the configurationmanagedLedgerInactiveOffloadedLedgerEvictionTimeSeconds, it may increase the probability of the issue happeningModifications
pendingReadto record how many pending reading requests are in progress, Pulsar release ledger handle whenpendingReadis0,and has idled for enough timeDocumentation
docdoc-requireddoc-not-neededdoc-completeMatching PR in forked repository
PR in forked repository: x