lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Michael McCandless (JIRA)" <j...@apache.org>
Subject [jira] Updated: (LUCENE-985) AIOOB thrown when length of termText is longer than 16384 characters (ArrayIndexOutOfBoundsException)
Date Sat, 18 Aug 2007 00:56:30 GMT

     [ https://issues.apache.org/jira/browse/LUCENE-985?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Michael McCandless updated LUCENE-985:
--------------------------------------

    Attachment: LUCENE-985.patch

> I doubt anyone will have a problem with the limit. And if they hit
> the exception it is probably due to bad end-user input of some
> kind. I always run a token filter that leaves out any token larger
> than 250 charachters or so, depending on the application. (It was
> quite accidential that I hit this AIOOBE.)

Agreed!

> That would also be a recommendation I think makes sense in the
> documentation people will look up when hitting the exception.

I've added a blurb in javadoc for IndexWriter.addDocument explaining
this limit.

Thanks for catching this Karl!

> AIOOB thrown when length of termText is longer than 16384 characters (ArrayIndexOutOfBoundsException)
> -----------------------------------------------------------------------------------------------------
>
>                 Key: LUCENE-985
>                 URL: https://issues.apache.org/jira/browse/LUCENE-985
>             Project: Lucene - Java
>          Issue Type: Bug
>          Components: Index
>    Affects Versions: 2.3
>            Reporter: Michael McCandless
>            Assignee: Michael McCandless
>            Priority: Minor
>             Fix For: 2.3
>
>         Attachments: LUCENE-985.patch
>
>
> DocumentsWriter has a max term length of 16384; if you cross that you
> get an unfriendly ArrayIndexOutOfBoundsException.  We should fix to raise a clearer exception.

-- 
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: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org


Mime
View raw message