[
https://issues.apache.org/jira/browse/HBASE-15509?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15217420#comment-15217420
]
ramkrishna.s.vasudevan commented on HBASE-15509:
------------------------------------------------
Some comments and questions
Why have you selected a thread local? For a given writer the fsBlockWriter is
just one instance and when during flush/compaction we could use the same
fsBlockWriter only. So can we try to solve this without ThreadLocal?
bq.This does an array copy (only when we can't reuse TLS buffer),
I think this comment should be changed. Allocating and copying will happen only
when we can't reuse else the copy is anyway happening in order to rewrite the
contents.
bq.// TODO
Why is this TODO?
> Avoid copy of block data in HFileBlock$Writer.finishBlock
> ---------------------------------------------------------
>
> Key: HBASE-15509
> URL: https://issues.apache.org/jira/browse/HBASE-15509
> Project: HBase
> Issue Type: Sub-task
> Components: HFile
> Reporter: Vladimir Rodionov
> Assignee: Vladimir Rodionov
> Attachments: HBASE-15509-v1.patch, HBASE-15509-v2.patch
>
>
> This calls ByteArrayOutputStream.toByteArray() which creates a copy of data
> block.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)