@InterfaceAudience.Private public class EntryBuffers extends Object
Modifier and Type | Class and Description |
---|---|
static class |
EntryBuffers.RegionEntryBuffer
A buffer of some number of edits for a given region.
|
Modifier and Type | Field and Description |
---|---|
(package private) Map<byte[],EntryBuffers.RegionEntryBuffer> |
buffers |
private WALSplitter.PipelineController |
controller |
private Set<byte[]> |
currentlyWriting |
private static org.slf4j.Logger |
LOG |
protected long |
maxHeapUsage |
protected long |
totalBuffered |
Constructor and Description |
---|
EntryBuffers(WALSplitter.PipelineController controller,
long maxHeapUsage) |
Modifier and Type | Method and Description |
---|---|
void |
appendEntry(WAL.Entry entry)
Append a log entry into the corresponding region buffer.
|
(package private) void |
doneWriting(EntryBuffers.RegionEntryBuffer buffer) |
(package private) EntryBuffers.RegionEntryBuffer |
getChunkToWrite()
Returns RegionEntryBuffer a buffer of edits to be written.
|
(package private) boolean |
isRegionCurrentlyWriting(byte[] region) |
void |
waitUntilDrained() |
private static final org.slf4j.Logger LOG
private final WALSplitter.PipelineController controller
final Map<byte[],EntryBuffers.RegionEntryBuffer> buffers
private final Set<byte[]> currentlyWriting
protected long totalBuffered
protected final long maxHeapUsage
public EntryBuffers(WALSplitter.PipelineController controller, long maxHeapUsage)
public void appendEntry(WAL.Entry entry) throws InterruptedException, IOException
InterruptedException
IOException
EntryBuffers.RegionEntryBuffer getChunkToWrite()
void doneWriting(EntryBuffers.RegionEntryBuffer buffer)
boolean isRegionCurrentlyWriting(byte[] region)
public void waitUntilDrained()
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.