zookeeper-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [zookeeper] hanm commented on a change in pull request #1080: ZOOKEEPER-3496: Transaction larger than jute.maxbuffer makes ZooKeeper service unavailable
Date Fri, 20 Sep 2019 20:44:17 GMT
hanm commented on a change in pull request #1080: ZOOKEEPER-3496: Transaction larger than jute.maxbuffer
makes ZooKeeper service unavailable
URL: https://github.com/apache/zookeeper/pull/1080#discussion_r326796321
 
 

 ##########
 File path: zookeeper-jute/src/main/java/org/apache/jute/BinaryInputArchive.java
 ##########
 @@ -27,8 +27,23 @@
  *
  */
 public class BinaryInputArchive implements InputArchive {
-    static public final String UNREASONBLE_LENGTH= "Unreasonable length = ";
+    public static final String UNREASONBLE_LENGTH= "Unreasonable length = ";
+    public static final int maxBuffer = Integer.getInteger("jute.maxbuffer", 0xfffff);
+    private static final int extraMaxBuffer;
+
+    static {
+        Integer configuredExtraMaxBuffer =
+            Integer.getInteger("zookeeper.jute.maxbuffer.extrasize", maxBuffer);
 
 Review comment:
   one suggestion: existing maxbuffer has a name of "jute.maxbuffer" (note, without zookeeper
prefix), so it might be better
   that we name this extra size property as "jute.maxbuffer.extrasize" to be consistent with
existing style.
   
   also, we need documentation on this new property. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message