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

Aleksey Yeschenko commented on CASSANDRA-14118:
-----------------------------------------------

[~JoshuaMcKenzie] in his comment, and [~bdeggleston] before him, explicitly 
mentioned that commit log and cache are specific implementation details of 
Cassandra's storage engine. You don't 'abstract' them - you make them part of 
the Cassandra {{WriteHandler}} implementation, in your terminology.

 

And you don't do that by writing code like this:
{code:java}
if (writeHandler.hasCommitLog() && writeCommitLog)
{
    Tracing.trace("Appending to commitlog");
    commitLogPosition = writeHandler.writeCommitLog(mutation);
}{code}
This is *not* how you 'abstract commit log'. External code shouldn't even know 
about the commitlog in this scenario. Writing to the commitlog - including the 
decision to do so - should be inside the default engine's default 
implementation of {{apply()}}.

Same goes for caching. This is not abstracting things away. I don't know what 
this is.

> Refactor write path
> -------------------
>
>                 Key: CASSANDRA-14118
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-14118
>             Project: Cassandra
>          Issue Type: Sub-task
>          Components: Core
>            Reporter: Dikang Gu
>            Assignee: Dikang Gu
>            Priority: Major
>
> As part of the pluggable storage engine effort, we'd like to modularize the 
> write path related code, make it to be independent from existing storage 
> engine implementation details.
> For now, refer to 
> https://docs.google.com/document/d/1suZlvhzgB6NIyBNpM9nxoHxz_Ri7qAm-UEO8v8AIFsc
>  for high level designs.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

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

Reply via email to