diff --git a/lucene/JRE_VERSION_MIGRATION.txt b/lucene/JRE_VERSION_MIGRATION.txt index 6face9eaa2f..c8404641c08 100644 --- a/lucene/JRE_VERSION_MIGRATION.txt +++ b/lucene/JRE_VERSION_MIGRATION.txt @@ -17,7 +17,7 @@ For reference, JRE major versions with their corresponding Unicode versions: * Java 6, Unicode 4.0 * Java 7, Unicode 6.0 * Java 8, Unicode 6.2 - * Java 9 (not yet released / offcially supported by Lucene), Unicode 7.0 + * Java 9 (not yet released / offcially supported by Lucene), Unicode 8.0 In general, whether or not you need to re-index largely depends upon the data that you are searching, and what was changed in any given Unicode version. For example, diff --git a/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java b/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java index 5f66074718e..44c03ea4b7e 100644 --- a/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java +++ b/lucene/test-framework/src/java/org/apache/lucene/store/BaseDirectoryTestCase.java @@ -1213,6 +1213,7 @@ public abstract class BaseDirectoryTestCase extends LuceneTestCase { continue; } try (IndexOutput out = dir.createOutput(candidate, IOContext.DEFAULT)) { + out.getFilePointer(); // just fake access to prevent compiler warning } fsDir.deleteFile(candidate); if (fsDir.checkPendingDeletions()) { @@ -1246,12 +1247,14 @@ public abstract class BaseDirectoryTestCase extends LuceneTestCase { if (random().nextBoolean()) { try (IndexOutput out = fsDir.createOutput(fileName + "z", IOContext.DEFAULT)) { + out.getFilePointer(); // just fake access to prevent compiler warning } // Make sure we can rename onto the deleted file: fsDir.renameFile(fileName + "z", fileName); } else { // write the file again try (IndexOutput out = dir.createOutput(fileName, IOContext.DEFAULT)) { + out.getFilePointer(); // just fake access to prevent compiler warning } } assertEquals(0, fsDir.fileLength(fileName)); diff --git a/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java b/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java index ef4397f40af..962062e0312 100644 --- a/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java +++ b/lucene/test-framework/src/java/org/apache/lucene/store/MockDirectoryWrapper.java @@ -19,7 +19,6 @@ package org.apache.lucene.store; import java.io.Closeable; import java.io.FileNotFoundException; import java.io.IOException; -import java.nio.file.FileSystem; import java.nio.file.NoSuchFileException; import java.util.ArrayList; import java.util.Arrays; @@ -46,8 +45,6 @@ import org.apache.lucene.index.IndexWriter; import org.apache.lucene.index.IndexWriterConfig; import org.apache.lucene.index.NoDeletionPolicy; import org.apache.lucene.index.SegmentInfos; -import org.apache.lucene.mockfile.FilterFileSystem; -import org.apache.lucene.mockfile.VirusCheckingFS; import org.apache.lucene.util.IOUtils; import org.apache.lucene.util.LuceneTestCase; import org.apache.lucene.util.TestUtil; @@ -423,6 +420,7 @@ public class MockDirectoryWrapper extends BaseDirectoryWrapper { deleteFile(name); try (IndexOutput out = in.createOutput(name, LuceneTestCase.newIOContext(randomState))) { + out.getFilePointer(); // just fake access to prevent compiler warning } catch (IOException ioe) { // ignore }