# This patch file was generated by NetBeans IDE # Following Index: paths are relative to: /intern/home/arbeit/projekte/upstream-sources/netbeans/main-golden # This patch can be applied using context Tools: Patch action on respective folder. # It uses platform neutral UTF-8 encoding and \n newlines. # Above lines and this line are ignored by the patching process. Index: maven.indexer/src/org/netbeans/modules/maven/indexer/NexusRepositoryIndexerImpl.java --- maven.indexer/src/org/netbeans/modules/maven/indexer/NexusRepositoryIndexerImpl.java +++ maven.indexer/src/org/netbeans/modules/maven/indexer/NexusRepositoryIndexerImpl.java @@ -52,15 +52,21 @@ import java.util.regex.Matcher; import java.util.regex.Pattern; import java.util.zip.ZipError; +import org.apache.lucene.index.DirectoryReader; import org.apache.lucene.index.IndexReader; import org.apache.lucene.index.Term; -import org.apache.lucene.queryParser.QueryParser; +import org.apache.lucene.queryparser.classic.QueryParser; import org.apache.lucene.search.*; +import org.apache.lucene.store.Directory; import org.apache.lucene.store.FSDirectory; +import org.apache.lucene.store.LockFactory; +import org.apache.lucene.store.MMapDirectory; +import org.apache.lucene.store.NativeFSLockFactory; import org.apache.lucene.store.SimpleFSDirectory; import org.apache.maven.artifact.Artifact; import org.apache.maven.artifact.repository.ArtifactRepository; import org.apache.maven.index.*; +import org.apache.maven.index.Scanner; import org.apache.maven.index.artifact.ArtifactPackagingMapper; import org.apache.maven.index.context.DefaultIndexingContext; import org.apache.maven.index.context.IndexCreator; @@ -68,7 +74,6 @@ import org.apache.maven.index.context.IndexingContext; import org.apache.maven.index.creator.OsgiArtifactIndexCreator; import org.apache.maven.index.expr.StringSearchExpression; -import org.apache.maven.index.search.grouping.GGrouping; import org.apache.maven.index.updater.IndexUpdateRequest; import org.apache.maven.index.updater.IndexUpdater; import org.apache.maven.index.updater.ResourceFetcher; @@ -365,7 +370,7 @@ if (!loc.exists() || !new File(loc, "timestamp").exists()) { index = true; LOGGER.log(Level.FINER, "Index Not Available: {0} at: {1}", new Object[]{info.getId(), loc.getAbsolutePath()}); - } else if (!IndexReader.indexExists(new SimpleFSDirectory(loc))) { + } else if (! DirectoryReader.indexExists(new SimpleFSDirectory(loc))) { index = true; LOGGER.log(Level.FINER, "Index Not Available: {0} at: {1}", new Object[]{info.getId(), loc.getAbsolutePath()}); } @@ -1595,7 +1600,7 @@ for (final RepositoryInfo repo : repos) { File loc = new File(getDefaultIndexLocation(), repo.getId()); // index folder try { - if (loc.exists() && new File(loc, "timestamp").exists() && IndexReader.indexExists(new SimpleFSDirectory(loc))) { + if (loc.exists() && new File(loc, "timestamp").exists() && DirectoryReader.indexExists(new SimpleFSDirectory(loc))) { toRet.add(repo); } } catch (IOException ex) {