[ https://issues.apache.org/jira/browse/CASSANDRA-9673?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14627593#comment-14627593 ]
Stefania commented on CASSANDRA-9673: ------------------------------------- [~iamaleksey], the code is ready for a first round of review. The only things still shared with write mutations are {{DatabaseDescriptor.getWriteRpcTimeout()}} and {{WriteTimeoutException}}. Let me know if you want to change these two as well, however I assume you don't want to change the WRITE_TIMEOUT error code in the native protocol. As for testing, in addition to the unit tests, I wrote two new dtests to check that we can still inter-operate with 2.2 nodes. However until CASSANDRA-9704 is delivered we cannot run these tests. I feel like we should have more tests in this area, for example I couldn't find any test checking that we actually replay a batch in case of failure, but as usual I don't know how to write these tests without a way to inject failures or to mock objects. > 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 > Fix For: 3.0.0 rc1 > > > 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)