This is an automated email from the ASF dual-hosted git repository.
sijie 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 f39c423 BookieProtoEncoding: use retainedSlice() to reduce garbage
f39c423 is described below
commit f39c423c8d2c493343e1172a81484c50c1b71168
Author: Samuel Just <[email protected]>
AuthorDate: Mon Jan 8 16:10:45 2018 -0800
BookieProtoEncoding: use retainedSlice() to reduce garbage
Signed-off-by: Samuel Just <sjustsalesforce.com>
Author: Samuel Just <[email protected]>
Reviewers: Sijie Guo <[email protected]>, Matteo Merli <[email protected]>
This closes #940 from athanatos/forupstream/requestprocessorfixes/3
---
.../main/java/org/apache/bookkeeper/proto/BookieProtoEncoding.java | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
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 00db67c..0423f76 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
@@ -289,8 +289,8 @@ public class BookieProtoEncoding {
entryId = buffer.readLong();
if (rc == BookieProtocol.EOK) {
- ByteBuf content = buffer.slice();
- return new BookieProtocol.ReadResponse(version, rc,
ledgerId, entryId, content.retain());
+ return new BookieProtocol.ReadResponse(version, rc,
+ ledgerId, entryId,
buffer.retainedSlice());
} else {
return new BookieProtocol.ReadResponse(version, rc,
ledgerId, entryId);
}
--
To stop receiving notification emails like this one, please contact
['"[email protected]" <[email protected]>'].