saintstack commented on a change in pull request #1825: URL: https://github.com/apache/hbase/pull/1825#discussion_r434067948
########## File path: hbase-server/src/main/java/org/apache/hadoop/hbase/wal/WALSplitter.java ########## @@ -285,23 +286,35 @@ boolean splitLogFile(FileStatus logfile, CancelableProgressable reporter) throws String encodedRegionNameAsStr = Bytes.toString(region); lastFlushedSequenceId = lastFlushedSequenceIds.get(encodedRegionNameAsStr); if (lastFlushedSequenceId == null) { - if (sequenceIdChecker != null) { - RegionStoreSequenceIds ids = sequenceIdChecker.getLastSequenceId(region); - Map<byte[], Long> maxSeqIdInStores = new TreeMap<>(Bytes.BYTES_COMPARATOR); - for (StoreSequenceId storeSeqId : ids.getStoreSequenceIdList()) { - maxSeqIdInStores.put(storeSeqId.getFamilyName().toByteArray(), - storeSeqId.getSequenceId()); + if (!(isRegionDirPresentUnderRoot(entry.getKey().getTableName(), encodedRegionNameAsStr))) { Review comment: Is this the right test to do? Should we rather ask the Master if this is an active Region? Asking the FS could be racy? E.g. something like maser.getAM.getRegionStates().isRegionInRegionStates... It takes HRI which you might not have so you might need to add a version that takes encoded region name? ---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org