lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mikemcc...@apache.org
Subject svn commit: r1594107 - /lucene/dev/trunk/lucene/core/src/test/org/apache/lucene/index/TestTieredMergePolicy.java
Date Mon, 12 May 2014 22:40:44 GMT
Author: mikemccand
Date: Mon May 12 22:40:44 2014
New Revision: 1594107

URL: http://svn.apache.org/r1594107
Log:
LUCENE-5668: fix the codec so segment sizes don't change on each flush

Modified:
    lucene/dev/trunk/lucene/core/src/test/org/apache/lucene/index/TestTieredMergePolicy.java

Modified: lucene/dev/trunk/lucene/core/src/test/org/apache/lucene/index/TestTieredMergePolicy.java
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/lucene/core/src/test/org/apache/lucene/index/TestTieredMergePolicy.java?rev=1594107&r1=1594106&r2=1594107&view=diff
==============================================================================
--- lucene/dev/trunk/lucene/core/src/test/org/apache/lucene/index/TestTieredMergePolicy.java
(original)
+++ lucene/dev/trunk/lucene/core/src/test/org/apache/lucene/index/TestTieredMergePolicy.java
Mon May 12 22:40:44 2014
@@ -18,6 +18,7 @@ package org.apache.lucene.index;
  */
 
 import org.apache.lucene.analysis.MockAnalyzer;
+import org.apache.lucene.codecs.Codec;
 import org.apache.lucene.document.Document;
 import org.apache.lucene.document.Field;
 import org.apache.lucene.store.Directory;
@@ -218,6 +219,8 @@ public class TestTieredMergePolicy exten
     IndexWriterConfig iwc = new IndexWriterConfig(TEST_VERSION_CURRENT, new MockAnalyzer(random()));
     TieredMergePolicy tmp = (TieredMergePolicy) iwc.getMergePolicy();
     tmp.setFloorSegmentMB(0.00001);
+    // We need stable sizes for each segment:
+    iwc.setCodec(Codec.forName("Lucene46"));
     iwc.setMergeScheduler(new SerialMergeScheduler());
     iwc.setMaxBufferedDocs(100);
     iwc.setRAMBufferSizeMB(-1);



Mime
View raw message