Package org.apache.lucene.index

Examples of org.apache.lucene.index.UpgradeIndexMergePolicy


            directoryManager.delete(migrationName);
        }

        Directory migrationDir = directoryManager.getDirectory(migrationName);
        final IndexWriterConfig c = new IndexWriterConfig(Version.LUCENE_36, new JackrabbitAnalyzer());
        c.setMergePolicy(new UpgradeIndexMergePolicy(new LogByteSizeMergePolicy()));
        c.setIndexDeletionPolicy(new KeepOnlyLastCommitDeletionPolicy());
        try {
            IndexWriter writer = new IndexWriter(migrationDir, c);
            try {
                IndexReader r = new MigrationIndexReader(IndexReader.open(index.getDirectory()),
View Full Code Here

TOP

Related Classes of org.apache.lucene.index.UpgradeIndexMergePolicy

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.