mirror of https://github.com/apache/lucene.git
Fix for bug #32847. Use uncached access to norms when merging to
minimize RAM usage. git-svn-id: https://svn.apache.org/repos/asf/lucene/java/trunk@151390 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
f19e0f7bcc
commit
bfffc32a3d
17
CHANGES.txt
17
CHANGES.txt
|
@ -140,16 +140,21 @@ Optimizations
|
|||
of 0 now run 20-50% faster (Patch #31882).
|
||||
(Jonathan Hager via Daniel Naber)
|
||||
|
||||
6. A Version of BooleanScorer (BooleanScorer2) added that delivers documents
|
||||
in increasing order and implements skipTo. For queries with required or forbidden
|
||||
clauses it may be faster than the old BooleanScorer, for BooleanQueries consisting
|
||||
only of optional clauses it is probably slower. The new BooleanScorer is now the
|
||||
6. A Version of BooleanScorer (BooleanScorer2) added that delivers
|
||||
documents in increasing order and implements skipTo. For queries
|
||||
with required or forbidden clauses it may be faster than the old
|
||||
BooleanScorer, for BooleanQueries consisting only of optional
|
||||
clauses it is probably slower. The new BooleanScorer is now the
|
||||
default. (Patch 31785 by Paul Elschot via Christoph)
|
||||
|
||||
7. Use uncached access to norms when merging to reduce RAM usage.
|
||||
(Bug #32847). (Doug Cutting)
|
||||
|
||||
Infrastructure
|
||||
|
||||
1. Lucene's source code repository has converted from CVS to Subversion. The new
|
||||
repository is at http://svn.apache.org/repos/asf/lucene/java/trunk
|
||||
1. Lucene's source code repository has converted from CVS to
|
||||
Subversion. The new repository is at
|
||||
http://svn.apache.org/repos/asf/lucene/java/trunk
|
||||
|
||||
1.4.3
|
||||
|
||||
|
|
|
@ -392,12 +392,12 @@ final class SegmentMerger {
|
|||
try {
|
||||
for (int j = 0; j < readers.size(); j++) {
|
||||
IndexReader reader = (IndexReader) readers.elementAt(j);
|
||||
byte[] input = reader.norms(fi.name);
|
||||
int maxDoc = reader.maxDoc();
|
||||
byte[] input = new byte[maxDoc];
|
||||
reader.norms(fi.name, input, 0);
|
||||
for (int k = 0; k < maxDoc; k++) {
|
||||
byte norm = input != null ? input[k] : (byte) 0;
|
||||
if (!reader.isDeleted(k)) {
|
||||
output.writeByte(norm);
|
||||
output.writeByte(input[k]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue