You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Joshua McKenzie (JIRA)" <ji...@apache.org> on 2016/07/06 20:35:11 UTC

[jira] [Commented] (CASSANDRA-12018) CDC follow-ups

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

Joshua McKenzie commented on CASSANDRA-12018:
---------------------------------------------

bq. On linux, simplify to {{Arrays.stream(path.listFiles()).mapToLong(File::length).sum();}}
Done.

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.
Cleaned up.

bq. tolerateErrorsInSection &=: I don't think it was intended for the value to depend on previous iterations.
Removed &

bq. SimpleCachedBufferPool should provide getThreadLocalReusableBuffer(int size) which should automatically reallocate if the available size is less, and not expose a setter at all.
Updated interface to get and setPreferredBufferType

Lastly, removed unused CommitLogTest.testRecovery(byte[] logData) and added NoSpamLogger message once every 10 seconds when at CDC capacity.

||branch||testall||dtest||
|[12018|https://github.com/josh-mckenzie/cassandra/tree/12018]|[testall|http://cassci.datastax.com/view/Dev/view/josh-mckenzie/job/josh-mckenzie-12018-testall]|[dtest|http://cassci.datastax.com/view/Dev/view/josh-mckenzie/job/josh-mckenzie-12018-dtest]|

[~blambov] - up for a review?

> CDC follow-ups
> --------------
>
>                 Key: CASSANDRA-12018
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-12018
>             Project: Cassandra
>          Issue Type: Improvement
>            Reporter: Joshua McKenzie
>            Assignee: Joshua McKenzie
>            Priority: Minor
>
> h6. Platform independent implementation of DirectorySizeCalculator
> On linux, simplify to {{Arrays.stream(path.listFiles()).mapToLong(File::length).sum();}}
> h6. Refactor DirectorySizeCalculator
> 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.
> h6. TolerateErrorsInSection should not depend on previous SyncSegment status in CommitLogReader
> bq. tolerateErrorsInSection &=: I don't think it was intended for the value to depend on previous iterations.
> h6. Refactor interface of SImpleCachedBufferPool
> bq. SimpleCachedBufferPool should provide getThreadLocalReusableBuffer(int size) which should automatically reallocate if the available size is less, and not expose a setter at all.
> h6. Change CDC exception to WriteFailureException instead of WriteTimeoutException
> h6. Remove unused CommitLogTest.testRecovery(byte[] logData)
> h6. NoSpamLogger a message when at CDC capacity



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