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

Joshua McKenzie resolved CASSANDRA-8952.
----------------------------------------
    Resolution: Fixed

In retrospect, linking to line #'s on trunk in a ticket isn't useful.  Changes 
look good and cover the few places I had concerns about w/regards to Windows.

Committed w/1 nit: added copyright header to the 2 new test files.

> Remove transient RandomAccessFile usage
> ---------------------------------------
>
>                 Key: CASSANDRA-8952
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-8952
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Joshua McKenzie
>            Assignee: Stefania
>            Priority: Minor
>              Labels: Windows
>             Fix For: 3.0
>
>
> There are a few places within the code base where we use a RandomAccessFile 
> transiently to either grab fd's or channels for other operations. This is 
> prone to access violations on Windows (see CASSANDRA-4050 and CASSANDRA-8709) 
> - while these usages don't appear to be causing issues at this time there's 
> no reason to keep them. The less RandomAccessFile usage in the code-base the 
> more stable we'll be on Windows.
> [SSTableReader.dropPageCache|https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/io/sstable/format/SSTableReader.java#L2021]
> * Used to getFD, have FileChannel version
> [FileUtils.truncate|https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/io/util/FileUtils.java#L188]
> * Used to get file channel for channel truncate call. Only use is in index 
> file close so channel truncation down-only is acceptable.
> [MMappedSegmentedFile.createSegments|https://github.com/apache/cassandra/blob/trunk/src/java/org/apache/cassandra/io/util/MmappedSegmentedFile.java#L196]
> * Used to get file channel for mapping.
> Keeping these in a single ticket as all three should be fairly trivial 
> refactors.



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

Reply via email to