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

Sylvain Lebresne commented on CASSANDRA-3148:
---------------------------------------------

bq. can we make a AbstractMapBackedSortedColumns or something so we reduce code 
duplication?

We could, but we would have to change ThreadSafeSortedColumns and 
TreeMapBackedSortedColumns because they are using extension right now. Which 
was done to avoid some object allocation. Now I know, you'll say that this is 
exactly the kind of reason why you advocated using wrapping instead of 
extension back then on CASSANDRA-2843. And you would be right to say it. 
However, at least for now, there is not so much duplication: all the factory 
stuff can't be factored and the add/replace methods differ, so it is only a 
bunch of one line method. I would propose to stick to extension for now until 
some other change make an abstract class more worth it. But I won't fight for 
that if there is strong feeling involved against that.

bq. nit: not a fan of capitalizing final non-primitive objects as in FACTORY

Yeah, and it's true we don't do that in the code base. I'll lowercase all those 
(while committing if not sooner).

> Use TreeMap backed column families for the SSTable simple writers
> -----------------------------------------------------------------
>
>                 Key: CASSANDRA-3148
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-3148
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>    Affects Versions: 1.0
>            Reporter: Sylvain Lebresne
>            Assignee: Sylvain Lebresne
>            Priority: Trivial
>             Fix For: 1.0
>
>         Attachments: 0001-Use-TreeMap-for-SSTable-simple-writers-CFs.patch
>
>
> SSTable*SimpleWriter classes are not intended to be used concurrently (and 
> indeed they are not thread safe), so there is no point in using CLSM backed 
> column families.

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

        

Reply via email to