lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pranav Prakash <>
Subject Highlighting uses lots of memory and eventually slows down Solr
Date Fri, 09 Dec 2011 08:41:32 GMT
Hi Group,

I would like to have highlighting for search and I have the fields indexed
with the following schema (Solr 3.4)

<fieldType name="text_commongrams" class="solr.TextField">
<charFilter class="solr.HTMLStripCharFilterFactory"/>
<tokenizer class="solr.StandardTokenizerFactory"/>
<filter class="solr.RemoveDuplicatesTokenFilterFactory"/>
<filter class="solr.TrimFilterFactory"/>
<filter class="solr.LowerCaseFilterFactory"/>
<filter class="solr.SnowballPorterFilterFactory" language="English"
<filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase
="true" expand="true"/>
<filter class="solr.CommonGramsFilterFactory" words="stopwords_en.txt"
<filter class="solr.StopFilterFactory" words="stopwords_en.txt" ignoreCase="
<filter class="solr.WordDelimiterFilterFactory" generateWordParts="1"
generateNumberParts="1" catenateWords="1" catenateNumbers="1" catenateAll="0

<field name="transcript" type="text_commongrams" indexed="true" stored="true
" termVectors="true" termPositions="true" termOffsets="true"/>

<dynamicField name="*_en" type="text_commongrams" indexed="true" stored="
true" termVectors="true" termPositions="true" termOffsets="true"/>

And the following config

 <fragmenter name="gap" class="org.apache.solr.highlight.GapFragmenter"
 <lst name="defaults">
<int name="hl.fragsize">100</int>
<fragmenter name="regex" class="org.apache.solr.highlight.RegexFragmenter">
 <lst name="defaults">
<int name="hl.fragsize">20</int>
<float name="hl.regex.slop">0.5</float>
<str name="hl.regex.pattern">[-\w ,/\n\"']{20,200}</str>
<formatter name="html" class="org.apache.solr.highlight.HtmlFormatter"
 <lst name="defaults">
 <str name="hl.simple.pre">
<![CDATA[ <strong> ]]>
<str name="">
<![CDATA[ </strong> ]]>

The problem is that when I turn on highlighting, I face memory issues. The
Memory usage on system goes higher and higher until it consumes all the
memory (I dont receive OOM errors, there is always like 300 MB free
memory). The total memory I have is 48GiB. My Index size is 138GiB and
there are about 10m documents in the index.

I also get the following warning, but I am not sure how to get it done.

WARNING: Deprecated syntax found. <highlighting/> should move to

My Solr log with highlighting turned on looks something like this

[core0] webapp=/solr path=/select

Any help on this would be greatly appreciated. Thanks in advance !!

*Pranav Prakash*

"temet nosce"

Twitter <> | Blog <> |
Google <>

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