Class LogMetadata
java.lang.Object
org.apache.bookkeeper.bookie.storage.directentrylogger.LogMetadata
-
Field Summary
FieldsModifier and TypeFieldDescription(package private) static final long(package private) static final long(package private) static final int(package private) static final intLedgers map is composed of multiple parts that can be split into separated entries.(package private) static final int(package private) static final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) static EntryLogMetadata(package private) static voidwrite(LogWriter writer, EntryLogMetadata metadata, io.netty.buffer.ByteBufAllocator allocator)
-
Field Details
-
LEDGERS_MAP_HEADER_SIZE
static final int LEDGERS_MAP_HEADER_SIZELedgers map is composed of multiple parts that can be split into separated entries. Each of them is composed of:length: (4 bytes) [0-3] ledger id (-1): (8 bytes) [4 - 11] entry id: (8 bytes) [12-19] num ledgers stored in current metadata entry: (4 bytes) [20 - 23] ledger entries: sequence of (ledgerid, size) (8 + 8 bytes each) [24..]
- See Also:
-
LEDGERS_MAP_ENTRY_SIZE
static final int LEDGERS_MAP_ENTRY_SIZE- See Also:
-
LEDGERS_MAP_MAX_BATCH_SIZE
static final int LEDGERS_MAP_MAX_BATCH_SIZE- See Also:
-
LEDGERS_MAP_MAX_MAP_SIZE
static final int LEDGERS_MAP_MAX_MAP_SIZE- See Also:
-
INVALID_LID
static final long INVALID_LID- See Also:
-
LEDGERS_MAP_ENTRY_ID
static final long LEDGERS_MAP_ENTRY_ID- See Also:
-
-
Constructor Details
-
LogMetadata
LogMetadata()
-
-
Method Details
-
write
static void write(LogWriter writer, EntryLogMetadata metadata, io.netty.buffer.ByteBufAllocator allocator) throws IOException - Throws:
IOException
-
read
- Throws:
IOException
-