[improve][broker][PIP-384] Decouple Bookkeeper client from ManagedLedgerStorage and enable multiple ManagedLedgerFactory instances #23313
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.
This PR is partial implementation for "PIP-384: ManagedLedger interface decoupling", #23363.
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
This PR adds supports for multiple ManagedLedger implementations when using a custom ManagedLedgerStorage implementation. The benefit of this is that a Bookkeeper implementation can co-exist with a custom ManagedLedger implementation in the same Pulsar cluster.
Scope
This PR aims to make minimal, focused changes to achieve the decoupling goal. It does not include:
Modifications
managedLedgerStorageClassName
toPersistencePolicies
to control theManagedLedgerFactory
instance that is used for a particular namespace or topic.storageClassName
toManagedLedgerConfig
, this field is read fromPersistencePolicies
(namespace or topic policies)ManagedLedgerStorage
interface to support getting aManagedLedgerFactory
with thestorageClassName
ManagedLedgerFactory
instanceDocumentation
doc
doc-required
doc-not-needed
doc-complete