Is epoch a Date?  or a String?  If a String, what format is it?

Sorting by a Date keyword field will be sorting as a String value, which is a fair bit more resource intensive than if it was numeric.

Try using a purely numeric field (though as a String) that can be represented as an int be sure to specify the sort type as an int and see if that improves performance. I'm pretty certain you'd still get better performance by using a boost than a sort though.

        Erik

On Mar 17, 2005, at 8:59 AM, Michael Celona wrote:

I am sorting against an epoch time stored in my index. By using:

contactDocument.add( Field.Keyword( "epoch_time", epoch );

Then I sort by this field. My search time is in the order of 3sec on an
index of about 6G using simple searches against a text field. By using
boosts I was hoping to increase performance. Do you think this will make a
big difference?


        Michael

-----Original Message-----
From: Erik Hatcher [mailto:[EMAIL PROTECTED]
Sent: Tuesday, March 15, 2005 8:43 AM
To: java-user@lucene.apache.org
Subject: Re: search performace

I've been effectively off-line for a few days, so I'm not sure if
anyone has replied on this thread yet.

Using boosts will definitely use less resources than sorting.  If you
do use sorting for dates, be sure you're doing it numerically rather
than lexicographically.

        Erik

On Mar 10, 2005, at 8:45 AM, Michael Celona wrote:

I have a large index that needs to yield very fast query times.  I am
sorting by date as default since I am interested in the most recent
documents.  I was wondering if I boosted the score of my documents in
proportion to the date and not sorting would this increase search
performance. Thoughts?



Thanks,

Michael



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to