Skip to content

Commit

Permalink
HBASE-23589: FlushDescriptor contains non-matching family/output comb…
Browse files Browse the repository at this point in the history
…inations (#949)

Signed-off-by: Duo Zhang <[email protected]>
Signed-off-by: Lijin Bin <[email protected]>
  • Loading branch information
BukrosSzabolcs authored and binlijin committed Dec 24, 2019
1 parent 0936bc2 commit 0c09c43
Showing 1 changed file with 6 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2796,22 +2796,21 @@ protected FlushResultImpl internalFlushCacheAndCommit(WAL wal, MonitoredTask sta

// Switch snapshot (in memstore) -> new hfile (thus causing
// all the store scanners to reset/reseek).
Iterator<HStore> it = storesToFlush.iterator();
// stores.values() and storeFlushCtxs have same order
for (StoreFlushContext flush : storeFlushCtxs.values()) {
boolean needsCompaction = flush.commit(status);
for (Map.Entry<byte[], StoreFlushContext> flushEntry : storeFlushCtxs.entrySet()) {
StoreFlushContext sfc = flushEntry.getValue();
boolean needsCompaction = sfc.commit(status);
if (needsCompaction) {
compactionRequested = true;
}
byte[] storeName = it.next().getColumnFamilyDescriptor().getName();
List<Path> storeCommittedFiles = flush.getCommittedFiles();
byte[] storeName = flushEntry.getKey();
List<Path> storeCommittedFiles = sfc.getCommittedFiles();
committedFiles.put(storeName, storeCommittedFiles);
// Flush committed no files, indicating flush is empty or flush was canceled
if (storeCommittedFiles == null || storeCommittedFiles.isEmpty()) {
MemStoreSize storeFlushableSize = prepareResult.storeFlushableSize.get(storeName);
prepareResult.totalFlushableSize.decMemStoreSize(storeFlushableSize);
}
flushedOutputFileSize += flush.getOutputFileSize();
flushedOutputFileSize += sfc.getOutputFileSize();
}
storeFlushCtxs.clear();

Expand Down

0 comments on commit 0c09c43

Please sign in to comment.