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

David Capwell commented on CASSANDRA-18212:
-------------------------------------------

bq. This isn't what we discussed?

The slack link you gave points to the above code and this was your response

{code}
we have direct support in memtable already today
but probably most users this would be enough for, yep
could do both, if worried about changing allocator, and still fix a broader set 
of use cases (anyone using either latest client or on heap memtables)
{code}

I am not against changing the allocator and special casing that as well, but I 
don't have a good intuition on the testing needed to validate it, so it comes 
off to me as higher risk than just handling the 2 cases we have today.

> Reduce memory allocations of calls to ByteBufer.duplicate() made in 
> org.apache.cassandra.transport.CBUtil#writeValue
> --------------------------------------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-18212
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-18212
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Legacy/Local Write-Read Paths
>            Reporter: Natnael Adere
>            Assignee: Natnael Adere
>            Priority: Normal
>         Attachments: DiskBased.png, allocations-after.html, 
> allocations-before.html
>
>          Time Spent: 1h 40m
>  Remaining Estimate: 0h
>
> Currently, 
> org.apache.cassandra.transport.CBUtil#writeValue(java.nio.ByteBuffer, 
> io.netty.buffer.ByteBuf) calls ByteBufer.duplicate() and is found to be 20% 
> of memory allocations in production. No changes have been made to reduce this 
> but there is discussion related to the issue in CASSANDRA-13741. Attached 
> below are the performance result for disk based queries and mostly memory 
> based queries. 



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@cassandra.apache.org
For additional commands, e-mail: commits-h...@cassandra.apache.org

Reply via email to