@InterfaceAudience.Private public class ScanDeleteTracker extends Object implements DeleteTracker
This class is utilized through three methods:
add(org.apache.hadoop.hbase.Cell) when encountering a Delete or DeleteColumnisDeleted(org.apache.hadoop.hbase.Cell) when checking if a Put Cell has been deletedupdate() when reaching the end of a StoreFile or row for scansThis class is NOT thread-safe as queries are never multi-threaded
DeleteTracker.DeleteResult| 限定符和类型 | 字段和说明 |
|---|---|
protected CellComparator |
comparator |
protected byte[] |
deleteBuffer |
protected Cell |
deleteCell |
protected int |
deleteLength |
protected int |
deleteOffset |
protected long |
deleteTimestamp |
protected byte |
deleteType |
protected long |
familyStamp |
protected SortedSet<Long> |
familyVersionStamps |
protected boolean |
hasFamilyStamp |
| 构造器和说明 |
|---|
ScanDeleteTracker(CellComparator comparator) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
add(Cell cell)
Add the specified Cell to the list of deletes to check against for this row operation.
|
void |
beforeShipped()
The action that needs to be performed before
Shipper.shipped() is performed |
CellComparator |
getCellComparator()
Return the comparator passed to this delete tracker
|
DeleteTracker.DeleteResult |
isDeleted(Cell cell)
Check if the specified Cell buffer has been deleted by a previously seen delete.
|
boolean |
isEmpty() |
void |
reset()
Called between rows.
|
void |
update()
Called at the end of every StoreFile.
|
protected boolean hasFamilyStamp
protected long familyStamp
protected Cell deleteCell
protected byte[] deleteBuffer
protected int deleteOffset
protected int deleteLength
protected byte deleteType
protected long deleteTimestamp
protected final CellComparator comparator
public ScanDeleteTracker(CellComparator comparator)
public void add(Cell cell)
This is called when a Delete is encountered.
add 在接口中 DeleteTrackercell - - the delete cellpublic DeleteTracker.DeleteResult isDeleted(Cell cell)
isDeleted 在接口中 DeleteTrackercell - - current cell to check if deleted by a previously seen deletepublic boolean isEmpty()
isEmpty 在接口中 DeleteTrackerpublic void reset()
DeleteTrackerThis clears everything as if a new DeleteTracker was instantiated.
reset 在接口中 DeleteTrackerpublic void update()
DeleteTrackerMany optimized implementations of Trackers will require an update at when the end of each StoreFile is reached.
update 在接口中 DeleteTrackerpublic void beforeShipped()
throws IOException
ShipperListenerShipper.shipped() is performedbeforeShipped 在接口中 ShipperListenerIOExceptionpublic CellComparator getCellComparator()
DeleteTrackergetCellComparator 在接口中 DeleteTrackerCopyright © 2007–2019 The Apache Software Foundation. All rights reserved.