jackrabbit-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mreut...@apache.org
Subject svn commit: r598940 - in /jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene: IndexMerger.java SearchIndex.java
Date Wed, 28 Nov 2007 10:23:20 GMT
Author: mreutegg
Date: Wed Nov 28 02:23:16 2007
New Revision: 598940

URL: http://svn.apache.org/viewvc?rev=598940&view=rev
Log:
JCR-1238: Change default value for maxMergeDocs

Modified:
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/IndexMerger.java
    jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/SearchIndex.java

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/IndexMerger.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/IndexMerger.java?rev=598940&r1=598939&r2=598940&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/IndexMerger.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/IndexMerger.java
Wed Nov 28 02:23:16 2007
@@ -135,8 +135,8 @@
         synchronized (lock) {
             // initially create buckets
             if (indexBuckets.size() == 0) {
-                int lower = 0;
-                int upper = minMergeDocs;
+                long lower = 0;
+                long upper = minMergeDocs;
                 while (upper < maxMergeDocs) {
                     indexBuckets.add(new IndexBucket(lower, upper, true));
                     lower = upper + 1;
@@ -145,7 +145,7 @@
                 // one with upper = maxMergeDocs
                 indexBuckets.add(new IndexBucket(lower, maxMergeDocs, false));
                 // and another one as overflow, just in case...
-                indexBuckets.add(new IndexBucket(maxMergeDocs + 1, Integer.MAX_VALUE, false));
+                indexBuckets.add(new IndexBucket(maxMergeDocs + 1, Long.MAX_VALUE, false));
             }
 
             // put index in bucket
@@ -451,12 +451,12 @@
         /**
          * The lower document limit.
          */
-        private final int lower;
+        private final long lower;
 
         /**
          * The upper document limit.
          */
-        private final int upper;
+        private final long upper;
 
         /**
          * Flag indicating if indexes in this bucket can be merged.
@@ -470,7 +470,7 @@
          * @param upper document limit.
          * @param allowMerge if indexes in this bucket can be merged.
          */
-        IndexBucket(int lower, int upper, boolean allowMerge) {
+        IndexBucket(long lower, long upper, boolean allowMerge) {
             this.lower = lower;
             this.upper = upper;
             this.allowMerge = allowMerge;
@@ -483,7 +483,7 @@
          * @param numDocs the number of documents.
          * @return <code>true</code> if <code>numDocs</code> fit.
          */
-        boolean fits(int numDocs) {
+        boolean fits(long numDocs) {
             return numDocs >= lower && numDocs <= upper;
         }
 

Modified: jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/SearchIndex.java
URL: http://svn.apache.org/viewvc/jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/SearchIndex.java?rev=598940&r1=598939&r2=598940&view=diff
==============================================================================
--- jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/SearchIndex.java
(original)
+++ jackrabbit/trunk/jackrabbit-core/src/main/java/org/apache/jackrabbit/core/query/lucene/SearchIndex.java
Wed Nov 28 02:23:16 2007
@@ -115,7 +115,7 @@
     /**
      * The default value for property {@link #maxMergeDocs}.
      */
-    public static final int DEFAULT_MAX_MERGE_DOCS = 100000;
+    public static final int DEFAULT_MAX_MERGE_DOCS = Integer.MAX_VALUE;
 
     /**
      * the default value for property {@link #mergeFactor}.



Mime
View raw message