accumulo-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ctubb...@apache.org
Subject [3/3] git commit: Merge branch '1.6.0-SNAPSHOT'
Date Tue, 15 Apr 2014 19:11:43 GMT
Merge branch '1.6.0-SNAPSHOT'

Conflicts:
	test/src/main/java/org/apache/accumulo/test/randomwalk/concurrent/Shutdown.java


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

Branch: refs/heads/master
Commit: 1dd7d219df2d4173929816d7622b60e15fd33a89
Parents: 8520328 d77cd3f
Author: Christopher Tubbs <ctubbsii@apache.org>
Authored: Tue Apr 15 15:11:45 2014 -0400
Committer: Christopher Tubbs <ctubbsii@apache.org>
Committed: Tue Apr 15 15:11:45 2014 -0400

----------------------------------------------------------------------
 .../org/apache/accumulo/core/conf/Property.java | 12 ++--
 .../apache/accumulo/core/conf/PropertyType.java |  2 +
 .../apache/accumulo/core/conf/PropertyTest.java | 36 ++--------
 .../accumulo/core/conf/PropertyTypeTest.java    | 70 ++++++++++++++++++++
 .../test/randomwalk/concurrent/Shutdown.java    |  5 +-
 test/system/randomwalk/README.md                | 13 ++++
 6 files changed, 100 insertions(+), 38 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/accumulo/blob/1dd7d219/core/src/main/java/org/apache/accumulo/core/conf/Property.java
----------------------------------------------------------------------
diff --cc core/src/main/java/org/apache/accumulo/core/conf/Property.java
index 0502aae,60969be..5ab8ca5
--- a/core/src/main/java/org/apache/accumulo/core/conf/Property.java
+++ b/core/src/main/java/org/apache/accumulo/core/conf/Property.java
@@@ -473,12 -461,8 +473,13 @@@ public enum Property 
      return this.defaultValue;
    }
  
 +  /**
 +   * Gets the default value for this property. System properties are interpolated into the
value if necessary.
 +   *
 +   * @return default value
 +   */
    public String getDefaultValue() {
+     String v;
      if (isInterpolated()) {
        PropertiesConfiguration pconf = new PropertiesConfiguration();
        Properties systemProperties = System.getProperties();
@@@ -486,21 -470,15 +487,20 @@@
          pconf.append(new MapConfiguration(systemProperties));
        }
        pconf.addProperty("hack_default_value", this.defaultValue);
-       String v = pconf.getString("hack_default_value");
-       if (this.type == PropertyType.ABSOLUTEPATH)
-         return new File(v).getAbsolutePath();
-       else
-         return v;
+       v = pconf.getString("hack_default_value");
      } else {
-       return getRawDefaultValue();
+       v = getRawDefaultValue();
      }
+     if (this.type == PropertyType.ABSOLUTEPATH && !(v.trim().equals("")))
+       v = new File(v).getAbsolutePath();
+     return v;
    }
  
 +  /**
 +   * Gets the type of this property.
 +   *
 +   * @return property type
 +   */
    public PropertyType getType() {
      return this.type;
    }

http://git-wip-us.apache.org/repos/asf/accumulo/blob/1dd7d219/core/src/main/java/org/apache/accumulo/core/conf/PropertyType.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/accumulo/blob/1dd7d219/test/src/main/java/org/apache/accumulo/test/randomwalk/concurrent/Shutdown.java
----------------------------------------------------------------------
diff --cc test/src/main/java/org/apache/accumulo/test/randomwalk/concurrent/Shutdown.java
index 36464e1,0217fb4..ad93c78
--- a/test/src/main/java/org/apache/accumulo/test/randomwalk/concurrent/Shutdown.java
+++ b/test/src/main/java/org/apache/accumulo/test/randomwalk/concurrent/Shutdown.java
@@@ -34,11 -33,11 +34,11 @@@ import org.apache.accumulo.trace.instru
  public class Shutdown extends Test {
    
    @Override
 -  public void visit(State state, Properties props) throws Exception {
 +  public void visit(State state, Environment env, Properties props) throws Exception {
-     log.debug("shutting down");
+     log.info("shutting down");
      SetGoalState.main(new String[] {MasterGoalState.CLEAN_STOP.name()});
      
 -    while (!state.getConnector().instanceOperations().getTabletServers().isEmpty()) {
 +    while (!env.getConnector().instanceOperations().getTabletServers().isEmpty()) {
        UtilWaitThread.sleep(1000);
      }
      


Mime
View raw message