[improve][broker] Decouple ManagedLedger interfaces from the current implementation - #23311
Merged
lhotari merged 5 commits intoSep 17, 2024
Merged
Conversation
…implementation Co-authored-by: Yan Zhao <horizonzy@apache.org> Co-authored-by: Yong Zhang <zhangyong1025.zy@gmail.com>
lhotari
requested review from
BewareMyPower,
Demogorgon314,
Technoboy-,
codelipenghui,
dao-jun,
dlg99,
eolivelli,
hangc0276,
heesung-sohn,
horizonzy,
mattisonchao,
merlimat,
nodece and
zymap
September 16, 2024 13:48
lhotari
force-pushed
the
lh-managed-ledger-interface-improvements
branch
from
September 17, 2024 05:11
e376376 to
212ccf8
Compare
Co-authored-by: Yunze Xu <xyzinfernity@163.com>
Co-authored-by: Yunze Xu <xyzinfernity@163.com>
BewareMyPower
approved these changes
Sep 17, 2024
4 tasks
Closed
13 tasks
2 tasks
hanmz
pushed a commit
to hanmz/pulsar
that referenced
this pull request
Feb 12, 2025
…implementation (apache#23311) Co-authored-by: Yan Zhao <horizonzy@apache.org> Co-authored-by: Yong Zhang <zhangyong1025.zy@gmail.com> Co-authored-by: Yunze Xu <xyzinfernity@163.com>
11 tasks
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
This PR is part of an initiative to clean up and decouple the ManagedLedger interfaces from their current implementation in preparation for Pulsar 4.0. The primary goals are:
This work stems from a community discussion on the Apache Pulsar mailing list: Preparing for Pulsar 4.0: cleaning up the Managed Ledger interfaces
Since the ManagedLedger interface is not exposed externally and this PR doesn't introduce implementation changes, a formal PIP (Pulsar Improvement Proposal) is not required. The mailing list discussion and the review process for this PR are considered sufficient for proceeding with these changes.
Scope
This PR aims to make minimal, focused changes to achieve the decoupling goal. It does not include:
Modifications
Decouple from
ManagedLedgerImpl:ManagedLedgerImplto theManagedLedgerinterfaceDecouple from
ManagedLedgerFactoryImpl:ManagedLedgerFactoryImplto theManagedLedgerFactoryinterfaceDecouple from
ManagedCursorImpl:ManagedCursorinterface with required methods fromManagedCursorImplIntroduce
ReadOnlyManagedLedgerinterface:ReadOnlyManagedLedgerImplDecouple
OpAddEntryfromManagedLedgerInterceptor:AddEntryOperationto be used by thebeforeAddEntrymethodvoidAddEntryOperationinprocessPayloadBeforeLedgerWritesince mutation should happen with thePayloadProcessorHandlein that case.Decouple
LedgerHandlefromManagedLedgerInterceptor:LastEntryHandleto be used by theonManagedLedgerLastLedgerInitializemethodAdditional minor changes:
Documentation
docdoc-requireddoc-not-neededdoc-complete