Browse Source

ZOOKEEPER-2195 fsync.warningthresholdms in zoo.cfg not working (Biju Nair via phunt)

git-svn-id: https://svn.apache.org/repos/asf/zookeeper/trunk@1735892 13f79535-47bb-0310-9956-ffa450edef68
Patrick D. Hunt 9 years ago
parent
commit
7e889d125f

+ 3 - 0
CHANGES.txt

@@ -291,6 +291,9 @@ BUGFIXES:
   ZOOKEEPER-2393: Revert run-time dependency on log4j and slf4j-log4j12
   (Arshad Mohammad via cnauroth)
 
+  ZOOKEEPER-2195 fsync.warningthresholdms in zoo.cfg not working
+  (Biju Nair via phunt)
+
 IMPROVEMENTS:
   ZOOKEEPER-1660 Documentation for Dynamic Reconfiguration (Reed Wanderman-Milne via shralex)  
 

BIN
docs/index.pdf


BIN
docs/javaExample.pdf


BIN
docs/linkmap.pdf


BIN
docs/recipes.pdf


BIN
docs/releasenotes.pdf


+ 1 - 1
docs/zookeeperAdmin.html

@@ -1308,7 +1308,7 @@ server.3=zoo3:2888:3888</pre>
 <term>fsync.warningthresholdms</term>
 </dt>
 <dd>
-<p>(Java system property: <strong>fsync.warningthresholdms</strong>)</p>
+<p>(Java system property: <strong>zookeeper.fsync.warningthresholdms</strong>)</p>
 <p>
 <strong>New in 3.3.4:</strong> A
                warning message will be output to the log whenever an

BIN
docs/zookeeperAdmin.pdf


BIN
docs/zookeeperHierarchicalQuorums.pdf


BIN
docs/zookeeperInternals.pdf


BIN
docs/zookeeperJMX.pdf


BIN
docs/zookeeperObservers.pdf


BIN
docs/zookeeperOver.pdf


BIN
docs/zookeeperProgrammers.pdf


BIN
docs/zookeeperQuotas.pdf


BIN
docs/zookeeperReconfig.pdf


BIN
docs/zookeeperStarted.pdf


BIN
docs/zookeeperTutorial.pdf


+ 1 - 1
src/docs/src/documentation/content/xdocs/zookeeperAdmin.xml

@@ -901,7 +901,7 @@ server.3=zoo3:2888:3888</programlisting>
              <term>fsync.warningthresholdms</term>
              <listitem>
                <para>(Java system property: <emphasis
-               role="bold">fsync.warningthresholdms</emphasis>)</para>
+               role="bold">zookeeper.fsync.warningthresholdms</emphasis>)</para>
 
                <para><emphasis role="bold">New in 3.3.4:</emphasis> A
                warning message will be output to the log whenever an

+ 5 - 1
src/java/main/org/apache/zookeeper/server/persistence/FileTxnLog.java

@@ -112,7 +112,11 @@ public class FileTxnLog implements TxnLog {
                 LOG.warn(size + " is not a valid value for preAllocSize");
             }
         }
-        fsyncWarningThresholdMS = Long.getLong("fsync.warningthresholdms", 1000);
+        /** Local variable to read fsync.warningthresholdms into */
+        Long fsyncWarningThreshold;
+        if ((fsyncWarningThreshold = Long.getLong("zookeeper.fsync.warningthresholdms")) == null)
+            fsyncWarningThreshold = Long.getLong("fsync.warningthresholdms", 1000);
+        fsyncWarningThresholdMS = fsyncWarningThreshold;
     }
 
     long lastZxidSeen;