You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Jonathan Ellis (JIRA)" <ji...@apache.org> on 2011/02/21 06:17:38 UTC

[jira] Commented: (CASSANDRA-2203) Class to measure real memory allocated for an object

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

Jonathan Ellis commented on CASSANDRA-2203:
-------------------------------------------

I wrote a java agent to do this kind of thing more accurately: https://github.com/jbellis/jamm/

Includes test suite that starts with some simple stuff, so if your code disagrees with that it should be possible to track down which is right.

To use it with cassandra, copy the jamm jar into lib/ and add to cassandra-env.sh,
{noformat}
JVM_OPTS="$JVM_OPTS -javaagent:$CASSANDRA_HOME/lib/jamm-0.2.jar"
{noformat}


> Class to measure real memory allocated for an object
> ----------------------------------------------------
>
>                 Key: CASSANDRA-2203
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2203
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Chris Goffinet
>            Assignee: Chris Goffinet
>            Priority: Trivial
>         Attachments: 0001-Class-to-measure-actual-object-size-for-Hotspot-JVM.patch
>
>
> We wanted to share a class we are using internally to measure actual object sizes for Hotspot VM. We've been using this on RowCache and Memtables.

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