lucene-java-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From uschind...@apache.org
Subject svn commit: r926746 - in /lucene/java/branches/flex_1458: ./ backwards/src/ backwards/src/java/org/apache/lucene/search/ backwards/src/test/org/apache/lucene/analysis/ backwards/src/test/org/apache/lucene/document/ backwards/src/test/org/apache/lucene/...
Date Tue, 23 Mar 2010 19:36:48 GMT
Author: uschindler
Date: Tue Mar 23 19:36:47 2010
New Revision: 926746

URL: http://svn.apache.org/viewvc?rev=926746&view=rev
Log:
More merges from solr's newtrunk folder in svn - that was a not so good idea to only commit
there :(

The new flex branch is now up-to-date according to last commit message.

Added:
    lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/NoMergePolicy.java
      - copied unchanged from r926289, lucene/solr/branches/newtrunk/lucene/src/java/org/apache/lucene/index/NoMergePolicy.java
    lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/NoMergeScheduler.java
      - copied unchanged from r926289, lucene/solr/branches/newtrunk/lucene/src/java/org/apache/lucene/index/NoMergeScheduler.java
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestNoMergePolicy.java
      - copied unchanged from r926289, lucene/solr/branches/newtrunk/lucene/src/test/org/apache/lucene/index/TestNoMergePolicy.java
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestNoMergeScheduler.java
      - copied unchanged from r926289, lucene/solr/branches/newtrunk/lucene/src/test/org/apache/lucene/index/TestNoMergeScheduler.java
Modified:
    lucene/java/branches/flex_1458/   (props changed)
    lucene/java/branches/flex_1458/CHANGES.txt
    lucene/java/branches/flex_1458/backwards/src/   (props changed)
    lucene/java/branches/flex_1458/backwards/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java
  (props changed)
    lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java
  (props changed)
    lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/document/TestDateTools.java
  (props changed)
    lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/document/TestNumberTools.java
  (props changed)
    lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java
  (props changed)
    lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/util/TestAttributeSource.java
  (props changed)
    lucene/java/branches/flex_1458/build.xml   (props changed)
    lucene/java/branches/flex_1458/contrib/   (props changed)
    lucene/java/branches/flex_1458/contrib/CHANGES.txt   (props changed)
    lucene/java/branches/flex_1458/contrib/highlighter/src/test/   (props changed)
    lucene/java/branches/flex_1458/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java
  (props changed)
    lucene/java/branches/flex_1458/src/java/org/apache/lucene/analysis/Tokenizer.java   (props
changed)
    lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriter.java
    lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriterConfig.java
    lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/MergeScheduler.java
    lucene/java/branches/flex_1458/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java
  (props changed)
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java
  (props changed)
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/document/TestDateTools.java
  (props changed)
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/document/TestNumberTools.java
  (props changed)
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java
  (props changed)
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestIndexWriterConfig.java
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestStressIndexing2.java
    lucene/java/branches/flex_1458/src/test/org/apache/lucene/util/TestAttributeSource.java
  (props changed)

Propchange: lucene/java/branches/flex_1458/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -4,3 +4,4 @@
 /lucene/java/branches/lucene_2_9_back_compat_tests:818601-821336
 /lucene/java/branches/lucene_3_0:880793,896906
 /lucene/java/trunk:824912-825292,827043-833960,880727-886190,889185,889614-916543,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene:926020-926289

Modified: lucene/java/branches/flex_1458/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/java/branches/flex_1458/CHANGES.txt?rev=926746&r1=926745&r2=926746&view=diff
==============================================================================
--- lucene/java/branches/flex_1458/CHANGES.txt (original)
+++ lucene/java/branches/flex_1458/CHANGES.txt Tue Mar 23 19:36:47 2010
@@ -237,6 +237,16 @@ New features
   documents (previously this was hardwired to 5), using
   IndexWriterConfig.setMaxThreadStates.  (Mike McCandless)
 
+* LUCENE-2297: Enable turning on reader pooling inside IndexWriter
+  even when getReader (near-real-timer reader) is not in use, through
+  IndexWriterConfig.enable/disableReaderPooling.  (Mike McCandless)
+
+* LUCENE-2331: Add NoMergePolicy which never returns any merges to execute. In
+  addition, add NoMergeScheduler which never executes any merges. These two are
+  convenient classes in case you want to disable segment merges by IndexWriter
+  without tweaking a particular MergePolicy parameters, such as mergeFactor.
+  MergeScheduler's methods are now public. (Shai Erera via Mike McCandless)
+  
 Optimizations
 
 * LUCENE-2075: Terms dict cache is now shared across threads instead

Propchange: lucene/java/branches/flex_1458/backwards/src/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -6,3 +6,4 @@
 /lucene/java/branches/lucene_3_0_back_compat_tests/src:880869-912395
 /lucene/java/trunk/backwards/src:922624,922806,923238,924286,924321-924731,924781,925176-925462
 /lucene/java/trunk/src:881213,881315,881466,881819,882374,882807,882888,882977,883074-883075,885214
+/lucene/solr/branches/newtrunk/lucene/backwards/src:926020-926289

Propchange: lucene/java/branches/flex_1458/backwards/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -6,3 +6,4 @@
 /lucene/java/branches/lucene_3_0_back_compat_tests/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:880869-912395
 /lucene/java/trunk/backwards/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:922624,922806,923238,924286,924321-924731,924781,925176-925462
 /lucene/java/trunk/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:881213,881315,881466,881819,881984,882374,882807,882888,882977,883074-883075,885214,912319,912324,912328,912335,912372
+/lucene/solr/branches/newtrunk/lucene/backwards/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:926020-926289

Propchange: lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -5,3 +5,4 @@
 /lucene/java/branches/lucene_3_0_back_compat_tests/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:880869-912395
 /lucene/java/trunk/backwards/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:922624,922806,923238,924286,924321-924731,924781,925176-925462
 /lucene/java/trunk/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:881213,881315,881466,881819,882374,882807,882888,882977,883074-883075,885214,912319,912324,912328,912335,912372
+/lucene/solr/branches/newtrunk/lucene/backwards/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:926020-926289

Propchange: lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/document/TestDateTools.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -5,3 +5,4 @@
 /lucene/java/branches/lucene_3_0_back_compat_tests/src/test/org/apache/lucene/document/TestDateTools.java:880869-912395
 /lucene/java/trunk/backwards/src/test/org/apache/lucene/document/TestDateTools.java:922624,922806,923238,924286,924321-924731,924781,925176-925462
 /lucene/java/trunk/src/test/org/apache/lucene/document/TestDateTools.java:881213,881315,881466,881819,882374,882807,882888,882977,883074-883075,885214,912319,912324,912328,912335,912372
+/lucene/solr/branches/newtrunk/lucene/backwards/src/test/org/apache/lucene/document/TestDateTools.java:926020-926289

Propchange: lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/document/TestNumberTools.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -5,3 +5,4 @@
 /lucene/java/branches/lucene_3_0_back_compat_tests/src/test/org/apache/lucene/document/TestNumberTools.java:880869-912395
 /lucene/java/trunk/backwards/src/test/org/apache/lucene/document/TestNumberTools.java:922624,922806,923238,924286,924321-924731,924781,925176-925462
 /lucene/java/trunk/src/test/org/apache/lucene/document/TestNumberTools.java:881213,881315,881466,881819,882374,882807,882888,882977,883074-883075,885214,912319,912324,912328,912335,912372
+/lucene/solr/branches/newtrunk/lucene/backwards/src/test/org/apache/lucene/document/TestNumberTools.java:926020-926289

Propchange: lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -5,3 +5,4 @@
 /lucene/java/branches/lucene_3_0_back_compat_tests/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:880869-912395
 /lucene/java/trunk/backwards/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:922624,922806,923238,924286,924321-924731,924781,925176-925462
 /lucene/java/trunk/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:881213,881315,881466,881819,882374,882807,882888,882977,883074-883075,885214,912319,912324,912328,912335,912372
+/lucene/solr/branches/newtrunk/lucene/backwards/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:926020-926289

Propchange: lucene/java/branches/flex_1458/backwards/src/test/org/apache/lucene/util/TestAttributeSource.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -6,3 +6,4 @@
 /lucene/java/branches/lucene_3_0_back_compat_tests/src/test/org/apache/lucene/util/TestAttributeSource.java:880869-912395
 /lucene/java/trunk/backwards/src/test/org/apache/lucene/util/TestAttributeSource.java:922624,922806,923238,924286,924321-924731,924781,925176-925462
 /lucene/java/trunk/src/test/org/apache/lucene/util/TestAttributeSource.java:881213,881315,881466,881819,882374,882807,882888,882977,883074-883075,883079,885214,912319,912324,912328,912335,912372
+/lucene/solr/branches/newtrunk/lucene/backwards/src/test/org/apache/lucene/util/TestAttributeSource.java:926020-926289

Propchange: lucene/java/branches/flex_1458/build.xml
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -1,3 +1,4 @@
 /lucene/dev/trunk/lucene/build.xml:926653
 /lucene/java/branches/lucene_2_9/build.xml:909334
 /lucene/java/trunk/build.xml:916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/build.xml:926020-926289

Propchange: lucene/java/branches/flex_1458/contrib/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -4,3 +4,4 @@
 /lucene/java/branches/lucene_2_9_back_compat_tests/contrib:818601-821336
 /lucene/java/branches/lucene_3_0/contrib:880793,896906
 /lucene/java/trunk/contrib:824912-825292,827043-833960,880727-886190,889185,889614-916543,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/contrib:926020-926289

Propchange: lucene/java/branches/flex_1458/contrib/CHANGES.txt
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -4,3 +4,4 @@
 /lucene/java/branches/lucene_2_9_back_compat_tests/contrib/CHANGES.txt:818601-821336
 /lucene/java/branches/lucene_3_0/contrib/CHANGES.txt:880793,896906
 /lucene/java/trunk/contrib/CHANGES.txt:829439-833960,880727-886190,889185,889622,889667,889866-899001,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/contrib/CHANGES.txt:926020-926289

Propchange: lucene/java/branches/flex_1458/contrib/highlighter/src/test/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -4,3 +4,4 @@
 /lucene/java/branches/lucene_2_9_back_compat_tests/contrib/highlighter/src/test:818601-821336
 /lucene/java/branches/lucene_3_0/contrib/highlighter/src/test:880793,896906
 /lucene/java/trunk/contrib/highlighter/src/test:829439-833960,880727-886190,889185,889614-916543,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/contrib/highlighter/src/test:926020-926289

Propchange: lucene/java/branches/flex_1458/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -1,3 +1,4 @@
 /lucene/dev/trunk/lucene/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:926653
 /lucene/java/branches/lucene_2_9/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:909334
 /lucene/java/trunk/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:926020-926289

Propchange: lucene/java/branches/flex_1458/src/java/org/apache/lucene/analysis/Tokenizer.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -1,3 +1,4 @@
 /lucene/dev/trunk/lucene/src/java/org/apache/lucene/analysis/Tokenizer.java:926653
 /lucene/java/branches/lucene_2_9/src/java/org/apache/lucene/analysis/Tokenizer.java:909334
 /lucene/java/trunk/src/java/org/apache/lucene/analysis/Tokenizer.java:916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/src/java/org/apache/lucene/analysis/Tokenizer.java:926020-926289

Modified: lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriter.java
URL: http://svn.apache.org/viewvc/lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriter.java?rev=926746&r1=926745&r2=926746&view=diff
==============================================================================
--- lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriter.java (original)
+++ lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriter.java Tue Mar
23 19:36:47 2010
@@ -1087,6 +1087,8 @@ public class IndexWriter implements Clos
     mergedSegmentWarmer = conf.getMergedSegmentWarmer();
     codecs = conf.getCodecProvider();
     
+    poolReaders = conf.getReaderPooling();
+
     OpenMode mode = conf.getOpenMode();
     boolean create;
     if (mode == OpenMode.CREATE) {

Modified: lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriterConfig.java
URL: http://svn.apache.org/viewvc/lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriterConfig.java?rev=926746&r1=926745&r2=926746&view=diff
==============================================================================
--- lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriterConfig.java
(original)
+++ lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/IndexWriterConfig.java
Tue Mar 23 19:36:47 2010
@@ -88,6 +88,9 @@ public final class IndexWriterConfig imp
    *  others to finish. */
   public final static int DEFAULT_MAX_THREAD_STATES = 8;
 
+  /** Default setting for {@link #setIndexWriterPooling}. */
+  public final static boolean DEFAULT_READER_POOLING = false;
+
   /**
    * Sets the default (for any instance) maximum time to wait for a write lock
    * (in milliseconds).
@@ -123,6 +126,7 @@ public final class IndexWriterConfig imp
   private CodecProvider codecProvider;
   private MergePolicy mergePolicy;
   private int maxThreadStates;
+  private boolean readerPooling;
   
   // required for clone
   private Version matchVersion;
@@ -153,6 +157,7 @@ public final class IndexWriterConfig imp
     codecProvider = DEFAULT_CODEC_PROVIDER;
     mergePolicy = new LogByteSizeMergePolicy();
     maxThreadStates = DEFAULT_MAX_THREAD_STATES;
+    readerPooling = DEFAULT_READER_POOLING;
   }
   
   @Override
@@ -524,6 +529,15 @@ public final class IndexWriterConfig imp
 
   
   /**
+   * Returns the current MergePolicy in use by this writer.
+   * 
+   * @see #setMergePolicy(MergePolicy)
+   */
+  public MergePolicy getMergePolicy() {
+    return mergePolicy;
+  }
+
+  /**
    * Sets the max number of simultaneous threads that may be indexing documents
    * at once in IndexWriter. Values < 1 are invalid and if passed
    * <code>maxThreadStates</code> will be set to
@@ -540,13 +554,23 @@ public final class IndexWriterConfig imp
     return maxThreadStates;
   }
 
-  /**
-   * Returns the current MergePolicy in use by this writer.
-   * 
-   * @see #setMergePolicy(MergePolicy)
-   */
-  public MergePolicy getMergePolicy() {
-    return mergePolicy;
+  /** By default, IndexWriter does not pool the
+   *  SegmentReaders it must open for deletions and
+   *  merging, unless a near-real-time reader has been
+   *  obtained by calling {@link IndexWriter#getReader}.
+   *  This method lets you enable pooling without getting a
+   *  near-real-time reader.  NOTE: if you set this to
+   *  false, IndexWriter will still pool readers once
+   *  {@link IndexWriter#getReader} is called. */
+  public IndexWriterConfig setReaderPooling(boolean readerPooling) {
+    this.readerPooling = readerPooling;
+    return this;
+  }
+
+  /** Returns true if IndexWriter should pool readers even
+   *  if {@link IndexWriter#getReader} has not been called. */
+  public boolean getReaderPooling() {
+    return readerPooling;
   }
 
   /** Expert: sets the {@link DocConsumer} chain to be used to process documents. */
@@ -581,6 +605,7 @@ public final class IndexWriterConfig imp
     sb.append("codecProvider=").append(codecProvider).append("\n");
     sb.append("mergePolicy=").append(mergePolicy).append("\n");
     sb.append("maxThreadStates=").append(maxThreadStates).append("\n");
+    sb.append("readerPooling=").append(readerPooling).append("\n");
     return sb.toString();
   }
 }

Modified: lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/MergeScheduler.java
URL: http://svn.apache.org/viewvc/lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/MergeScheduler.java?rev=926746&r1=926745&r2=926746&view=diff
==============================================================================
--- lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/MergeScheduler.java (original)
+++ lucene/java/branches/flex_1458/src/java/org/apache/lucene/index/MergeScheduler.java Tue
Mar 23 19:36:47 2010
@@ -26,14 +26,13 @@ import java.io.IOException;
  *
  * @lucene.experimental
 */
-
 public abstract class MergeScheduler {
 
   /** Run the merges provided by {@link IndexWriter#getNextMerge()}. */
-  abstract void merge(IndexWriter writer)
+  public abstract void merge(IndexWriter writer)
     throws CorruptIndexException, IOException;
 
   /** Close this MergeScheduler. */
-  abstract void close()
+  public abstract void close()
     throws CorruptIndexException, IOException;
 }

Propchange: lucene/java/branches/flex_1458/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -1,3 +1,4 @@
 /lucene/dev/trunk/lucene/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:926653
 /lucene/java/branches/lucene_2_9/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:909334
 /lucene/java/trunk/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:926020-926289

Propchange: lucene/java/branches/flex_1458/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -3,3 +3,4 @@
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:829134,829881,831036,896850,909334
 /lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:880793,896906
 /lucene/java/trunk/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:824912-825292,826213-833960,880727-886190,889185,889614-916543,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:926020-926289

Propchange: lucene/java/branches/flex_1458/src/test/org/apache/lucene/document/TestDateTools.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -3,3 +3,4 @@
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/document/TestDateTools.java:829134,829881,831036,896850,909334
 /lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/document/TestDateTools.java:880793,896906
 /lucene/java/trunk/src/test/org/apache/lucene/document/TestDateTools.java:824912-825292,826213-833960,880727-886190,889185,889614-916543,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/src/test/org/apache/lucene/document/TestDateTools.java:926020-926289

Propchange: lucene/java/branches/flex_1458/src/test/org/apache/lucene/document/TestNumberTools.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -3,3 +3,4 @@
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/document/TestNumberTools.java:829134,829881,831036,896850,909334
 /lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/document/TestNumberTools.java:880793,896906
 /lucene/java/trunk/src/test/org/apache/lucene/document/TestNumberTools.java:824912-825292,826213-833960,880727-886190,889185,889614-916543,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/src/test/org/apache/lucene/document/TestNumberTools.java:926020-926289

Propchange: lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -3,3 +3,4 @@
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:829134,829881,831036,896850,909334
 /lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:880793,896906
 /lucene/java/trunk/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:824912-825292,826213-833960,880727-886190,889185,889614-916543,916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:926020-926289

Modified: lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestIndexWriterConfig.java
URL: http://svn.apache.org/viewvc/lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestIndexWriterConfig.java?rev=926746&r1=926745&r2=926746&view=diff
==============================================================================
--- lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestIndexWriterConfig.java
(original)
+++ lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestIndexWriterConfig.java
Tue Mar 23 19:36:47 2010
@@ -79,6 +79,7 @@ public class TestIndexWriterConfig exten
     assertEquals(IndexWriterConfig.DEFAULT_MAX_BUFFERED_DELETE_TERMS, conf.getMaxBufferedDeleteTerms());
     assertEquals(IndexWriterConfig.DEFAULT_RAM_BUFFER_SIZE_MB, conf.getRAMBufferSizeMB(),
0.0);
     assertEquals(IndexWriterConfig.DEFAULT_MAX_BUFFERED_DOCS, conf.getMaxBufferedDocs());
+    assertEquals(IndexWriterConfig.DEFAULT_READER_POOLING, conf.getReaderPooling());
     assertTrue(DocumentsWriter.defaultIndexingChain == conf.getIndexingChain());
     assertNull(conf.getMergedSegmentWarmer());
     assertEquals(IndexWriterConfig.DEFAULT_CODEC_PROVIDER, CodecProvider.getDefault());
@@ -105,6 +106,7 @@ public class TestIndexWriterConfig exten
     getters.add("getCodecProvider");
     getters.add("getMergePolicy");
     getters.add("getMaxThreadStates");
+    getters.add("getReaderPooling");
     for (Method m : IndexWriterConfig.class.getDeclaredMethods()) {
       if (m.getDeclaringClass() == IndexWriterConfig.class && m.getName().startsWith("get"))
{
         assertTrue("method " + m.getName() + " is not tested for defaults", getters.contains(m.getName()));
@@ -136,6 +138,7 @@ public class TestIndexWriterConfig exten
     assertEquals(IndexWriterConfig.DISABLE_AUTO_FLUSH, IndexWriterConfig.DEFAULT_MAX_BUFFERED_DELETE_TERMS);
     assertEquals(IndexWriterConfig.DISABLE_AUTO_FLUSH, IndexWriterConfig.DEFAULT_MAX_BUFFERED_DOCS);
     assertEquals(16.0, IndexWriterConfig.DEFAULT_RAM_BUFFER_SIZE_MB, 0.0);
+    assertEquals(false, IndexWriterConfig.DEFAULT_READER_POOLING);
     assertEquals(8, IndexWriterConfig.DEFAULT_MAX_THREAD_STATES);
   }
   

Modified: lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestStressIndexing2.java
URL: http://svn.apache.org/viewvc/lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestStressIndexing2.java?rev=926746&r1=926745&r2=926746&view=diff
==============================================================================
--- lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestStressIndexing2.java
(original)
+++ lucene/java/branches/flex_1458/src/test/org/apache/lucene/index/TestStressIndexing2.java
Tue Mar 23 19:36:47 2010
@@ -85,7 +85,8 @@ public class TestStressIndexing2 extends
     Directory dir2 = new MockRAMDirectory();
     // mergeFactor=2; maxBufferedDocs=2; Map docs = indexRandom(1, 3, 2, dir1);
     int maxThreadStates = 1+r.nextInt(10);
-    Map<String,Document> docs = indexRandom(10, 10, 100, dir1, maxThreadStates);
+    boolean doReaderPooling = r.nextBoolean();
+    Map<String,Document> docs = indexRandom(10, 10, 100, dir1, maxThreadStates, doReaderPooling);
     indexSerial(docs, dir2);
 
     // verifying verify
@@ -107,6 +108,7 @@ public class TestStressIndexing2 extends
       mergeFactor=r.nextInt(3)+2;
       maxBufferedDocs=r.nextInt(3)+2;
       int maxThreadStates = 1+r.nextInt(10);
+      boolean doReaderPooling = r.nextBoolean();
       seed++;
 
       int nThreads=r.nextInt(5)+1;
@@ -114,7 +116,7 @@ public class TestStressIndexing2 extends
       int range=r.nextInt(20)+1;
       Directory dir1 = new MockRAMDirectory();
       Directory dir2 = new MockRAMDirectory();
-      Map<String,Document> docs = indexRandom(nThreads, iter, range, dir1, maxThreadStates);
+      Map<String,Document> docs = indexRandom(nThreads, iter, range, dir1, maxThreadStates,
doReaderPooling);
       //System.out.println("TEST: index serial");
       indexSerial(docs, dir2);
       //System.out.println("TEST: verify");
@@ -193,12 +195,14 @@ public class TestStressIndexing2 extends
     return dw;
   }
   
-  public Map<String,Document> indexRandom(int nThreads, int iterations, int range,
Directory dir, int maxThreadStates) throws IOException, InterruptedException {
+  public Map<String,Document> indexRandom(int nThreads, int iterations, int range,
Directory dir, int maxThreadStates,
+                                          boolean doReaderPooling) throws IOException, InterruptedException
{
     Map<String,Document> docs = new HashMap<String,Document>();
     for(int iter=0;iter<3;iter++) {
       IndexWriter w = new MockIndexWriter(dir, new IndexWriterConfig(
           TEST_VERSION_CURRENT, new WhitespaceAnalyzer(TEST_VERSION_CURRENT)).setOpenMode(OpenMode.CREATE)
-               .setRAMBufferSizeMB(0.1).setMaxBufferedDocs(maxBufferedDocs).setMaxThreadStates(maxThreadStates));
+               .setRAMBufferSizeMB(0.1).setMaxBufferedDocs(maxBufferedDocs).setMaxThreadStates(maxThreadStates)
+               .setReaderPooling(doReaderPooling));
       LogMergePolicy lmp = (LogMergePolicy) w.getConfig().getMergePolicy();
       lmp.setUseCompoundFile(false);
       lmp.setUseCompoundDocStore(false);

Propchange: lucene/java/branches/flex_1458/src/test/org/apache/lucene/util/TestAttributeSource.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Mar 23 19:36:47 2010
@@ -1,3 +1,4 @@
 /lucene/dev/trunk/lucene/src/test/org/apache/lucene/util/TestAttributeSource.java:926653
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/util/TestAttributeSource.java:909334
 /lucene/java/trunk/src/test/org/apache/lucene/util/TestAttributeSource.java:916596,916685,916755,916769,917019,917148,917154,917161,917203-917204,919060,919119,919718,919731,919869,920237-920499,922013,922277,922525,922528,922583,922593,922602,922624,922797,922799,922806,922886-922887,923112,923238,924151,924207,924286,924321-924731,924781,925176-925462
+/lucene/solr/branches/newtrunk/lucene/src/test/org/apache/lucene/util/TestAttributeSource.java:926020-926289



Mime
View raw message