accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From els...@apache.org
Subject [08/10] git commit: Merge branch '1.5.1-SNAPSHOT' into 1.6.0-SNAPSHOT
Date Wed, 22 Jan 2014 22:10:16 GMT
Merge branch '1.5.1-SNAPSHOT' into 1.6.0-SNAPSHOT

Conflicts:
	core/src/main/java/org/apache/accumulo/core/client/mapreduce/RangeInputSplit.java
	core/src/main/java/org/apache/accumulo/core/client/mapreduce/lib/util/ConfiguratorBase.java


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

Branch: refs/heads/1.6.0-SNAPSHOT
Commit: 2e65817691e462394cfaf97a58fc0ad9471aaccf
Parents: b642d1b 7bef404
Author: Josh Elser <elserj@apache.org>
Authored: Wed Jan 22 17:09:36 2014 -0500
Committer: Josh Elser <elserj@apache.org>
Committed: Wed Jan 22 17:09:36 2014 -0500

----------------------------------------------------------------------
 .../core/client/mapreduce/RangeInputSplit.java  | 11 ++++++++-
 .../mapreduce/lib/util/ConfiguratorBase.java    | 13 +++++++++--
 .../test/continuous/ContinuousVerify.java       | 22 ++++++++++++++++++
 test/system/continuous/run-verify.sh            | 24 +++++++++++++++++++-
 4 files changed, 66 insertions(+), 4 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/2e658176/core/src/main/java/org/apache/accumulo/core/client/mapreduce/RangeInputSplit.java
----------------------------------------------------------------------
diff --cc core/src/main/java/org/apache/accumulo/core/client/mapreduce/RangeInputSplit.java
index b238903,592cde6..85a0104
--- a/core/src/main/java/org/apache/accumulo/core/client/mapreduce/RangeInputSplit.java
+++ b/core/src/main/java/org/apache/accumulo/core/client/mapreduce/RangeInputSplit.java
@@@ -36,7 -33,8 +36,9 @@@ import org.apache.accumulo.core.client.
  import org.apache.accumulo.core.client.mapreduce.lib.util.InputConfigurator;
  import org.apache.accumulo.core.client.mock.MockInstance;
  import org.apache.accumulo.core.client.security.tokens.AuthenticationToken;
 +import org.apache.accumulo.core.client.security.tokens.AuthenticationToken.AuthenticationTokenSerializer;
+ import org.apache.accumulo.core.conf.AccumuloConfiguration;
+ import org.apache.accumulo.core.conf.SiteConfiguration;
  import org.apache.accumulo.core.data.ByteSequence;
  import org.apache.accumulo.core.data.Key;
  import org.apache.accumulo.core.data.PartialKey;
@@@ -367,8 -324,15 +369,15 @@@ public class RangeInputSplit extends In
      if (null == zooKeepers) {
        return null;
      }
+     
 -    ZooKeeperInstance zki = new ZooKeeperInstance(getInstanceName(), getZooKeepers());
++    ZooKeeperInstance zki = new ZooKeeperInstance(ClientConfiguration.loadDefault().withInstance(getInstanceName()).withZkHosts(getZooKeepers()));
  
-     return new ZooKeeperInstance(ClientConfiguration.loadDefault().withInstance(getInstanceName()).withZkHosts(getZooKeepers()));
+     // Wrap the DefaultConfiguration with a SiteConfiguration so we use accumulo-site.xml
+     // when it's present
+     AccumuloConfiguration xmlConfig = SiteConfiguration.getInstance(zki.getConfiguration());
+     zki.setConfiguration(xmlConfig);
+ 
+     return zki;
    }
  
    public String getInstanceName() {

http://git-wip-us.apache.org/repos/asf/accumulo/blob/2e658176/core/src/main/java/org/apache/accumulo/core/client/mapreduce/lib/util/ConfiguratorBase.java
----------------------------------------------------------------------
diff --cc core/src/main/java/org/apache/accumulo/core/client/mapreduce/lib/util/ConfiguratorBase.java
index cf861ce,a38aecf..b846356
--- a/core/src/main/java/org/apache/accumulo/core/client/mapreduce/lib/util/ConfiguratorBase.java
+++ b/core/src/main/java/org/apache/accumulo/core/client/mapreduce/lib/util/ConfiguratorBase.java
@@@ -27,8 -23,9 +27,10 @@@ import org.apache.accumulo.core.client.
  import org.apache.accumulo.core.client.ZooKeeperInstance;
  import org.apache.accumulo.core.client.mock.MockInstance;
  import org.apache.accumulo.core.client.security.tokens.AuthenticationToken;
 +import org.apache.accumulo.core.client.security.tokens.AuthenticationToken.AuthenticationTokenSerializer;
 +import org.apache.accumulo.core.security.Credentials;
+ import org.apache.accumulo.core.conf.AccumuloConfiguration;
+ import org.apache.accumulo.core.conf.SiteConfiguration;
 -import org.apache.accumulo.core.security.CredentialHelper;
  import org.apache.accumulo.core.util.ArgumentChecker;
  import org.apache.commons.codec.binary.Base64;
  import org.apache.hadoop.conf.Configuration;
@@@ -346,14 -232,14 +348,21 @@@ public class ConfiguratorBase 
      if ("MockInstance".equals(instanceType))
        return new MockInstance(conf.get(enumToConfKey(implementingClass, InstanceOpts.NAME)));
      else if ("ZooKeeperInstance".equals(instanceType)) {
 -      ZooKeeperInstance zki = new ZooKeeperInstance(conf.get(enumToConfKey(implementingClass,
InstanceOpts.NAME)), conf.get(enumToConfKey(implementingClass,
 -          InstanceOpts.ZOO_KEEPERS)));
++      ZooKeeperInstance zki;
 +      String clientConfigString = conf.get(enumToConfKey(implementingClass, InstanceOpts.CLIENT_CONFIG));
 +      if (clientConfigString == null) {
 +        String instanceName = conf.get(enumToConfKey(implementingClass, InstanceOpts.NAME));
 +        String zookeepers = conf.get(enumToConfKey(implementingClass, InstanceOpts.ZOO_KEEPERS));
-         return new ZooKeeperInstance(ClientConfiguration.loadDefault().withInstance(instanceName).withZkHosts(zookeepers));
++        zki = new ZooKeeperInstance(ClientConfiguration.loadDefault().withInstance(instanceName).withZkHosts(zookeepers));
 +      } else {
-         return new ZooKeeperInstance(ClientConfiguration.deserialize(clientConfigString));
++        zki = new ZooKeeperInstance(ClientConfiguration.deserialize(clientConfigString));
 +      }
+ 
+       // Wrap the DefaultConfiguration with a SiteConfiguration
+       AccumuloConfiguration xmlConfig = SiteConfiguration.getInstance(zki.getConfiguration());
+       zki.setConfiguration(xmlConfig);
+ 
+       return zki;
      } else if (instanceType.isEmpty())
        throw new IllegalStateException("Instance has not been configured for " + implementingClass.getSimpleName());
      else

http://git-wip-us.apache.org/repos/asf/accumulo/blob/2e658176/test/src/main/java/org/apache/accumulo/test/continuous/ContinuousVerify.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/accumulo/blob/2e658176/test/system/continuous/run-verify.sh
----------------------------------------------------------------------


Mime
View raw message