lucene-java-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rm...@apache.org
Subject svn commit: r1028827 - in /lucene/java/branches/lucene_3_0: ./ contrib/ contrib/analyzers/ contrib/analyzers/common/ contrib/analyzers/common/src/test/ contrib/analyzers/smartcn/ contrib/highlighter/ contrib/highlighter/src/test/ contrib/instantiated/s...
Date Fri, 29 Oct 2010 16:37:10 GMT
Author: rmuir
Date: Fri Oct 29 16:37:09 2010
New Revision: 1028827

URL: http://svn.apache.org/viewvc?rev=1028827&view=rev
Log:
LUCENE-2658: fix case where exception on docs w/ more than one field w/ tvs could mess up
the ByteBlockPool

Modified:
    lucene/java/branches/lucene_3_0/   (props changed)
    lucene/java/branches/lucene_3_0/CHANGES.txt   (contents, props changed)
    lucene/java/branches/lucene_3_0/build.xml   (props changed)
    lucene/java/branches/lucene_3_0/contrib/   (props changed)
    lucene/java/branches/lucene_3_0/contrib/CHANGES.txt   (props changed)
    lucene/java/branches/lucene_3_0/contrib/analyzers/   (props changed)
    lucene/java/branches/lucene_3_0/contrib/analyzers/common/   (props changed)
    lucene/java/branches/lucene_3_0/contrib/analyzers/common/src/test/   (props changed)
    lucene/java/branches/lucene_3_0/contrib/analyzers/smartcn/   (props changed)
    lucene/java/branches/lucene_3_0/contrib/highlighter/   (props changed)
    lucene/java/branches/lucene_3_0/contrib/highlighter/src/test/   (props changed)
    lucene/java/branches/lucene_3_0/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/   (props changed)
    lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/analysis/BaseCharFilter.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/analysis/Tokenizer.java   (props
changed)
    lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/index/TermVectorsTermsWriterPerField.java
    lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/document/TestDateTools.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/document/TestNumberTools.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/   (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestIndexWriterExceptions.java
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/search/TestCachingWrapperFilter.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/search/spans/TestPayloadSpans.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/search/spans/TestSpans.java
  (props changed)
    lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/util/TestAttributeSource.java
  (props changed)

Propchange: lucene/java/branches/lucene_3_0/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4:748824
 /lucene/java/branches/lucene_2_9:817269-818600,825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests:818601-821336

Modified: lucene/java/branches/lucene_3_0/CHANGES.txt
URL: http://svn.apache.org/viewvc/lucene/java/branches/lucene_3_0/CHANGES.txt?rev=1028827&r1=1028826&r2=1028827&view=diff
==============================================================================
--- lucene/java/branches/lucene_3_0/CHANGES.txt (original)
+++ lucene/java/branches/lucene_3_0/CHANGES.txt Fri Oct 29 16:37:09 2010
@@ -51,6 +51,10 @@ Bug fixes
 * LUCENE-2384: Reset zzBuffer in StandardTokenizerImpl when lexer is reset.
   (Ruben Laguna via Uwe Schindler, sub-issue of LUCENE-2074) 
   
+* LUCENE-2658: Exceptions while processing term vectors enabled for multiple
+  fields could lead to invalid ArrayIndexOutOfBoundsExceptions.
+  (Robert Muir, Mike McCandless)
+
 Documentation
 
 * LUCENE-2239: Documented limitations in NIOFSDirectory and MMapDirectory due 

Propchange: lucene/java/branches/lucene_3_0/CHANGES.txt
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/CHANGES.txt:941394,946651,948430,957490,984210
-/lucene/dev/trunk/lucene/CHANGES.txt:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,994979
+/lucene/dev/branches/branch_3x/lucene/CHANGES.txt:941394,946651,948430,957490,984210,999847
+/lucene/dev/trunk/lucene/CHANGES.txt:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,994979,999842
 /lucene/java/branches/lucene_2_4/CHANGES.txt:748824
 /lucene/java/branches/lucene_2_9/CHANGES.txt:817269-818600,825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/CHANGES.txt:818601-821336

Propchange: lucene/java/branches/lucene_3_0/build.xml
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/build.xml:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/build.xml:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/build.xml:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/build.xml:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/build.xml:748824
 /lucene/java/branches/lucene_2_9/build.xml:817269-818600,825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/build.xml:818601-821336

Propchange: lucene/java/branches/lucene_3_0/contrib/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/contrib:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/contrib:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/contrib:748824
 /lucene/java/branches/lucene_2_9/contrib:817269-818600,825998,829134,829816,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/contrib:818601-821336

Propchange: lucene/java/branches/lucene_3_0/contrib/CHANGES.txt
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/CHANGES.txt:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/contrib/CHANGES.txt:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/CHANGES.txt:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib/CHANGES.txt:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/contrib/CHANGES.txt:748824
 /lucene/java/branches/lucene_2_9/contrib/CHANGES.txt:817269-818600,825998,826775,829134,829816,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/contrib/CHANGES.txt:818601-821336

Propchange: lucene/java/branches/lucene_3_0/contrib/analyzers/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/analyzers:941394,946651,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/contrib/analyzers:929738,935522,939611,940730,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/analyzers:941394,946651,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib/analyzers:929738,935522,939611,940730,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/trunk/contrib/analyzers:887670,889579,889866,890439,891205,891377,916543,919869,920270

Propchange: lucene/java/branches/lucene_3_0/contrib/analyzers/common/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/analyzers/common:988629,990286,999226
-/lucene/dev/trunk/lucene/contrib/analyzers/common:984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/analyzers/common:988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib/analyzers/common:984187,989785,990281,994979,999223,999842
 /lucene/java/trunk/contrib/analyzers/common:916543,919869

Propchange: lucene/java/branches/lucene_3_0/contrib/analyzers/common/src/test/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/analyzers/common/src/test:999226
-/lucene/dev/trunk/lucene/contrib/analyzers/common/src/test:989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/analyzers/common/src/test:999226,999847
+/lucene/dev/trunk/lucene/contrib/analyzers/common/src/test:989785,990281,994979,999223,999842
 /lucene/java/trunk/contrib/analyzers/common/src/test:916543,919869

Propchange: lucene/java/branches/lucene_3_0/contrib/analyzers/smartcn/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/analyzers/smartcn:988629,990286,999226
-/lucene/dev/trunk/lucene/contrib/analyzers/smartcn:984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/analyzers/smartcn:988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib/analyzers/smartcn:984187,989785,990281,994979,999223,999842
 /lucene/java/trunk/contrib/analyzers/smartcn:916543,919869

Propchange: lucene/java/branches/lucene_3_0/contrib/highlighter/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/highlighter:988629,990286,999226
-/lucene/dev/trunk/lucene/contrib/highlighter:984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/highlighter:988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib/highlighter:984187,989785,990281,994979,999223,999842
 /lucene/java/trunk/contrib/highlighter:916543,919869

Propchange: lucene/java/branches/lucene_3_0/contrib/highlighter/src/test/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/highlighter/src/test:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/contrib/highlighter/src/test:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/highlighter/src/test:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib/highlighter/src/test:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/contrib/highlighter/src/test:748824
 /lucene/java/branches/lucene_2_9/contrib/highlighter/src/test:817269-818600,825998,826775,829134,829816,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/contrib/highlighter/src/test:818601-821336

Propchange: lucene/java/branches/lucene_3_0/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:748824
 /lucene/java/branches/lucene_2_9/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:817269-818600,825998,829134,829816,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/contrib/instantiated/src/test/org/apache/lucene/store/instantiated/TestIndicesEquals.java:818601-821336

Propchange: lucene/java/branches/lucene_3_0/src/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src:748824
 /lucene/java/branches/lucene_2_9/src:817269-818600,825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/src:818601-821336

Propchange: lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/analysis/BaseCharFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (added)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -0,0 +1 @@
+/lucene/dev/trunk/lucene/src/java/org/apache/lucene/analysis/BaseCharFilter.java:999842

Propchange: lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/analysis/Tokenizer.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src/java/org/apache/lucene/analysis/Tokenizer.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/java/org/apache/lucene/analysis/Tokenizer.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/java/org/apache/lucene/analysis/Tokenizer.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/java/org/apache/lucene/analysis/Tokenizer.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src/java/org/apache/lucene/analysis/Tokenizer.java:748824
 /lucene/java/branches/lucene_2_9/src/java/org/apache/lucene/analysis/Tokenizer.java:817269-818600,825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/src/java/org/apache/lucene/analysis/Tokenizer.java:818601-821336

Modified: lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/index/TermVectorsTermsWriterPerField.java
URL: http://svn.apache.org/viewvc/lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/index/TermVectorsTermsWriterPerField.java?rev=1028827&r1=1028826&r2=1028827&view=diff
==============================================================================
--- lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/index/TermVectorsTermsWriterPerField.java
(original)
+++ lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/index/TermVectorsTermsWriterPerField.java
Fri Oct 29 16:37:09 2010
@@ -76,14 +76,16 @@ final class TermVectorsTermsWriterPerFie
         assert perThread.doc.numVectorFields == 0;
         assert 0 == perThread.doc.perDocTvf.length();
         assert 0 == perThread.doc.perDocTvf.getFilePointer();
-      } else {
-        assert perThread.doc.docID == docState.docID;
+      }
+
+      assert perThread.doc.docID == docState.docID;
 
