Sfoglia il codice sorgente

ZOOKEEPER-1411. Consolidate membership management, distinguish between static and dynamic configuration parameters. A small bug fix.

git-svn-id: https://svn.apache.org/repos/asf/zookeeper/trunk@1463329 13f79535-47bb-0310-9956-ffa450edef68
Michi Mutsuzaki 12 anni fa
parent
commit
52cf2242c9

+ 1 - 1
src/java/main/org/apache/zookeeper/server/quorum/QuorumPeerConfig.java

@@ -225,7 +225,7 @@ public class QuorumPeerConfig {
                 snapRetainCount = Integer.parseInt(value);
             } else if (key.equals("autopurge.purgeInterval")) {
                 purgeInterval = Integer.parseInt(value);
-            } else if ((key.startsWith("server.") || key.startsWith("group") || key.startsWith("weight")) && zkProp.entrySet().contains("dynamicConfigFile")){                
+            } else if ((key.startsWith("server.") || key.startsWith("group") || key.startsWith("weight")) && zkProp.containsKey("dynamicConfigFile")){                
                throw new ConfigException("parameter: " + key + " must be in a separate dynamic config file");
             } else {
                 System.setProperty("zookeeper." + key, value);