Skip to content

Commit

Permalink
HBASE-15302 Reenable the other tests disabled by HBASE-14678
Browse files Browse the repository at this point in the history
Signed-off-by: stack <stack@apache.org>
  • Loading branch information
yangzhe1991 authored and saintstack committed Feb 24, 2016
1 parent 876a6ab commit 30cec72
Show file tree
Hide file tree
Showing 11 changed files with 5,256 additions and 5 deletions.
Expand Up @@ -515,13 +515,14 @@ private static void archiveLogs(
* @param fs
* @param logEntry
* @param rootDir HBase root dir.
* @param fileBeingSplit the file being split currently. Used to generate tmp file name.
* @param fileNameBeingSplit the file being split currently. Used to generate tmp file name.
* @return Path to file into which to dump split log edits.
* @throws IOException
*/
@SuppressWarnings("deprecation")
private static Path getRegionSplitEditsPath(final FileSystem fs,
final Entry logEntry, final Path rootDir, FileStatus fileBeingSplit)
@VisibleForTesting
static Path getRegionSplitEditsPath(final FileSystem fs,
final Entry logEntry, final Path rootDir, String fileNameBeingSplit)
throws IOException {
Path tableDir = FSUtils.getTableDir(rootDir, logEntry.getKey().getTablename());
String encodedRegionName = Bytes.toString(logEntry.getKey().getEncodedRegionName());
Expand Down Expand Up @@ -556,7 +557,7 @@ private static Path getRegionSplitEditsPath(final FileSystem fs,
// Append file name ends with RECOVERED_LOG_TMPFILE_SUFFIX to ensure
// region's replayRecoveredEdits will not delete it
String fileName = formatRecoveredEditsFileName(logEntry.getKey().getSequenceId());
fileName = getTmpRecoveredEditsFileName(fileName + "-" + fileBeingSplit.getPath().getName());
fileName = getTmpRecoveredEditsFileName(fileName + "-" + fileNameBeingSplit);
return new Path(dir, fileName);
}

Expand Down Expand Up @@ -1518,7 +1519,7 @@ private WriterAndPath getWriterAndPath(Entry entry) throws IOException {
* @return a path with a write for that path. caller should close.
*/
private WriterAndPath createWAP(byte[] region, Entry entry, Path rootdir) throws IOException {
Path regionedits = getRegionSplitEditsPath(fs, entry, rootdir, fileBeingSplit);
Path regionedits = getRegionSplitEditsPath(fs, entry, rootdir, fileBeingSplit.getPath().getName());
if (regionedits == null) {
return null;
}
Expand Down

0 comments on commit 30cec72

Please sign in to comment.