-        if (termsHashPerField.numPostings != 0)
-          // Only necessary if previous doc hit a
-          // non-aborting exception while writing vectors in
-          // this field:
-          termsHashPerField.reset();
+      if (termsHashPerField.numPostings != 0) {
+        // Only necessary if previous doc hit a
+        // non-aborting exception while writing vectors in
+        // this field:
+        termsHashPerField.reset();
+        perThread.termsHashPerThread.reset(false);
       }
     }
 
@@ -98,7 +100,7 @@ final class TermVectorsTermsWriterPerFie
   /** Called once per field per document if term vectors
    *  are enabled, to write the vectors to
    *  RAMOutputStream, which is then quickly flushed to
-   *  * the real term vectors files in the Directory. */
+   *  the real term vectors files in the Directory. */
   @Override
   void finish() throws IOException {
 
@@ -189,6 +191,12 @@ final class TermVectorsTermsWriterPerFie
     }
 
     termsHashPerField.reset();
+
+    // NOTE: we clear, per-field, at the thread level,
+    // because term vectors fully write themselves on each
+    // field; this saves RAM (eg if large doc has two large
+    // fields w/ term vectors on) because we recycle/reuse
+    // all RAM after each field:
     perThread.termsHashPerThread.reset(false);
   }
 

Propchange: lucene/java/branches/lucene_3_0/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:748824
 /lucene/java/branches/lucene_2_9/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:817269-818600,825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/src/java/org/apache/lucene/search/MultiTermQueryWrapperFilter.java:818601-821336

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:748824
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/trunk/src/test/org/apache/lucene/analysis/TestISOLatin1AccentFilter.java:881213,881315,881466,881819,882374,882672,882807,882888,882977,883074-883075,883554,884870,886257,886911,887347,887532,887602,887670,888247,889431-889432,889579,889866,890439,890967,890988,891189,891205,891209,891363,891377,893093,894348,897672,899627,900196,908477,908975,909360,909398,910034,910078,912407,915399,916543,919060,919869,920270

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/document/TestDateTools.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/document/TestDateTools.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/document/TestDateTools.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/document/TestDateTools.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/document/TestDateTools.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src/test/org/apache/lucene/document/TestDateTools.java:748824
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/document/TestDateTools.java:825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/trunk/src/test/org/apache/lucene/document/TestDateTools.java:881213,881315,881466,881819,882374,882672,882807,882888,882977,883074-883075,883554,884870,886257,886911,887347,887532,887602,887670,888247,889431-889432,889579,889866,890439,890967,890988,891189,891205,891209,891363,891377,893093,894348,897672,899627,900196,908477,908975,909360,909398,910034,910078,912407,915399,916543,919060,919869,920270

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/document/TestNumberTools.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/document/TestNumberTools.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/document/TestNumberTools.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/document/TestNumberTools.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/document/TestNumberTools.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src/test/org/apache/lucene/document/TestNumberTools.java:748824
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/document/TestNumberTools.java:825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/trunk/src/test/org/apache/lucene/document/TestNumberTools.java:881213,881315,881466,881819,882374,882672,882807,882888,882977,883074-883075,883554,884870,886257,886911,887347,887532,887602,887670,888247,889431-889432,889579,889866,890439,890967,890988,891189,891205,891209,891363,891377,893093,894348,897672,899627,900196,908477,908975,909360,909398,910034,910078,912407,915399,916543,919060,919869,920270

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/index:941394,946651,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/index:929738,935522,940730,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/index:941394,946651,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/index:929738,935522,940730,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/trunk/src/test/org/apache/lucene/index:887670,889579,889866,890439,891205,891377,916543,919869,920270

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:748824
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/trunk/src/test/org/apache/lucene/index/TestBackwardsCompatibility.java:881213,881315,881466,881819,882374,882672,882807,882888,882977,883074-883075,883554,884870,886257,886911,887347,887532,887602,887670,888247,889431-889432,889579,889866,890439,890967,890988,891189,891205,891209,891363,891377,893093,894348,897672,899627,900196,908477,908975,909360,909398,910034,910078,912407,915399,916543,919060,919869,920270

