This commit is contained in:
Tim McIver
2013-01-03 10:45:44 -05:00
3 changed files with 15 additions and 15 deletions
@@ -209,7 +209,9 @@
<fieldType name="text_ws" class="solr.TextField" positionIncrementGap="100">
<analyzer>
<tokenizer class="solr.WhitespaceTokenizerFactory"/>
<filter class="solr.LimitTokenCountFilterFactory" maxTokenCount="foo" foo="100000"/>
<!-- workaround to bug in Solr 4.0 to set LimitTokenCountFilterFactory maxTokenCount, might change to single attribute in future -->
<!-- 200000 token limit ensures we are indexing entire 1MB chunk of meaningful tokens, increase the limit for larger chunks -->
<filter class="solr.LimitTokenCountFilterFactory" maxTokenCount="val" val="200000"/>
</analyzer>
</fieldType>
@@ -221,8 +223,8 @@
<fieldType name="text_general" class="solr.TextField" positionIncrementGap="100">
<analyzer type="index">
<tokenizer class="solr.StandardTokenizerFactory"/>
<!-- workaround to bug in Solr 4.0 to set LimitTokenCountFilterFactory maxTokenCount -->
<filter class="solr.LimitTokenCountFilterFactory" maxTokenCount="foo" foo="100000"/>
<!-- workaround to bug in Solr 4.0 to set LimitTokenCountFilterFactory maxTokenCount, might change to single attribute in future -->
<filter class="solr.LimitTokenCountFilterFactory" maxTokenCount="val" val="200000"/>
<filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />
<!-- in this example, we will only use synonyms at query time
<filter class="solr.SynonymFilterFactory" synonyms="index_synonyms.txt" ignoreCase="true" expand="false"/>
@@ -231,8 +233,8 @@
</analyzer>
<analyzer type="query">
<tokenizer class="solr.StandardTokenizerFactory"/>
<!-- workaround to bug in Solr 4.0 to set LimitTokenCountFilterFactory maxTokenCount -->
<filter class="solr.LimitTokenCountFilterFactory" maxTokenCount="foo" foo="100000"/>
<!-- workaround to bug in Solr 4.0 to set LimitTokenCountFilterFactory maxTokenCount, might change to single attribute in future -->
<filter class="solr.LimitTokenCountFilterFactory" maxTokenCount="val" val="200000"/>
<filter class="solr.StopFilterFactory" ignoreCase="true" words="stopwords.txt" enablePositionIncrements="true" />
<filter class="solr.SynonymFilterFactory" synonyms="synonyms.txt" ignoreCase="true" expand="true"/>
<filter class="solr.LowerCaseFilterFactory"/>
@@ -345,18 +345,15 @@ class HighlightedMatchesSource implements MarkupSource, HighlightLookup {
q.addFilterQuery(filterQuery);
q.addHighlightField(highLightField); //for exact highlighting, try content_ws field (with stored="true" in Solr schema)
//need to use original highlighter (as opposed to snippets), because FVH does not seem to support fragsize=0 to get entire content
//https://issues.apache.org/jira/browse/SOLR-1268?attachmentSortBy=dateTime
q.setHighlightSimplePre(HIGHLIGHT_PRE); //original highlighter only
q.setHighlightSimplePost(HIGHLIGHT_POST); //original highlighter only
q.setHighlightFragsize(0); // don't fragment the highlight, works with original highlighter only
//q.setHighlightSimplePre(HIGHLIGHT_PRE); //original highlighter only
//q.setHighlightSimplePost(HIGHLIGHT_POST); //original highlighter only
q.setHighlightFragsize(0); // don't fragment the highlight, works with original highlighter, or needs "single" list builder with FVH
//tune the highlighter
//q.setParam("hl.useFastVectorHighlighter", "on"); //fast highlighter scales better than standard one
//q.setParam("hl.tag.pre", HIGHLIGHT_PRE); //makes sense for FastVectorHighlighter only
//q.setParam("hl.tag.post", HIGHLIGHT_POST); //makes sense for FastVectorHighlighter only
//q.setParam("hl.fragListBuilder", "simple"); //makes sense for FastVectorHighlighter only
q.setParam("hl.useFastVectorHighlighter", "on"); //fast highlighter scales better than standard one
q.setParam("hl.tag.pre", HIGHLIGHT_PRE); //makes sense for FastVectorHighlighter only
q.setParam("hl.tag.post", HIGHLIGHT_POST); //makes sense for FastVectorHighlighter only
q.setParam("hl.fragListBuilder", "single"); //makes sense for FastVectorHighlighter only
//docs says makes sense for the original Highlighter only, but not really
q.setParam("hl.maxAnalyzedChars", Server.HL_ANALYZE_CHARS_UNLIMITED);
+1
View File
@@ -4,6 +4,7 @@ New features:
Improvements:
- Keyword search indexing and search speed improvements
- Improved keyword search highlighting in Text View: highlighted tokens are no longer white-space separated
- Remake of reporting UI and functionality
- Significant increase in reporting speed
- Documented report module API