You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@nutch.apache.org by Gal Nitzan <gn...@usa.net> on 2006/01/04 02:00:37 UTC
NegativeArraySizeException in search server
When trying to use the search server I get.
I use the trunk from today...
060104 025549 13 Server handler 0 on 9004 call error:
java.io.IOException: java.lang.NegativeArraySizeException
java.io.IOException: java.lang.NegativeArraySizeException
at
org.apache.lucene.util.PriorityQueue.initialize(PriorityQueue.java:35)
at org.apache.lucene.search.HitQueue.<init>(HitQueue.java:23)
at
org.apache.lucene.search.TopDocCollector.<init>(TopDocCollector.java:47)
at org.apache.nutch.searcher.LuceneQueryOptimizer
$LimitedCollector.<init>(LuceneQueryOptimizer.java:52)
at
org.apache.nutch.searcher.LuceneQueryOptimizer.optimize(LuceneQueryOptimizer.java:153)
at
org.apache.nutch.searcher.IndexSearcher.search(IndexSearcher.java:93)
at
org.apache.nutch.searcher.NutchBean.search(NutchBean.java:155)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:324)
at org.apache.nutch.ipc.RPC$1.call(RPC.java:186)
at org.apache.nutch.ipc.Server$Handler.run(Server.java:200)
Re: [bug] Re: NegativeArraySizeException in search server
Posted by Doug Cutting <cu...@nutch.org>.
I just committed a fix for this. Thanks for diagnosing it!
I changed things so that hit limiting is entirely disabled when
searcher.max.hits is not positive.
Doug
Marko Bauhardt wrote:
> Hi,
> I got the same Exception. The cause of this exception is the default
> value of searcher.max.hits property in the nutch-default.xml. The
> default value is Integer.MAX_VALUE. But the class
> org.apache.lucene.util.PriorityQueue increment this max.value.
> The next number after Integer.MAX_VALUE is -2147483648. You must
> decrease the searcher.max.hits to fix this.
> But notice: The PriorityQueue use an Array of this size. If large a
> value is defined an OutOfMemoryException occurs.
> Any Ideas suggestion how to fix this?
>
> Marko
>
>
>
>
> Am 04.01.2006 um 02:00 schrieb Gal Nitzan:
>
>> When trying to use the search server I get.
>>
>> I use the trunk from today...
>>
>> 060104 025549 13 Server handler 0 on 9004 call error:
>> java.io.IOException: java.lang.NegativeArraySizeException
>> java.io.IOException: java.lang.NegativeArraySizeException
>> at
>> org.apache.lucene.util.PriorityQueue.initialize(PriorityQueue.java:35)
>> at org.apache.lucene.search.HitQueue.<init>(HitQueue.java:23)
>> at
>> org.apache.lucene.search.TopDocCollector.<init> (TopDocCollector.java:47)
>> at org.apache.nutch.searcher.LuceneQueryOptimizer
>> $LimitedCollector.<init>(LuceneQueryOptimizer.java:52)
>> at
>> org.apache.nutch.searcher.LuceneQueryOptimizer.optimize
>> (LuceneQueryOptimizer.java:153)
>> at
>> org.apache.nutch.searcher.IndexSearcher.search(IndexSearcher.java:93)
>> at
>> org.apache.nutch.searcher.NutchBean.search(NutchBean.java:155)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke
>> (NativeMethodAccessorImpl.java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke
>> (DelegatingMethodAccessorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:324)
>> at org.apache.nutch.ipc.RPC$1.call(RPC.java:186)
>> at org.apache.nutch.ipc.Server$Handler.run(Server.java:200)
>>
>>
>>
>
>
Re: [bug] Re: NegativeArraySizeException in search server
Posted by Gal Nitzan <gn...@usa.net>.
Yes correct. for a second I thought it was fixed :)
On Wed, 2006-01-04 at 10:57 +0100, Marko Bauhardt wrote:
> Hi,
> I got the same Exception. The cause of this exception is the default
> value of searcher.max.hits property in the nutch-default.xml. The
> default value is Integer.MAX_VALUE. But the class
> org.apache.lucene.util.PriorityQueue increment this max.value.
> The next number after Integer.MAX_VALUE is -2147483648. You must
> decrease the searcher.max.hits to fix this.
> But notice: The PriorityQueue use an Array of this size. If large a
> value is defined an OutOfMemoryException occurs.
> Any Ideas suggestion how to fix this?
>
> Marko
>
>
>
>
> Am 04.01.2006 um 02:00 schrieb Gal Nitzan:
>
> > When trying to use the search server I get.
> >
> > I use the trunk from today...
> >
> > 060104 025549 13 Server handler 0 on 9004 call error:
> > java.io.IOException: java.lang.NegativeArraySizeException
> > java.io.IOException: java.lang.NegativeArraySizeException
> > at
> > org.apache.lucene.util.PriorityQueue.initialize(PriorityQueue.java:35)
> > at org.apache.lucene.search.HitQueue.<init>(HitQueue.java:23)
> > at
> > org.apache.lucene.search.TopDocCollector.<init>
> > (TopDocCollector.java:47)
> > at org.apache.nutch.searcher.LuceneQueryOptimizer
> > $LimitedCollector.<init>(LuceneQueryOptimizer.java:52)
> > at
> > org.apache.nutch.searcher.LuceneQueryOptimizer.optimize
> > (LuceneQueryOptimizer.java:153)
> > at
> > org.apache.nutch.searcher.IndexSearcher.search(IndexSearcher.java:93)
> > at
> > org.apache.nutch.searcher.NutchBean.search(NutchBean.java:155)
> > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> > at
> > sun.reflect.NativeMethodAccessorImpl.invoke
> > (NativeMethodAccessorImpl.java:39)
> > at
> > sun.reflect.DelegatingMethodAccessorImpl.invoke
> > (DelegatingMethodAccessorImpl.java:25)
> > at java.lang.reflect.Method.invoke(Method.java:324)
> > at org.apache.nutch.ipc.RPC$1.call(RPC.java:186)
> > at org.apache.nutch.ipc.Server$Handler.run(Server.java:200)
> >
> >
> >
>
[bug] Re: NegativeArraySizeException in search server
Posted by Marko Bauhardt <mb...@media-style.com>.
Hi,
I got the same Exception. The cause of this exception is the default
value of searcher.max.hits property in the nutch-default.xml. The
default value is Integer.MAX_VALUE. But the class
org.apache.lucene.util.PriorityQueue increment this max.value.
The next number after Integer.MAX_VALUE is -2147483648. You must
decrease the searcher.max.hits to fix this.
But notice: The PriorityQueue use an Array of this size. If large a
value is defined an OutOfMemoryException occurs.
Any Ideas suggestion how to fix this?
Marko
Am 04.01.2006 um 02:00 schrieb Gal Nitzan:
> When trying to use the search server I get.
>
> I use the trunk from today...
>
> 060104 025549 13 Server handler 0 on 9004 call error:
> java.io.IOException: java.lang.NegativeArraySizeException
> java.io.IOException: java.lang.NegativeArraySizeException
> at
> org.apache.lucene.util.PriorityQueue.initialize(PriorityQueue.java:35)
> at org.apache.lucene.search.HitQueue.<init>(HitQueue.java:23)
> at
> org.apache.lucene.search.TopDocCollector.<init>
> (TopDocCollector.java:47)
> at org.apache.nutch.searcher.LuceneQueryOptimizer
> $LimitedCollector.<init>(LuceneQueryOptimizer.java:52)
> at
> org.apache.nutch.searcher.LuceneQueryOptimizer.optimize
> (LuceneQueryOptimizer.java:153)
> at
> org.apache.nutch.searcher.IndexSearcher.search(IndexSearcher.java:93)
> at
> org.apache.nutch.searcher.NutchBean.search(NutchBean.java:155)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke
> (NativeMethodAccessorImpl.java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke
> (DelegatingMethodAccessorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:324)
> at org.apache.nutch.ipc.RPC$1.call(RPC.java:186)
> at org.apache.nutch.ipc.Server$Handler.run(Server.java:200)
>
>
>