[
https://issues.apache.org/jira/browse/CASSANDRA-9673?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14710437#comment-14710437
]
Stefania commented on CASSANDRA-9673:
-------------------------------------
This is done, I'm just waiting for the CI results:
http://cassci.datastax.com/view/Dev/view/stef1927/job/stef1927-9673-3.0-dtest/
http://cassci.datastax.com/view/Dev/view/stef1927/job/stef1927-9673-3.0-testall/
You are correct, the previous strategy was to handle legacy mutations by
invoking {{LegacyBatchMigrator.convertBatchEntries}} every time before
replaying:
_For replaying legacy mutations, I've opted for a conversion done before
replaying, which is not very efficient, but keeps the code clean. I figured
mixed version clusters are transient but if it concerns you I can enhance it._
I changed it so that legacy mutations are converted on-the-fly before being
applied.
I created a new class, {{Batch}}, and moved the {{BatchStoreMessage}} logic
there, so the messages are only concerned with serialization. The static remove
method, I actually prefer to have it in {{Batch}} rather than
{{BatchLogManager}} but you can move it if you prefer it in
{{BatchlogManager}}. The remaining nits should also be addressed.
> Improve batchlog write path
> ---------------------------
>
> Key: CASSANDRA-9673
> URL: https://issues.apache.org/jira/browse/CASSANDRA-9673
> Project: Cassandra
> Issue Type: Improvement
> Reporter: Aleksey Yeschenko
> Assignee: Stefania
> Labels: performance
> Fix For: 3.0 beta 2
>
> Attachments: 9673_001.tar.gz, 9673_004.tar.gz,
> gc_times_first_node_patched_004.png, gc_times_first_node_trunk_004.png
>
>
> Currently we allocate an on-heap {{ByteBuffer}} to serialize the batched
> mutations into, before sending it to a distant node, generating unnecessary
> garbage (potentially a lot of it).
> With materialized views using the batchlog, it would be nice to optimise the
> write path:
> - introduce a new verb ({{Batch}})
> - introduce a new message ({{BatchMessage}}) that would encapsulate the
> mutations, expiration, and creation time (similar to {{HintMessage}} in
> CASSANDRA-6230)
> - have MS serialize it directly instead of relying on an intermediate buffer
> To avoid merely shifting the temp buffer to the receiving side(s) we should
> change the structure of the batchlog table to use a list or a map of
> individual mutations.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)