Modified: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestIndexWriterExceptions.java
URL: http://svn.apache.org/viewvc/lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestIndexWriterExceptions.java?rev=1028827&r1=1028826&r2=1028827&view=diff
==============================================================================
--- lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestIndexWriterExceptions.java
(original)
+++ lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/index/TestIndexWriterExceptions.java
Fri Oct 29 16:37:09 2010
@@ -28,11 +28,21 @@ import org.apache.lucene.analysis.Analyz
 import org.apache.lucene.analysis.WhitespaceAnalyzer;
 import org.apache.lucene.document.Document;
 import org.apache.lucene.document.Field;
+import org.apache.lucene.document.Field.TermVector;
 
 public class TestIndexWriterExceptions extends LuceneTestCase {
-
+  Random random;
   final private static boolean DEBUG = false;
-
+  
+  static final TermVector tvSettings[] = { 
+    TermVector.NO, TermVector.YES, TermVector.WITH_OFFSETS, 
+    TermVector.WITH_POSITIONS, TermVector.WITH_POSITIONS_OFFSETS 
+  };
+  
+  private TermVector randomTVSetting(Random random) {
+    return tvSettings[random.nextInt(tvSettings.length)];
+  }
+  
   private class IndexerThread extends Thread {
 
     IndexWriter writer;
@@ -50,17 +60,17 @@ public class TestIndexWriterExceptions e
 
       final Document doc = new Document();
 
-      doc.add(new Field("content1", "aaa bbb ccc ddd", Field.Store.YES, Field.Index.ANALYZED));
-      doc.add(new Field("content6", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.ANALYZED,
Field.TermVector.WITH_POSITIONS_OFFSETS));
-      doc.add(new Field("content2", "aaa bbb ccc ddd", Field.Store.YES, Field.Index.NOT_ANALYZED));
+      doc.add(new Field("content1", "aaa bbb ccc ddd", Field.Store.YES, Field.Index.ANALYZED,
randomTVSetting(random)));
+      doc.add(new Field("content6", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.ANALYZED,
randomTVSetting(random)));
+      doc.add(new Field("content2", "aaa bbb ccc ddd", Field.Store.YES, Field.Index.NOT_ANALYZED,
randomTVSetting(random)));
       doc.add(new Field("content3", "aaa bbb ccc ddd", Field.Store.YES, Field.Index.NO));
 
-      doc.add(new Field("content4", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.ANALYZED));
-      doc.add(new Field("content5", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.NOT_ANALYZED));
+      doc.add(new Field("content4", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.ANALYZED,
randomTVSetting(random)));
+      doc.add(new Field("content5", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.NOT_ANALYZED,
randomTVSetting(random)));
 
-      doc.add(new Field("content7", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.NOT_ANALYZED,
Field.TermVector.WITH_POSITIONS_OFFSETS));
+      doc.add(new Field("content7", "aaa bbb ccc ddd", Field.Store.NO, Field.Index.NOT_ANALYZED,
randomTVSetting(random)));
 
-      final Field idField = new Field("id", "", Field.Store.YES, Field.Index.NOT_ANALYZED);
+      final Field idField = new Field("id", "", Field.Store.YES, Field.Index.NOT_ANALYZED,
randomTVSetting(random));
       doc.add(idField);
 
       final long stopTime = System.currentTimeMillis() + 3000;
@@ -74,7 +84,7 @@ public class TestIndexWriterExceptions e
           writer.updateDocument(idTerm, doc);
         } catch (RuntimeException re) {
           if (DEBUG) {
-            System.out.println("EXC: ");
+            System.out.println(Thread.currentThread().getName() + ": EXC: ");
             re.printStackTrace(System.out);
           }
           try {
@@ -134,6 +144,7 @@ public class TestIndexWriterExceptions e
   public void testRandomExceptions() throws Throwable {
     MockRAMDirectory dir = new MockRAMDirectory();
 
+    random = newRandom();
     MockIndexWriter writer  = new MockIndexWriter(dir, new WhitespaceAnalyzer(), true, IndexWriter.MaxFieldLength.LIMITED);
     ((ConcurrentMergeScheduler) writer.getMergeScheduler()).setSuppressExceptions();
     //writer.setMaxBufferedDocs(10);
@@ -171,6 +182,7 @@ public class TestIndexWriterExceptions e
 
   public void testRandomExceptionsThreads() throws Throwable {
 
+    random = newRandom();
     MockRAMDirectory dir = new MockRAMDirectory();
     MockIndexWriter writer  = new MockIndexWriter(dir, new WhitespaceAnalyzer(), true, IndexWriter.MaxFieldLength.LIMITED);
     ((ConcurrentMergeScheduler) writer.getMergeScheduler()).setSuppressExceptions();

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/search/TestCachingWrapperFilter.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/search/TestCachingWrapperFilter.java:999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/search/TestCachingWrapperFilter.java:989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/search/TestCachingWrapperFilter.java:999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/search/TestCachingWrapperFilter.java:989785,990281,994979,999223,999842
 /lucene/java/trunk/src/test/org/apache/lucene/search/TestCachingWrapperFilter.java:916543,919869

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/search/spans/TestPayloadSpans.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/search/spans/TestPayloadSpans.java:999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/search/spans/TestPayloadSpans.java:989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/search/spans/TestPayloadSpans.java:999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/search/spans/TestPayloadSpans.java:989785,990281,994979,999223,999842
 /lucene/java/trunk/src/test/org/apache/lucene/search/spans/TestPayloadSpans.java:916543,919869

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/search/spans/TestSpans.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,3 +1,3 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/search/spans/TestSpans.java:999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/search/spans/TestSpans.java:989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/search/spans/TestSpans.java:999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/search/spans/TestSpans.java:989785,990281,994979,999223,999842
 /lucene/java/trunk/src/test/org/apache/lucene/search/spans/TestSpans.java:916543,919869

Propchange: lucene/java/branches/lucene_3_0/src/test/org/apache/lucene/util/TestAttributeSource.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Fri Oct 29 16:37:09 2010
@@ -1,5 +1,5 @@
-/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/util/TestAttributeSource.java:941394,946651,948430,957490,984210,988629,990286,999226
-/lucene/dev/trunk/lucene/src/test/org/apache/lucene/util/TestAttributeSource.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223
+/lucene/dev/branches/branch_3x/lucene/src/test/org/apache/lucene/util/TestAttributeSource.java:941394,946651,948430,957490,984210,988629,990286,999226,999847
+/lucene/dev/trunk/lucene/src/test/org/apache/lucene/util/TestAttributeSource.java:929738,932398,935522,938989,939611,939649,940730,945420,946599,948082,948429,949288,949976,949997,950458,950613,951521,953407,963781,965103,984187,989785,990281,994979,999223,999842
 /lucene/java/branches/lucene_2_4/src/test/org/apache/lucene/util/TestAttributeSource.java:748824
 /lucene/java/branches/lucene_2_9/src/test/org/apache/lucene/util/TestAttributeSource.java:817269-818600,825998,829134,829881,831036,896850,909334,940987,948516
 /lucene/java/branches/lucene_2_9_back_compat_tests/src/test/org/apache/lucene/util/TestAttributeSource.java:818601-821336



Mime
View raw message