You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kafka.apache.org by "Jun Rao (Updated) (JIRA)" <ji...@apache.org> on 2012/04/06 23:38:15 UTC

[jira] [Updated] (KAFKA-315) enable shallow iterator in ByteBufferMessageSet to allow mirroing data without decompression

     [ https://issues.apache.org/jira/browse/KAFKA-315?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jun Rao updated KAFKA-315:
--------------------------

    Resolution: Fixed
        Status: Resolved  (was: Patch Available)

Thanks for the review. Committed to trunk. 

For performance, with a socket buffer and a fetch size of 2MB, I was able to improve the cross DC mirroring throughput btw 2 brokers from about 9MB/sec to 30MB/sec, using this patch.

As for the decoder, shallowIterator only works with the DefaultDecoder. If a wrong decoder is used, the user will get an exception and realize the decoder problem. So, this is probably not a big concern.
                
> enable shallow iterator in ByteBufferMessageSet to allow mirroing data without decompression
> --------------------------------------------------------------------------------------------
>
>                 Key: KAFKA-315
>                 URL: https://issues.apache.org/jira/browse/KAFKA-315
>             Project: Kafka
>          Issue Type: Improvement
>          Components: core
>            Reporter: Jun Rao
>            Assignee: Jun Rao
>             Fix For: 0.7.1
>
>         Attachments: kafka-315.patch
>
>
> Currently, the iterator of ByteBufferMessageSet does deep iteration, ie, if messages are compressed, they will be decompressed first during the iteration. This adds CPU overhead. For mirroring data between 2 Kafka clusters, we can use a shallow iterator to avoid the decompression overhead.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira