On Tue, 11 Dec 2007, Timo Nentwig wrote:
Date: Tue, 11 Dec 2007 13:27:59 +0100
From: Timo Nentwig <[EMAIL PROTECTED]>
Reply-To: java-dev@lucene.apache.org
To: java-dev@lucene.apache.org
Subject: Caching FuzzyQuery
Hi!
Actually FuzzyQuery.rewrite() is pretty expensive so why not introduce a
c
: I'm against caching in general because you always run into some hard to
: understand and examine problem but this seems to be one of the rare cases
: where caching makes sense.
For you maybe, but i've actually seen very few instances in practice where
people who are speed concious use FuzzyQ
: > Hoss means calling rewrite on the *result* of a rewrite.
:
: Uh? That's what I mean (propose), too... But currently nothing's cached at
: all.
:
: Cache the result (BooleanQuery) of rewrite() in a WeakHashMap with key =
: IndexReader and value = LRU.
yes .. you can do that. you don't nee
On Saturday 15 December 2007 20:48:38 Yonik Seeley wrote:
> On Dec 15, 2007 2:23 PM, Timo Nentwig <[EMAIL PROTECTED]> wrote:
> > On Saturday 15 December 2007 00:17:10 Chris Hostetter wrote:
> > > : Actually FuzzyQuery.rewrite() is pretty expensive so why not
> > > : introduce a caching decorator? A
On Dec 15, 2007 2:23 PM, Timo Nentwig <[EMAIL PROTECTED]> wrote:
> On Saturday 15 December 2007 00:17:10 Chris Hostetter wrote:
> > : Actually FuzzyQuery.rewrite() is pretty expensive so why not introduce a
> > : caching decorator? A WeakHashMap with key==IndexReader and value==LRU of
> > : Boolean
On Saturday 15 December 2007 00:17:10 Chris Hostetter wrote:
> : Actually FuzzyQuery.rewrite() is pretty expensive so why not introduce a
> : caching decorator? A WeakHashMap with key==IndexReader and value==LRU of
> : BooleanQueries.
>
> Applications are certainly welcome to do this (there is noth
: Actually FuzzyQuery.rewrite() is pretty expensive so why not introduce a
: caching decorator? A WeakHashMap with key==IndexReader and value==LRU of
: BooleanQueries.
Applications are certainly welcome to do this (there is nothing to stop
you from calling rewrite before passing the query to y