| Package | Description |
|---|---|
| org.apache.bookkeeper.client |
BookKeeper Client.
|
| Modifier and Type | Class and Description |
|---|---|
static class |
BKException.BKAddEntryQuorumTimeoutException
Bookkeeper add entry quorum timeout exception.
|
static class |
BKException.BKBookieException
Bookkeeper bookie exception.
|
static class |
BKException.BKBookieHandleNotAvailableException
Bookkeeper bookie handle not available exception.
|
static class |
BKException.BKClientClosedException
Bookkeeper client closed exception.
|
static class |
BKException.BKDigestMatchException
Bookkeeper digest match exception.
|
static class |
BKException.BKDigestNotInitializedException
Bookkeeper digest not initialized exception.
|
static class |
BKException.BKDuplicateEntryIdException
Bookkeeper duplicate entry id exception.
|
static class |
BKException.BKIllegalOpException
Bookkeeper illegal operation exception.
|
static class |
BKException.BKIncorrectParameterException
Bookkeeper incorrect parameter exception.
|
static class |
BKException.BKInterruptedException
Bookkeeper interrupted exception.
|
static class |
BKException.BKLedgerClosedException
Bookkeeper ledger closed exception.
|
static class |
BKException.BKLedgerExistException
Bookkeeper ledger exist exception.
|
static class |
BKException.BKLedgerFencedException
Bookkeeper ledger fenced exception.
|
static class |
BKException.BKLedgerIdOverflowException
Bookkeeper ledger id overflow exception.
|
static class |
BKException.BKLedgerRecoveryException
Bookkeeper ledger recovery exception.
|
static class |
BKException.BKMetadataSerializationException
Bookkeeper metadata serialization exception.
|
static class |
BKException.BKMetadataVersionException
Bookkeeper metadata version exception.
|
static class |
BKException.BKNoSuchEntryException
Bookkeeper no such entry exception.
|
static class |
BKException.BKNoSuchLedgerExistsException
Bookkeeper no such ledger exists exception.
|
static class |
BKException.BKNoSuchLedgerExistsOnMetadataServerException
Bookkeeper no such ledger exists on metadata server exception.
|
static class |
BKException.BKNotEnoughBookiesException
Bookkeeper not enough bookies exception.
|
static class |
BKException.BKProtocolVersionException
Bookkeeper protocol version exception.
|
static class |
BKException.BKQuorumException
Bookkeeper quorum exception.
|
static class |
BKException.BKReadException
Bookkeeper read exception.
|
static class |
BKException.BKReplicationException
Bookkeeper replication exception.
|
static class |
BKException.BKSecurityException
Bookkeeper security exception.
|
static class |
BKException.BKTimeoutException
Bookkeeper timeout exception.
|
static class |
BKException.BKTooManyRequestsException
Bookkeeper too many requests exception.
|
static class |
BKException.BKUnauthorizedAccessException
Bookkeeper unauthorized access exception.
|
static class |
BKException.BKUnclosedFragmentException
Bookkeeper unclosed fragment exception.
|
static class |
BKException.BKUnexpectedConditionException
Bookkeeper unexpected condition exception.
|
static class |
BKException.BKWriteException
Bookkeeper write exception.
|
static class |
BKException.BKWriteOnReadOnlyBookieException
Bookkeeper write on readonly bookie exception.
|
static class |
BKException.MetaStoreException
Metastore exception.
|
static class |
BKException.ZKException
Zookeeper exception.
|
| Modifier and Type | Field and Description |
|---|---|
static java.util.function.Function<java.lang.Throwable,BKException> |
BKException.HANDLER |
| Modifier and Type | Method and Description |
|---|---|
static BKException |
BKException.create(int code)
Create an exception from an error code.
|
| Modifier and Type | Method and Description |
|---|---|
long |
ReadOnlyLedgerHandle.addEntry(byte[] data) |
long |
LedgerHandle.addEntry(byte[] data)
Add entry synchronously to an open ledger.
|
long |
ReadOnlyLedgerHandle.addEntry(byte[] data,
int offset,
int length) |
long |
LedgerHandle.addEntry(byte[] data,
int offset,
int length)
Add entry synchronously to an open ledger.
|
long |
LedgerHandleAdv.addEntry(long entryId,
byte[] data)
Add entry synchronously to an open ledger.
|
long |
LedgerHandle.addEntry(long entryId,
byte[] data)
Add entry synchronously to an open ledger.
|
long |
LedgerHandleAdv.addEntry(long entryId,
byte[] data,
int offset,
int length)
Add entry synchronously to an open ledger.
|
long |
LedgerHandle.addEntry(long entryId,
byte[] data,
int offset,
int length)
Add entry synchronously to an open ledger.
|
BookKeeper |
BookKeeper.Builder.build() |
void |
BookKeeper.close()
Shuts down client.
|
void |
BookKeeperAdmin.close()
Gracefully release resources that this client uses.
|
void |
ReadOnlyLedgerHandle.close() |
void |
LedgerHandle.close()
Synchronous close the write handle, any adds in flight will return errors.
|
LedgerHandle |
BookKeeper.createLedger(BookKeeper.DigestType digestType,
byte[] passwd)
Creates a new ledger.
|
LedgerHandle |
BookKeeper.createLedger(int ensSize,
int qSize,
BookKeeper.DigestType digestType,
byte[] passwd)
Synchronous call to create ledger.
|
LedgerHandle |
BookKeeper.createLedger(int ensSize,
int writeQuorumSize,
int ackQuorumSize,
BookKeeper.DigestType digestType,
byte[] passwd)
Synchronous call to create ledger.
|
LedgerHandle |
BookKeeper.createLedger(int ensSize,
int writeQuorumSize,
int ackQuorumSize,
BookKeeper.DigestType digestType,
byte[] passwd,
java.util.Map<java.lang.String,byte[]> customMetadata)
Synchronous call to create ledger.
|
LedgerHandle |
BookKeeper.createLedgerAdv(int ensSize,
int writeQuorumSize,
int ackQuorumSize,
BookKeeper.DigestType digestType,
byte[] passwd)
Synchronous call to create ledger.
|
LedgerHandle |
BookKeeper.createLedgerAdv(int ensSize,
int writeQuorumSize,
int ackQuorumSize,
BookKeeper.DigestType digestType,
byte[] passwd,
java.util.Map<java.lang.String,byte[]> customMetadata)
Synchronous call to create ledger.
|
LedgerHandle |
BookKeeper.createLedgerAdv(long ledgerId,
int ensSize,
int writeQuorumSize,
int ackQuorumSize,
BookKeeper.DigestType digestType,
byte[] passwd,
java.util.Map<java.lang.String,byte[]> customMetadata)
Synchronously creates a new ledger using the interface which accepts a ledgerId as input.
|
void |
BookKeeperAdmin.decommissionBookie(org.apache.bookkeeper.net.BookieId bookieAddress)
Triggers AuditTask by resetting lostBookieRecoveryDelay and then make
sure the ledgers stored in the given decommissioning bookie are properly
replicated and they are not underreplicated because of the given bookie.
|
void |
BookKeeper.deleteLedger(long lId)
Synchronous call to delete a ledger.
|
java.util.Collection<org.apache.bookkeeper.net.BookieId> |
BookKeeperAdmin.getAllBookies()
Get a list of all bookies including the not available ones.
|
java.util.Set<org.apache.bookkeeper.net.BookieId> |
BookieWatcher.getAllBookies() |
java.util.Set<org.apache.bookkeeper.net.BookieId> |
BookieWatcherImpl.getAllBookies() |
java.util.Collection<org.apache.bookkeeper.net.BookieId> |
BookKeeperAdmin.getAvailableBookies()
Get a list of the available bookies.
|
java.util.Map<org.apache.bookkeeper.net.BookieId,BookieInfoReader.BookieInfo> |
BookKeeper.getBookieInfo()
Retrieves BookieInfo from all the bookies in the cluster.
|
(package private) java.util.Map<org.apache.bookkeeper.net.BookieId,BookieInfoReader.BookieInfo> |
BookieInfoReader.getBookieInfo() |
java.util.Set<org.apache.bookkeeper.net.BookieId> |
BookieWatcher.getBookies() |
java.util.Set<org.apache.bookkeeper.net.BookieId> |
BookieWatcherImpl.getBookies() |
org.apache.bookkeeper.discover.BookieServiceInfo |
BookKeeperAdmin.getBookieServiceInfo(java.lang.String bookiedId) |
java.util.SortedMap<java.lang.Long,LedgerMetadata> |
BookKeeperAdmin.getLedgersContainBookies(java.util.Set<org.apache.bookkeeper.net.BookieId> bookies) |
java.util.Collection<org.apache.bookkeeper.net.BookieId> |
BookKeeperAdmin.getReadOnlyBookies()
Get a list of readonly bookies synchronously.
|
java.util.Set<org.apache.bookkeeper.net.BookieId> |
BookieWatcher.getReadOnlyBookies() |
java.util.Set<org.apache.bookkeeper.net.BookieId> |
BookieWatcherImpl.getReadOnlyBookies() |
void |
BookieWatcherImpl.initialBlockingBookieRead()
Blocks until bookies are read from zookeeper, used in the
BookKeeper constructor. |
boolean |
BookKeeper.isClosed(long lId)
Check whether the ledger with identifier lId
has been closed.
|
LedgerHandle |
BookKeeperAdmin.openLedger(long lId)
Open a ledger as an administrator.
|
LedgerHandle |
BookKeeper.openLedger(long lId,
BookKeeper.DigestType digestType,
byte[] passwd)
Synchronous open ledger call.
|
LedgerHandle |
BookKeeperAdmin.openLedgerNoRecovery(long lId)
Open a ledger as an administrator without recovering the ledger.
|
LedgerHandle |
BookKeeper.openLedgerNoRecovery(long lId,
BookKeeper.DigestType digestType,
byte[] passwd)
Synchronous, unsafe open ledger call.
|
java.util.Enumeration<LedgerEntry> |
LedgerHandle.readEntries(long firstEntry,
long lastEntry)
Read a sequence of entries synchronously.
|
java.lang.Iterable<LedgerEntry> |
BookKeeperAdmin.readEntries(long ledgerId,
long firstEntry,
long lastEntry)
Read entries from a ledger synchronously.
|
long |
LedgerHandle.readExplicitLastConfirmed() |
long |
LedgerHandle.readLastConfirmed()
Obtains synchronously the last confirmed write from a quorum of bookies.
|
LedgerEntry |
LedgerHandle.readLastEntry() |
java.util.Enumeration<LedgerEntry> |
LedgerHandle.readUnconfirmedEntries(long firstEntry,
long lastEntry)
Read a sequence of entries synchronously, allowing to read after the LastAddConfirmed range.
This is the same of #asyncReadUnconfirmedEntries(long, long, ReadCallback, Object) |
void |
BookKeeperAdmin.recoverBookieData(org.apache.bookkeeper.net.BookieId bookieSrc)
Synchronous method to rebuild and recover the ledger fragments data that
was stored on the source bookie.
|
void |
BookKeeperAdmin.recoverBookieData(long lid,
java.util.Set<org.apache.bookkeeper.net.BookieId> bookiesSrc,
boolean dryrun,
boolean skipOpenLedgers) |
void |
BookKeeperAdmin.recoverBookieData(java.util.Set<org.apache.bookkeeper.net.BookieId> bookiesSrc) |
void |
BookKeeperAdmin.recoverBookieData(java.util.Set<org.apache.bookkeeper.net.BookieId> bookiesSrc,
boolean dryrun,
boolean skipOpenLedgers) |
void |
BookKeeperAdmin.recoverBookieData(java.util.Set<org.apache.bookkeeper.net.BookieId> bookiesSrc,
boolean dryrun,
boolean skipOpenLedgers,
boolean skipUnrecoverableLedgers) |
void |
BookKeeperAdmin.replicateLedgerFragment(LedgerHandle lh,
LedgerFragment ledgerFragment,
java.util.function.BiConsumer<java.lang.Long,java.lang.Long> onReadEntryFailureCallback)
Replicate the Ledger fragment to target Bookie passed.
|
long |
LedgerHandle.tryReadLastConfirmed()
Obtains synchronously the last confirmed write from a quorum of bookies.
|
static <T> T |
SyncCallbackUtils.waitForResult(java.util.concurrent.CompletableFuture<T> future)
Wait for a result.
|
void |
BookKeeperAdmin.watchReadOnlyBookiesChanged(org.apache.bookkeeper.discover.RegistrationClient.RegistrationListener listener)
Notify when the available list of read only bookies changes.
|
void |
BookKeeperAdmin.watchWritableBookiesChanged(org.apache.bookkeeper.discover.RegistrationClient.RegistrationListener listener)
Notify when the available list of bookies changes.
|
| Constructor and Description |
|---|
BookKeeper(ClientConfiguration conf)
Create a bookkeeper client using a configuration object.
|
BookKeeper(ClientConfiguration conf,
org.apache.zookeeper.ZooKeeper zk)
Create a bookkeeper client but use the passed in zookeeper client instead
of instantiating one.
|
BookKeeper(ClientConfiguration conf,
org.apache.zookeeper.ZooKeeper zk,
io.netty.channel.EventLoopGroup eventLoopGroup)
Create a bookkeeper client but use the passed in zookeeper client and
client event loop group instead of instantiating those.
|
BookKeeper(ClientConfiguration conf,
org.apache.zookeeper.ZooKeeper zkc,
io.netty.channel.EventLoopGroup eventLoopGroup,
io.netty.buffer.ByteBufAllocator byteBufAllocator,
org.apache.bookkeeper.stats.StatsLogger rootStatsLogger,
org.apache.bookkeeper.net.DNSToSwitchMapping dnsResolver,
io.netty.util.HashedWheelTimer requestTimer,
FeatureProvider featureProvider)
Constructor for use with the builder.
|
BookKeeper(java.lang.String servers)
Create a bookkeeper client.
|
BookKeeperAdmin(ClientConfiguration conf)
Constructor that takes in a configuration object so we know
how to connect to ZooKeeper to retrieve information about the BookKeeper
cluster.
|
BookKeeperAdmin(java.lang.String zkServers)
Constructor that takes in a ZooKeeper servers connect string so we know
how to connect to ZooKeeper to retrieve information about the BookKeeper
cluster.
|
LedgerEntriesIterator(long ledgerId,
long firstEntry,
long lastEntry) |
Copyright © 2011–2024 The Apache Software Foundation. All rights reserved.