You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hbase.apache.org by te...@apache.org on 2016/07/01 21:26:13 UTC

hbase git commit: HBASE-16159 OutOfMemory exception when using AsyncRpcClient with encryption to read rpc response (Colin Ma)

Repository: hbase
Updated Branches:
  refs/heads/master fe75edb55 -> af9422c04


HBASE-16159 OutOfMemory exception when using AsyncRpcClient with encryption to read rpc response (Colin Ma)


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

Branch: refs/heads/master
Commit: af9422c04a343730d9ed6f3cf46cd6fc9d77c04a
Parents: fe75edb
Author: tedyu <yu...@gmail.com>
Authored: Fri Jul 1 14:26:09 2016 -0700
Committer: tedyu <yu...@gmail.com>
Committed: Fri Jul 1 14:26:09 2016 -0700

----------------------------------------------------------------------
 .../java/org/apache/hadoop/hbase/security/SaslClientHandler.java | 4 ++++
 1 file changed, 4 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hbase/blob/af9422c0/hbase-client/src/main/java/org/apache/hadoop/hbase/security/SaslClientHandler.java
----------------------------------------------------------------------
diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/SaslClientHandler.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/SaslClientHandler.java
index 9b522ae..d583e20 100644
--- a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/SaslClientHandler.java
+++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/SaslClientHandler.java
@@ -216,6 +216,8 @@ public class SaslClientHandler extends ChannelDuplexHandler {
           writeSaslToken(ctx, saslToken);
         }
       }
+      // release the memory
+      in.release();
 
       if (saslClient.isComplete()) {
         String qop = (String) saslClient.getNegotiatedProperty(Sasl.QOP);
@@ -246,6 +248,8 @@ public class SaslClientHandler extends ChannelDuplexHandler {
         }
         saslToken = new byte[length];
         in.readBytes(saslToken);
+        // release the memory
+        in.release();
       } catch (IndexOutOfBoundsException e) {
         return;
       }