You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-commits@lucene.apache.org by mi...@apache.org on 2007/10/10 14:26:18 UTC

svn commit: r583450 - /lucene/java/trunk/src/java/org/apache/lucene/index/IndexWriter.java

Author: mikemccand
Date: Wed Oct 10 05:26:18 2007
New Revision: 583450

URL: http://svn.apache.org/viewvc?rev=583450&view=rev
Log:
add NOTE that the input Directory[] to addIndexes* must not be opened by a writer while the method is running

Modified:
    lucene/java/trunk/src/java/org/apache/lucene/index/IndexWriter.java

Modified: lucene/java/trunk/src/java/org/apache/lucene/index/IndexWriter.java
URL: http://svn.apache.org/viewvc/lucene/java/trunk/src/java/org/apache/lucene/index/IndexWriter.java?rev=583450&r1=583449&r2=583450&view=diff
==============================================================================
--- lucene/java/trunk/src/java/org/apache/lucene/index/IndexWriter.java (original)
+++ lucene/java/trunk/src/java/org/apache/lucene/index/IndexWriter.java Wed Oct 10 05:26:18 2007
@@ -2005,6 +2005,12 @@
    * complete index can then be created by merging sub-collection indexes
    * with this method.
    *
+   * <p><b>NOTE:</b> the index in each Directory must not be
+   * changed (opened by a writer) while this method is
+   * running.  This method does not acquire a write lock in
+   * each input Directory, so it is up to the caller to
+   * enforce this.
+   *
    * <p>After this completes, the index is optimized.
    *
    * <p>This method is transactional in how Exceptions are
@@ -2089,6 +2095,13 @@
    * This is similar to addIndexes(Directory[]). However, no optimize()
    * is called either at the beginning or at the end. Instead, merges
    * are carried out as necessary.
+   *
+   * <p><b>NOTE:</b> the index in each Directory must not be
+   * changed (opened by a writer) while this method is
+   * running.  This method does not acquire a write lock in
+   * each input Directory, so it is up to the caller to
+   * enforce this.
+   *
    * <p>
    * This requires this index not be among those to be added, and the
    * upper bound* of those segment doc counts not exceed maxMergeDocs.