Apache9 commented on a change in pull request #320: HBASE-21879 Read HFile's
block to ByteBuffer directly instead of to byte for reducing young gc purpose
URL: https://github.com/apache/hbase/pull/320#discussion_r295300619
##########
File path:
hbase-common/src/main/java/org/apache/hadoop/hbase/io/ByteBufferListOutputStream.java
##########
@@ -39,37 +41,28 @@
public class ByteBufferListOutputStream extends ByteBufferOutputStream {
private static final Logger LOG =
LoggerFactory.getLogger(ByteBufferListOutputStream.class);
- private ByteBufferPool pool;
+ private ByteBuffAllocator allocator;
// Keep track of the BBs where bytes written to. We will first try to get a
BB from the pool. If
// it is not available will make a new one our own and keep writing to that.
We keep track of all
// the BBs that we got from pool, separately so that on
closeAndPutbackBuffers, we can make sure
// to return back all of them to pool
- protected List<ByteBuffer> allBufs = new ArrayList<>();
- protected List<ByteBuffer> bufsFromPool = new ArrayList<>();
+ protected List<SingleByteBuff> allBufs = new ArrayList<>();
Review comment:
Will a MultiByteBuff be better here?
----------------------------------------------------------------
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:
[email protected]
With regards,
Apache Git Services