lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Tim Smith (JIRA)" <>
Subject [jira] Created: (LUCENE-2501) ArrayIndexOutOfBoundsException in ByteBlockPool.allocSlice
Date Wed, 16 Jun 2010 16:40:23 GMT
ArrayIndexOutOfBoundsException in ByteBlockPool.allocSlice

                 Key: LUCENE-2501
             Project: Lucene - Java
          Issue Type: Bug
          Components: Index
    Affects Versions: 3.0.1
            Reporter: Tim Smith

I'm seeing the following exception during indexing:
Caused by: java.lang.ArrayIndexOutOfBoundsException: 14
at org.apache.lucene.index.ByteBlockPool.allocSlice(
at org.apache.lucene.index.TermsHashPerField.writeByte(
at org.apache.lucene.index.TermsHashPerField.writeVInt(
at org.apache.lucene.index.FreqProxTermsWriterPerField.writeProx(
at org.apache.lucene.index.FreqProxTermsWriterPerField.newTerm(
at org.apache.lucene.index.TermsHashPerField.add(
at org.apache.lucene.index.DocInverterPerField.processFields(
at org.apache.lucene.index.DocFieldProcessorPerThread.processDocument(
at org.apache.lucene.index.DocumentsWriter.updateDocument(
at org.apache.lucene.index.DocumentsWriter.updateDocument(
at org.apache.lucene.index.IndexWriter.updateDocument(
... 37 more

This seems to be caused by the following code:
    final int level = slice[upto] & 15;
    final int newLevel = nextLevelArray[level];
    final int newSize = levelSizeArray[newLevel];

this can result in "level" being a value between 0 and 14
the array nextLevelArray is only of size 10

i suspect the solution would be to either max the level to 10, or to add more entries to the
nextLevelArray so it has 15 entries
however, i don't know if something more is going wrong here and this is just where the exception
hits from a deeper issue

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message