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

Ed Anuff commented on CASSANDRA-2355:
-------------------------------------

In Cassandra-2231 it was suggested that this be implemented by making 
comparators parameterizable.  The idea would be to perhaps replace 
FBUtilities.getComparator() with a ComparatorFactory that could be passed 
something like "UUIDType(restrictTo=time,sort=desc)" and parse out the 
parameters in order to construct the instance.  For Cassandra-2231, the 
proposed patch requires that FBUtilities.getComparator() caches and returns the 
same singleton comparator instances, so that requesting "UUIDType" will always 
return the same instance.  It would be necessary to cache the parameterized 
version in a similar way, and would probably need to be able to know that 
"UUIDType(restrictTo=time,sort=desc)" and "UUIDType(sort=desc,restrictTo=time)" 
should return the same cached comparator.

> Have an easy way to define the reverse comparator of any comparator
> -------------------------------------------------------------------
>
>                 Key: CASSANDRA-2355
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-2355
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Sylvain Lebresne
>            Assignee: Sylvain Lebresne
>            Priority: Minor
>   Original Estimate: 4h
>  Remaining Estimate: 4h
>


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

Reply via email to