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

ryan rawson commented on HBASE-3514:
------------------------------------

This is breaking the build, here is the output:

https://hudson.apache.org/hudson/job/HBase-TRUNK/1749/

Apparently this line:
+      // pre-allocates the byte stream to the block size + 25%
+      baos = new ByteArrayOutputStream(blocksize + (int)(blocksize * 0.25));

isn't doing the right thing.  The patch had (blocksize / 25) which wasnt giving 
what the comment said, so I switched to what you see here.  Somehow this stack 
snippet happens:


Caused by: java.lang.IllegalArgumentException: Negative initial size: 
-1610612738
        at java.io.ByteArrayOutputStream.<init>(ByteArrayOutputStream.java:57)
        at 
org.apache.hadoop.hbase.io.hfile.HFile$Writer.newBlock(HFile.java:417)

Can you poke at it please?

> Speedup HFile.Writer append
> ---------------------------
>
>                 Key: HBASE-3514
>                 URL: https://issues.apache.org/jira/browse/HBASE-3514
>             Project: HBase
>          Issue Type: Improvement
>          Components: io
>    Affects Versions: 0.90.0
>            Reporter: Matteo Bertozzi
>            Priority: Minor
>         Attachments: HBASE-3514-append.patch, 
> HBASE-3514-metaBlock-bsearch.patch
>
>
> Remove double writes when block cache is specified, by using, only, the 
> ByteArrayDataStream.
> baos is flushed with the compress stream on finishBlock.
> On my machines HFilePerformanceEvaluation SequentialWriteBenchmark passes 
> from 4000ms to 2500ms.
> Running SequentialWriteBenchmark for 1000000 rows took 4247ms.
> Running SequentialWriteBenchmark for 1000000 rows took 4512ms.
> Running SequentialWriteBenchmark for 1000000 rows took 4498ms.
> Running SequentialWriteBenchmark for 1000000 rows took 2697ms.
> Running SequentialWriteBenchmark for 1000000 rows took 2770ms.
> Running SequentialWriteBenchmark for 1000000 rows took 2721ms.

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to