Enable TermVectors for fields that you're going tot highlight. If it is 
disabled Solr will reanalyze the field, killing performance.

> I looked into the search that I'm doing a little closer and it seems
> like the highlighting is slowing it down. If I do the query without
> requesting highlighting it is fast. (BTW, I also have faceting and
> pagination in my query. Faceting doesn't seem to change the response
> time much, adding &rows= and &start= does, but not prohibitively.)
> 
> The field in question needs to be stored=true, because it is needed
> for highlighting.
> 
> I'm thinking of doing this in two searches: first without highlighting
> and put a progress spinner next to each result, then do an ajax call
> to repeat the search with highlighting that can take its time to
> finish.
> 
> (I, too, have seen random really long response times that seem to be
> related to not enough RAM, but this isn't the problem because the
> results here are repeatable.)
> 
> On Wed, Mar 23, 2011 at 2:30 PM, Sascha Szott <sz...@zib.de> wrote:
> > On 23.03.2011 18:52, Paul wrote:
> >> I increased maxFieldLength and reindexed a small number of documents.
> >> That worked -- I got the correct results. In 3 minutes!
> > 
> > Did you mark the field in question as stored = false?
> > 
> > -Sascha
> > 
> >> I assume that if I reindex all my documents that all searches will
> >> become even slower. Is there any way to get all the results in a way
> >> that is quick enough that my user won't get bored waiting? Is there
> >> some optimization of this coming in solr 3.0?
> >> 
> >> On Wed, Mar 23, 2011 at 12:15 PM, Sascha Szott<sz...@zib.de>  wrote:
> >>> Hi Paul,
> >>> 
> >>> did you increase the value of the maxFieldLength parameter in your
> >>> solrconfig.xml?
> >>> 
> >>> -Sascha
> >>> 
> >>> On 23.03.2011 17:05, Paul wrote:
> >>>> I'm using solr 1.4.1.
> >>>> 
> >>>> I have a document that has a pretty big field. If I search for a
> >>>> phrase that occurs near the start of that field, it works fine. If I
> >>>> search for a phrase that appears even a little ways into the field, it
> >>>> doesn't find it. Is there some limit to how far into a field solr will
> >>>> search?
> >>>> 
> >>>> Here's the way I'm doing the search. All I'm changing is the text I'm
> >>>> searching on to make it succeed or fail:
> >>>> 
> >>>> 
> >>>> 
> >>>> http://localhost:8983/solr/my_core/select/?q=%22search+phrase%22&hl=on
> >>>> &hl.fl=text
> >>>> 
> >>>> Or, if it is not related to how large the document is, what else could
> >>>> it possibly be related to? Could there be some character in that field
> >>>> that is stopping the search?

Reply via email to