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

Stefan Podkowinski commented on CASSANDRA-12870:
------------------------------------------------

Elements from the keyspace list will be removed by 
keyspaces.iterator().remove(). That's why the list is copied before as I don't 
want to remove elements from an "unowned" collection. LinkedList was chosen for 
performance reasons, although totally insignificant at such low cardinality. 
The LHS declaration should be changed to List<String> to make the code style 
coherent, yes. 

> Calculate pending ranges for identical KS settings just once
> ------------------------------------------------------------
>
>                 Key: CASSANDRA-12870
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12870
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Stefan Podkowinski
>            Assignee: Stefan Podkowinski
>             Fix For: 4.0
>
>         Attachments: 12870-trunk.patch
>
>
> The {{TokenMetadata.calculatePendingRanges()}} operation can be very 
> expensive and already has been subject to micro optimization in 
> CASSANDRA-9258. Instead of further optimizing the calculation itself, I'd 
> like to prevent it from being executed as often by only calling it just once 
> for all keyspaces sharing identical replication settings. 



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

Reply via email to