[
https://issues.apache.org/jira/browse/HBASE-23838?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17037370#comment-17037370
]
Michael Stack commented on HBASE-23838:
---------------------------------------
Pushed an addendum on branch-2 and master to fix failing TestExportSnapshot:
{code}
diff --git
a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java
b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java
index 4293d461d9..99d9d65d30 100644
---
a/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java
+++
b/hbase-mapreduce/src/test/java/org/apache/hadoop/hbase/snapshot/TestExportSnapshot.java
@@ -213,8 +213,7 @@ public class TestExportSnapshot {
final RegionPredicate bypassregionPredicate, boolean success) throws
Exception {
URI hdfsUri = FileSystem.get(conf).getUri();
FileSystem fs = FileSystem.get(copyDir.toUri(), conf);
- copyDir = copyDir.makeQualified(hdfsUri, copyDir);
-
+ copyDir = copyDir.makeQualified(fs.getUri(), fs.getWorkingDirectory());
List<String> opts = new ArrayList<>();
opts.add("--snapshot");
opts.add(Bytes.toString(snapshotName));
@@ -227,10 +226,8 @@ public class TestExportSnapshot {
if (overwrite) opts.add("--overwrite");
// Export Snapshot
- ExportSnapshot es = new ExportSnapshot();
- es.setConf(conf);
- int res = run(conf, es, opts.toArray(new String[opts.size()]));
- assertEquals(success ? 0 : 1, res);
+ int res = run(conf, new ExportSnapshot(), opts.toArray(new
String[opts.size()]));
+ assertEquals("success " + success + ", res=" + res, success ? 0 : 1, res);
if (!success) {
final Path targetDir = new Path(HConstants.SNAPSHOT_DIR_NAME,
Bytes.toString(targetName));
assertFalse(copyDir.toString() + " " + targetDir.toString(),
{code}
> Adding debug logging to a few ExportSnapshot tests
> --------------------------------------------------
>
> Key: HBASE-23838
> URL: https://issues.apache.org/jira/browse/HBASE-23838
> Project: HBase
> Issue Type: Bug
> Reporter: Michael Stack
> Assignee: Michael Stack
> Priority: Trivial
> Fix For: 3.0.0, 2.3.0
>
> Attachments:
> 0001-HBASE-23838-Adding-debug-logging-to-a-few-ExportSnap.patch
>
>
> Bit of extra logging in tests to help me diagnose where they are going wrong.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)