@InterfaceAudience.Private class WALEntryBatch extends Object
Modifier and Type | Field and Description |
---|---|
private boolean |
endOfFile |
private long |
heapSize |
private Map<String,Long> |
lastSeqIds |
private org.apache.hadoop.fs.Path |
lastWalPath |
private long |
lastWalPosition |
private int |
nbHFiles |
private int |
nbRowKeys |
static WALEntryBatch |
NO_MORE_DATA |
private List<Pair<WAL.Entry,Long>> |
walEntriesWithSize |
Constructor and Description |
---|
WALEntryBatch(int maxNbEntries,
org.apache.hadoop.fs.Path lastWalPath) |
Modifier and Type | Method and Description |
---|---|
void |
addEntry(WAL.Entry entry,
long entrySize) |
(package private) static WALEntryBatch |
endOfFile(org.apache.hadoop.fs.Path lastWalPath) |
long |
getHeapSize()
Returns the heap size of this batch
|
Map<String,Long> |
getLastSeqIds()
Returns the last sequenceid for each region if the table has serial-replication scope
|
org.apache.hadoop.fs.Path |
getLastWalPath()
Returns the path of the last WAL that was read.
|
long |
getLastWalPosition()
Returns the position in the last WAL that was read.
|
int |
getNbEntries() |
int |
getNbHFiles()
Returns the number of HFiles in this batch
|
int |
getNbOperations()
Returns total number of operations in this batch
|
int |
getNbRowKeys()
Returns the number of distinct row keys in this batch
|
List<WAL.Entry> |
getWalEntries()
Returns the WAL Entries.
|
List<Pair<WAL.Entry,Long>> |
getWalEntriesWithSize()
Returns the WAL Entries.
|
void |
incrementHeapSize(long increment) |
void |
incrementNbHFiles(int increment) |
void |
incrementNbRowKeys(int increment) |
boolean |
isEndOfFile() |
void |
setEndOfFile(boolean endOfFile) |
void |
setLastSeqId(String region,
long sequenceId) |
void |
setLastWalPath(org.apache.hadoop.fs.Path lastWalPath) |
void |
setLastWalPosition(long lastWalPosition) |
String |
toString() |
public static final WALEntryBatch NO_MORE_DATA
private List<Pair<WAL.Entry,Long>> walEntriesWithSize
private org.apache.hadoop.fs.Path lastWalPath
private long lastWalPosition
private int nbRowKeys
private int nbHFiles
private long heapSize
private Map<String,Long> lastSeqIds
private boolean endOfFile
WALEntryBatch(int maxNbEntries, org.apache.hadoop.fs.Path lastWalPath)
lastWalPath
- Path of the WAL the last entry in this batch was read fromstatic WALEntryBatch endOfFile(org.apache.hadoop.fs.Path lastWalPath)
public List<WAL.Entry> getWalEntries()
public List<Pair<WAL.Entry,Long>> getWalEntriesWithSize()
public org.apache.hadoop.fs.Path getLastWalPath()
public void setLastWalPath(org.apache.hadoop.fs.Path lastWalPath)
public long getLastWalPosition()
public void setLastWalPosition(long lastWalPosition)
public int getNbEntries()
public int getNbRowKeys()
public int getNbHFiles()
public int getNbOperations()
public long getHeapSize()
public Map<String,Long> getLastSeqIds()
public boolean isEndOfFile()
public void setEndOfFile(boolean endOfFile)
public void incrementNbRowKeys(int increment)
public void incrementNbHFiles(int increment)
public void incrementHeapSize(long increment)
public void setLastSeqId(String region, long sequenceId)
Copyright © 2007–2020 The Apache Software Foundation. All rights reserved.