You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lucene.apache.org by "Robert Muir (JIRA)" <ji...@apache.org> on 2014/04/01 07:34:15 UTC
[jira] [Commented] (LUCENE-5561) NativeUnixDirectory is broken
[ https://issues.apache.org/jira/browse/LUCENE-5561?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13956129#comment-13956129 ]
Robert Muir commented on LUCENE-5561:
-------------------------------------
Wow the test base class is awesome! Please resolve LUCENE-5067 once you get this in, I think this is a really useful thing to have in test-framework and for our tests.
> NativeUnixDirectory is broken
> -----------------------------
>
> Key: LUCENE-5561
> URL: https://issues.apache.org/jira/browse/LUCENE-5561
> Project: Lucene - Core
> Issue Type: Bug
> Reporter: Michael McCandless
> Assignee: Michael McCandless
> Fix For: 4.8, 5.0
>
> Attachments: LUCENE-5561.patch
>
>
> Several things:
> * It assumed ByteBuffer.allocateDirect would be page-aligned, but
> that's no longer true in Java 1.7
> * It failed to throw FNFE if a file didn't exist (throw IOExc
> instead)
> * It didn't have a default ctor taking File (so it was hard to run
> all tests against it)
> * It didn't have a test case
> * Some Javadocs problems
> * I cutover to FilterDirectory
> I tried to cutover to BufferedIndexOutput since this is essentially
> all that NativeUnixIO is doing ... but it's not simple because BIO
> sometimes flushes non-full (non-aligned) buffers even before the end
> of the file (its writeBytes method).
> I also factored out a BaseDirectoryTestCase, and tried to fold in
> "generic" Directory tests, and added/cutover explicit tests for the
> core directory impls.
--
This message was sent by Atlassian JIRA
(v6.2#6252)
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: dev-help@lucene.apache.org