Details
-
Sub-task
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
Description
After incorporating v11 of the 2856 fix, we discovered that we are still having some ACID violations.
This time, however, the problem is not about including "newer" updates; but, about missing older updates
that should be including.
Here is what seems to be happening.
There is a race condition in the StoreScanner.getScanners()
private List<KeyValueScanner> getScanners(Scan scan,
final NavigableSet<byte[]> columns) throws IOException {
// First the store file scanners
List<StoreFileScanner> sfScanners = StoreFileScanner
.getScannersForStoreFiles(store.getStorefiles(), cacheBlocks,
isGet, false);
List<KeyValueScanner> scanners =
new ArrayList<KeyValueScanner>(sfScanners.size()+1);
// include only those scan files which pass all filters
for (StoreFileScanner sfs : sfScanners) {
if (sfs.shouldSeek(scan, columns))
}
// Then the memstore scanners
if (this.store.memstore.shouldSeek(scan))
return scanners;
}
If for example there is a call to Store.updateStorefiles() that happens between
the store.getStorefiles() and this.store.memstore.getScanners(); then
it is possible that there was a new HFile created, that is not seen by the
StoreScanner, and the data is not present in the Memstore.snapshot either.
Attachments
Attachments
Issue Links
- is related to
-
HBASE-4570 Scan ACID problem with concurrent puts.
- Closed