cassandra-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joshua McKenzie (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CASSANDRA-9951) For opening files, change over usages of java.io.* to java.nio.file.Files counterparts to achieve standard behavior with Windows IFS.
Date Mon, 03 Aug 2015 19:29:04 GMT

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

Joshua McKenzie commented on CASSANDRA-9951:
--------------------------------------------

CASSANDRA-4050 and CASSANDRA-8709 do exactly this for the 2.2 release. Did you have somewhere
else in the code-base you've found that's specifically causing trouble w/the older IO packages
or is this more of a "In general, it's a bad idea to use io.*"?

> For opening files, change over usages of java.io.* to java.nio.file.Files counterparts
to achieve standard behavior with Windows IFS.
> -------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: CASSANDRA-9951
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-9951
>             Project: Cassandra
>          Issue Type: Improvement
>          Components: Core
>            Reporter: Garth Pickell
>
> So in windows, the JVM tends to open files without FILE_SHARE_DELETE when using the older
java.io.* components. This, I think, is a problem for Cassandra in that:
> a) it is not standard behavior.
> b) Cassandra kind of relies on this a lot as you routinely see problems in the log regarding
renaming of files or deleting of files.
> I don't think this is a bad design by any means, but Windows users will tend to experience
many problems in the areas of commit log cleanups and compaction.
> However, if you use the java.nio.file.Files class instead for opening files. These methods
use FILE_SHARE_DELETE.
> I have personally tested this, and I have done some poking around in the Cassandra source
which leads me to believe that changing over these usages would be relatively easy.



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

Mime
View raw message