You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bookkeeper.apache.org by mm...@apache.org on 2023/03/07 16:07:14 UTC

[bookkeeper] branch master updated: Fix memory leak issue of reading small entries (#3844)

This is an automated email from the ASF dual-hosted git repository.

mmerli pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git


The following commit(s) were added to refs/heads/master by this push:
     new 5703132316 Fix memory leak issue of reading small entries (#3844)
5703132316 is described below

commit 57031323166bd55004aaf50e3f46611dbb7eacf7
Author: Penghui Li <pe...@apache.org>
AuthorDate: Wed Mar 8 00:07:06 2023 +0800

    Fix memory leak issue of reading small entries (#3844)
---
 .../src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java   | 1 +
 1 file changed, 1 insertion(+)

diff --git a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java
index edbffa5f43..5f886dbe0d 100644
--- a/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java
+++ b/bookkeeper-server/src/main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java
@@ -271,6 +271,7 @@ public class BookieProtoEncoding {
 
                     if (isSmallEntry) {
                         buf.writeBytes(rr.getData());
+                        rr.release();
                         return buf;
                     } else {
                         return ByteBufList.get(buf, rr.getData());