accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From els...@apache.org
Subject [3/3] accumulo git commit: ACCUMULO-3687 Use the canonical path for Accumulo home and confdir
Date Fri, 20 Mar 2015 00:39:43 GMT
ACCUMULO-3687 Use the canonical path for Accumulo home and confdir


Project: http://git-wip-us.apache.org/repos/asf/accumulo/repo
Commit: http://git-wip-us.apache.org/repos/asf/accumulo/commit/9df45b21
Tree: http://git-wip-us.apache.org/repos/asf/accumulo/tree/9df45b21
Diff: http://git-wip-us.apache.org/repos/asf/accumulo/diff/9df45b21

Branch: refs/heads/master
Commit: 9df45b2101669064176c2330c324b92b02b4da95
Parents: bdedcde
Author: Josh Elser <elserj@apache.org>
Authored: Thu Mar 19 19:00:45 2015 -0400
Committer: Josh Elser <elserj@apache.org>
Committed: Thu Mar 19 19:00:45 2015 -0400

----------------------------------------------------------------------
 .../cluster/standalone/StandaloneClusterControl.java         | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/9df45b21/minicluster/src/main/java/org/apache/accumulo/cluster/standalone/StandaloneClusterControl.java
----------------------------------------------------------------------
diff --git a/minicluster/src/main/java/org/apache/accumulo/cluster/standalone/StandaloneClusterControl.java
b/minicluster/src/main/java/org/apache/accumulo/cluster/standalone/StandaloneClusterControl.java
index ebc6143..97f99a3 100644
--- a/minicluster/src/main/java/org/apache/accumulo/cluster/standalone/StandaloneClusterControl.java
+++ b/minicluster/src/main/java/org/apache/accumulo/cluster/standalone/StandaloneClusterControl.java
@@ -63,8 +63,12 @@ public class StandaloneClusterControl implements ClusterControl {
   public StandaloneClusterControl(String user, String accumuloHome, String accumuloConfDir)
{
     this.user = user;
     this.options = new RemoteShellOptions();
-    this.accumuloHome = accumuloHome;
-    this.accumuloConfDir = accumuloConfDir;
+    try {
+      this.accumuloHome = new File(accumuloHome).getCanonicalPath();
+      this.accumuloConfDir = new File(accumuloConfDir).getCanonicalPath();
+    } catch (IOException e) {
+      throw new RuntimeException("Failed to compute canonical path", e);
+    }
 
     File bin = new File(accumuloHome, "bin");
     this.startServerPath = new File(bin, START_SERVER_SCRIPT).getAbsolutePath();


Mime
View raw message