[ 
https://issues.apache.org/jira/browse/CASSANDRA-12019?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Joshua McKenzie deleted CASSANDRA-12019:
----------------------------------------


> Platform independent implementation of DirectorySizeCalculator and refactor
> ---------------------------------------------------------------------------
>
>                 Key: CASSANDRA-12019
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12019
>             Project: Cassandra
>          Issue Type: Sub-task
>            Reporter: Joshua McKenzie
>            Assignee: Joshua McKenzie
>            Priority: Minor
>
> On linux, simplify to 
> {{Arrays.stream(path.listFiles()).mapToLong(File::length).sum();}}
> It's simpler and performs better, however is much slower on Windows.
> See discussion on CASSANDRA-8844.
> Also:
> bq. I don't get the DirectorySizeCalculator. Why the alive and visited sets, 
> the listFiles step? Either list the files and just loop through them, or do 
> the walkFileTree operation – you are now doing the same work twice. Use a 
> plain long instead of the atomic as the class is still thread-unsafe.
> So the existing class could use a refactor as well.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to