cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Pavel Yaskevich (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-5521) move IndexSummary off heap
Date Wed, 01 May 2013 06:18:17 GMT

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

Pavel Yaskevich commented on CASSANDRA-5521:
--------------------------------------------

I see v2 does byte[] allocation on every getKey(int) call which would be happening very frequently
due to binary search which happens on very index lookup. So I don't think there is any real
benefit in terms of GC friendliness from moving off-heap in this case as we have to copy data
over multiple times anyway.

As an alternative to Unsafe we can try hybrid approach - identify if JNA is present and put
summaries off-heap (using JNA's Memory) in combination with Pointer.getByteBuffer() which
doesn't copy any data around but instead creates direct ByteBuffer, otherwise have IndexSummary
on-heap but split byte[][] and long[] into pages so we don't have to allocate contiguous space
for big SSTables which would be much GC friendlier. 


                
> move IndexSummary off heap
> --------------------------
>
>                 Key: CASSANDRA-5521
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-5521
>             Project: Cassandra
>          Issue Type: Bug
>          Components: Core
>            Reporter: Jonathan Ellis
>            Assignee: Vijay
>             Fix For: 2.0
>
>
> IndexSummary can still use a lot of heap for narrow-row sstables.  (It can also contribute
to memory fragmentation because of the large arrays it creates.)

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message