Author: ecn
Date: Tue Dec 27 20:34:04 2011
New Revision: 1225006

URL: http://svn.apache.org/viewvc?rev=1225006&view=rev
Log:
ACCUMULO-232 check for a setting that doesn't have a default value

Modified:
    
incubator/accumulo/branches/1.3/src/core/src/main/java/org/apache/accumulo/core/util/shell/Shell.java

Modified: 
incubator/accumulo/branches/1.3/src/core/src/main/java/org/apache/accumulo/core/util/shell/Shell.java
URL: 
http://svn.apache.org/viewvc/incubator/accumulo/branches/1.3/src/core/src/main/java/org/apache/accumulo/core/util/shell/Shell.java?rev=1225006&r1=1225005&r2=1225006&view=diff
==============================================================================
--- 
incubator/accumulo/branches/1.3/src/core/src/main/java/org/apache/accumulo/core/util/shell/Shell.java
 (original)
+++ 
incubator/accumulo/branches/1.3/src/core/src/main/java/org/apache/accumulo/core/util/shell/Shell.java
 Tue Dec 27 20:34:04 2011
@@ -2063,8 +2063,8 @@ public class Shell {
           log.debug("Successfully set table configuration option.");
         } else {
           if (!Property.isValidZooPropertyKey(property))
-            throw new BadArgumentException("Property cannot be modified in 
zookeepr", fullCommand, fullCommand.indexOf(property));
-          
+            throw new BadArgumentException("Property cannot be modified in 
zookeeper", fullCommand, fullCommand.indexOf(property));
+
           shellState.connector.instanceOperations().setProperty(property, 
value);
           log.debug("Successfully set system configuration option");
         }
@@ -2126,11 +2126,11 @@ public class Shell {
               printed = true;
             }
             if (!defaults.containsKey(key) || 
!defaults.get(key).equals(siteVal)) {
-              printConfLine(output, "site", printed ? "   @override" : key, 
siteVal);
+              printConfLine(output, "site", printed ? "   @override" : key, 
siteVal == null ? "" : siteVal);
               printed = true;
             }
             if (!siteConfig.containsKey(key) || !siteVal.equals(sysVal)) {
-              printConfLine(output, "system", printed ? "   @override" : key, 
sysVal);
+              printConfLine(output, "system", printed ? "   @override" : key, 
sysVal == null ? "" : sysVal);
               printed = true;
             }
           }


Reply via email to