public class BookkeeperSchemaStorage extends Object implements org.apache.pulsar.common.protocol.schema.SchemaStorage
| Modifier and Type | Method and Description |
|---|---|
static Exception |
bkException(String operation,
int rc,
long ledgerId,
long entryId) |
void |
clearLocatorCache(String key) |
void |
close() |
CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> |
delete(String key) |
CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> |
delete(String key,
boolean forcefully) |
CompletableFuture<org.apache.pulsar.common.protocol.schema.StoredSchema> |
get(String key,
org.apache.pulsar.common.protocol.schema.SchemaVersion version) |
CompletableFuture<List<CompletableFuture<org.apache.pulsar.common.protocol.schema.StoredSchema>>> |
getAll(String key) |
List<Long> |
getSchemaLedgerList(String key) |
CompletableFuture<List<Long>> |
getStoreLedgerIdsBySchemaId(String schemaId) |
void |
init() |
CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> |
put(String key,
byte[] value,
byte[] hash) |
void |
start() |
org.apache.pulsar.common.protocol.schema.SchemaVersion |
versionFromBytes(byte[] version) |
public void init()
throws KeeperException,
InterruptedException
KeeperExceptionInterruptedExceptionpublic void start()
throws IOException
start in interface org.apache.pulsar.common.protocol.schema.SchemaStorageIOExceptionpublic CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> put(String key, byte[] value, byte[] hash)
put in interface org.apache.pulsar.common.protocol.schema.SchemaStoragepublic CompletableFuture<org.apache.pulsar.common.protocol.schema.StoredSchema> get(String key, org.apache.pulsar.common.protocol.schema.SchemaVersion version)
get in interface org.apache.pulsar.common.protocol.schema.SchemaStoragepublic CompletableFuture<List<CompletableFuture<org.apache.pulsar.common.protocol.schema.StoredSchema>>> getAll(String key)
getAll in interface org.apache.pulsar.common.protocol.schema.SchemaStoragepublic void clearLocatorCache(String key)
public List<Long> getSchemaLedgerList(String key) throws IOException
IOExceptionpublic CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> delete(String key, boolean forcefully)
delete in interface org.apache.pulsar.common.protocol.schema.SchemaStoragepublic CompletableFuture<org.apache.pulsar.common.protocol.schema.SchemaVersion> delete(String key)
delete in interface org.apache.pulsar.common.protocol.schema.SchemaStoragepublic org.apache.pulsar.common.protocol.schema.SchemaVersion versionFromBytes(byte[] version)
versionFromBytes in interface org.apache.pulsar.common.protocol.schema.SchemaStoragepublic void close()
throws Exception
close in interface org.apache.pulsar.common.protocol.schema.SchemaStorageExceptionpublic CompletableFuture<List<Long>> getStoreLedgerIdsBySchemaId(String schemaId)
Copyright © 2017–2021 Apache Software Foundation. All rights reserved.