lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Erick Erickson" <>
Subject Re: Reading field parameters from XML
Date Thu, 03 Jan 2008 13:01:23 GMT
Do you have any evidence at all that this is worth the effort? I assume
that you're worried about efficiency. In my experience, this is *very*
often a mis-placed concern. And "efficient" code that saves, say,
even 1% of my run time is *not* worth the hours/days/weeks spent
creating and *maintaining* clever code......

Do the simple thing. Then if your application is unacceptably slow,
put a profiler on it and fix what's *really* slow. I can't tell you how
I've been sure that I knew where the bottleneck is only to find that
my problem is somewhere completely different.


On Jan 3, 2008 12:33 AM, Michael Mitiaguin <> wrote:

> I want to keep index parameters in XML.
> e.g.
>        <Field name="description" store="NO" index="TOKENIZED"
> termvector="WITH_OFFSETS" >
> May I avoid switch/case  , if/else in my code
> and assign somehow Field.Store, Field.Index  and etc...  based on string
> value.
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message