You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@jackrabbit.apache.org by to...@apache.org on 2015/06/16 11:38:36 UTC
svn commit: r1685749 - /jackrabbit/site/live/oak/docs/query/lucene.html
Author: tommaso
Date: Tue Jun 16 09:38:36 2015
New Revision: 1685749
URL: http://svn.apache.org/r1685749
Log:
OAK-936: Site checkin for project Oak Documentation-1.4-SNAPSHOT
Modified:
jackrabbit/site/live/oak/docs/query/lucene.html
Modified: jackrabbit/site/live/oak/docs/query/lucene.html
URL: http://svn.apache.org/viewvc/jackrabbit/site/live/oak/docs/query/lucene.html?rev=1685749&r1=1685748&r2=1685749&view=diff
==============================================================================
--- jackrabbit/site/live/oak/docs/query/lucene.html (original)
+++ jackrabbit/site/live/oak/docs/query/lucene.html Tue Jun 16 09:38:36 2015
@@ -1140,12 +1140,30 @@ Copied 8.5 MB in 218.7 ms
<div class="section">
<h5>Suggestions<a name="Suggestions"></a></h5>
<p><tt>@since Oak 1.1.17, 1.0.15</tt></p>
-<p>In order to use Lucene index to perform search suggestions, the index definition node (the one of type <tt>oak:queryIndexConfiguration</tt>) needs to have the <tt>compatVersion</tt> set to <tt>2</tt>, then one or more property nodes, depending on use case, need to have the property <tt>useForSuggest</tt> set to <tt>true</tt>, such setting controls from which properties terms to be used for suggestions will be taken.</p>
+<p>In order to use Lucene index to perform search suggestions, the index definition node (the one of type <tt>oak:QueryIndexDefinition</tt>) needs to have the <tt>compatVersion</tt> set to <tt>2</tt>, then one or more property nodes, depending on use case, need to have the property <tt>useForSuggest</tt> set to <tt>true</tt>, such setting controls from which properties terms to be used for suggestions will be taken.</p>
<p>Once the above configuration has been done, by default, the Lucene suggester is updated every 10 minutes but that can be changed by setting the property <tt>suggestUpdateFrequencyMinutes</tt> in the index definition node to a different value.</p></div>
<div class="section">
<h5>Spellchecking<a name="Spellchecking"></a></h5>
<p><tt>@since Oak 1.1.17, 1.0.13</tt></p>
-<p>In order to use Lucene index to perform spellchecking, the index definition node (the one of type <tt>oak:queryIndexConfiguration</tt>) needs to have the <tt>compatVersion</tt> set to <tt>2</tt>, then one or more property nodes, depending on use case, need to have the property <tt>useForSpellcheck</tt> set to <tt>true</tt>, such setting controls from which properties terms to be used for spellcheck corrections will be taken.</p></div></div></div>
+<p>In order to use Lucene index to perform spellchecking, the index definition node (the one of type <tt>oak:QueryIndexDefinition</tt>) needs to have the <tt>compatVersion</tt> set to <tt>2</tt>, then one or more property nodes, depending on use case, need to have the property <tt>useForSpellcheck</tt> set to <tt>true</tt>, such setting controls from which properties terms to be used for spellcheck corrections will be taken.</p>
+<p>Sample configuration for spellchecking based on terms contained in <tt>jcr:title</tt> property.</p>
+
+<div class="source">
+<pre>/oak:index/lucene-spellcheck
+ - jcr:primaryType = "oak:QueryIndexDefinition"
+ - compatVersion = 2
+ - type = "lucene"
+ - async = "async"
+ + indexRules
+ - jcr:primaryType = "nt:unstructured"
+ + nt:base
+ + properties
+ - jcr:primaryType = "nt:unstructured"
+ + jcr:title
+ - propertyIndex = true
+ - analyzed = true
+ - useForSpellcheck = true
+</pre></div></div></div></div>
<div class="section">
<h3>Design Considerations<a name="Design_Considerations"></a></h3>
<p>Lucene index provides quite a few features to meet various query requirements. While defining the index definition do consider the following aspects</p>