[ 
https://issues.apache.org/jira/browse/HBASE-17048?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15694995#comment-15694995
 ] 

Anoop Sam John commented on HBASE-17048:
----------------------------------------

{code}
buf.writeBytes(bb);
338         this.byteBufAllocator.bytesWritten(bb.remaining());
{code}
Test once and make sure that call to writeBytes wont advance the pos in bb. If 
so, bb.remaining() will give a wrong result. I have some doubt.
bq.this.buf = this.byteBufAllocator.allocate(alloc);
Will be odd passing the actual alloc every time we do allocate. Why can't pass 
the underlying alloc at time of constructor? So the new class act as a wrapper 
and this handles the bytesWritten.
Pls add code level comment abt the algo in guess().  This is taken from some of 
our existi


> Introduce a helper class to calcuate suitable ByteBuf size when allocating 
> send buffer in FanOutOneBlockAsyncDFSOutputHelper
> ----------------------------------------------------------------------------------------------------------------------------
>
>                 Key: HBASE-17048
>                 URL: https://issues.apache.org/jira/browse/HBASE-17048
>             Project: HBase
>          Issue Type: Sub-task
>          Components: wal
>    Affects Versions: 2.0.0
>            Reporter: Duo Zhang
>            Assignee: ramkrishna.s.vasudevan
>             Fix For: 2.0.0
>
>         Attachments: HBASE-17012_3.patch, HBASE-17048.patch, 
> HBASE-17048_1.patch
>
>
> As [~ram_krish] mentioned in HBASE-17021
> https://issues.apache.org/jira/browse/HBASE-17021?focusedCommentId=15646938&page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#comment-15646938
> The default ByteBuf size is 256B which is too small.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to