accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ctubb...@apache.org
Subject [3/4] accumulo git commit: ACCUMULO-3000: Use MAC config impl when using existing zookeepers
Date Wed, 20 May 2015 16:56:01 GMT
ACCUMULO-3000: Use MAC config impl when using existing zookeepers


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

Branch: refs/heads/master
Commit: 6c22aabfc604c6a93f215496577f9ed6ae7372bc
Parents: 0c069d1
Author: Trent Nadeau <tanadeau@gmail.com>
Authored: Tue May 12 17:36:38 2015 -0400
Committer: Trent Nadeau <tanadeau@gmail.com>
Committed: Fri May 15 15:19:02 2015 -0400

----------------------------------------------------------------------
 .../accumulo/minicluster/MiniAccumuloConfig.java       | 13 -------------
 .../accumulo/minicluster/MiniAccumuloRunner.java       |  2 +-
 .../minicluster/impl/MiniAccumuloConfigImpl.java       |  2 +-
 .../MiniAccumuloClusterExistingZooKeepersTest.java     |  6 +++---
 4 files changed, 5 insertions(+), 18 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/6c22aabf/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloConfig.java
----------------------------------------------------------------------
diff --git a/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloConfig.java
b/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloConfig.java
index 932507d..b71b771 100644
--- a/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloConfig.java
+++ b/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloConfig.java
@@ -108,19 +108,6 @@ public class MiniAccumuloConfig {
   }
 
   /**
-   * Configure an existing ZooKeeper instance to use. Calling this method is optional. If
not set, a new ZooKeeper instance is created.
-   *
-   * @param existingZooKeepers
-   *          Connection string for a already-running ZooKeeper instance
-   *
-   * @since 1.7.0
-   */
-  public MiniAccumuloConfig setExistingZooKeepers(String existingZooKeepers) {
-    impl.setExistingZooKeepers(existingZooKeepers);
-    return this;
-  }
-
-  /**
    * Sets the amount of memory to use in the master process. Calling this method is optional.
Default memory is 128M
    *
    * @param serverType

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6c22aabf/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloRunner.java
----------------------------------------------------------------------
diff --git a/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloRunner.java
b/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloRunner.java
index 1f1be44..78af6a0 100644
--- a/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloRunner.java
+++ b/minicluster/src/main/java/org/apache/accumulo/minicluster/MiniAccumuloRunner.java
@@ -170,7 +170,7 @@ public class MiniAccumuloRunner {
     if (opts.prop.containsKey(ZOO_KEEPER_STARTUP_TIME_PROP))
       config.setZooKeeperStartupTime(Long.parseLong(opts.prop.getProperty(ZOO_KEEPER_STARTUP_TIME_PROP)));
     if (opts.prop.containsKey(EXISTING_ZOO_KEEPERS_PROP))
-      config.setExistingZooKeepers(opts.prop.getProperty(EXISTING_ZOO_KEEPERS_PROP));
+      config.getImpl().setExistingZooKeepers(opts.prop.getProperty(EXISTING_ZOO_KEEPERS_PROP));
     if (opts.prop.containsKey(JDWP_ENABLED_PROP))
       config.setJDWPEnabled(Boolean.parseBoolean(opts.prop.getProperty(JDWP_ENABLED_PROP)));
     if (opts.prop.containsKey(ZOO_KEEPER_MEMORY_PROP))

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6c22aabf/minicluster/src/main/java/org/apache/accumulo/minicluster/impl/MiniAccumuloConfigImpl.java
----------------------------------------------------------------------
diff --git a/minicluster/src/main/java/org/apache/accumulo/minicluster/impl/MiniAccumuloConfigImpl.java
b/minicluster/src/main/java/org/apache/accumulo/minicluster/impl/MiniAccumuloConfigImpl.java
index 25f3c99..f2c4b80 100644
--- a/minicluster/src/main/java/org/apache/accumulo/minicluster/impl/MiniAccumuloConfigImpl.java
+++ b/minicluster/src/main/java/org/apache/accumulo/minicluster/impl/MiniAccumuloConfigImpl.java
@@ -324,7 +324,7 @@ public class MiniAccumuloConfigImpl {
    * Configure an existing ZooKeeper instance to use. Calling this method is optional. If
not set, a new ZooKeeper instance is created.
    *
    * @param existingZooKeepers
-   *          Connection string for a already-running ZooKeeper instance
+   *          Connection string for a already-running ZooKeeper instance. A null value will
turn off this feature.
    *
    * @since 1.8.0
    */

http://git-wip-us.apache.org/repos/asf/accumulo/blob/6c22aabf/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterExistingZooKeepersTest.java
----------------------------------------------------------------------
diff --git a/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterExistingZooKeepersTest.java
b/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterExistingZooKeepersTest.java
index d9fb63e..8c21874 100644
--- a/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterExistingZooKeepersTest.java
+++ b/minicluster/src/test/java/org/apache/accumulo/minicluster/MiniAccumuloClusterExistingZooKeepersTest.java
@@ -40,8 +40,8 @@ import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
 public class MiniAccumuloClusterExistingZooKeepersTest {
-  private static final File BASE_DIR = new File(
-          System.getProperty("user.dir") + "/target/mini-tests/" + MiniAccumuloClusterExistingZooKeepersTest.class.getName());
+  private static final File BASE_DIR = new File(System.getProperty("user.dir") + "/target/mini-tests/"
+      + MiniAccumuloClusterExistingZooKeepersTest.class.getName());
 
   private static final String SECRET = "superSecret";
 
@@ -62,7 +62,7 @@ public class MiniAccumuloClusterExistingZooKeepersTest {
     zooKeeper = new TestingServer();
 
     MiniAccumuloConfig config = new MiniAccumuloConfig(testDir, SECRET);
-    config.setExistingZooKeepers(zooKeeper.getConnectString());
+    config.getImpl().setExistingZooKeepers(zooKeeper.getConnectString());
     accumulo = new MiniAccumuloCluster(config);
     accumulo.start();
   }


Mime
View raw message