Removing analyzers on Entity2LuceneDoc.term.RDFTYPE and Entity2LuceneDoc.term.CLASSGROUP_URI fields.
This commit is contained in:
parent
328bcf86d6
commit
635130c73e
2 changed files with 2 additions and 3 deletions
|
@ -152,7 +152,7 @@ public class Entity2LuceneDoc implements Obj2DocIface{
|
||||||
if( clz.getSearchBoost() != null )
|
if( clz.getSearchBoost() != null )
|
||||||
doc.setBoost( doc.getBoost() + clz.getSearchBoost() );
|
doc.setBoost( doc.getBoost() + clz.getSearchBoost() );
|
||||||
|
|
||||||
Field typeField = new Field (term.RDFTYPE, clz.getName(), Field.Store.YES, Field.Index.ANALYZED);
|
Field typeField = new Field (term.RDFTYPE, clz.getURI(), Field.Store.YES, Field.Index.NOT_ANALYZED);
|
||||||
//typeField.setBoost(2*FIELD_BOOST);
|
//typeField.setBoost(2*FIELD_BOOST);
|
||||||
|
|
||||||
doc.add( typeField);
|
doc.add( typeField);
|
||||||
|
@ -163,7 +163,7 @@ public class Entity2LuceneDoc implements Obj2DocIface{
|
||||||
//Classgroup URI
|
//Classgroup URI
|
||||||
if( clz.getGroupURI() != null ){
|
if( clz.getGroupURI() != null ){
|
||||||
Field classGroupField = new Field(term.CLASSGROUP_URI, clz.getGroupURI(),
|
Field classGroupField = new Field(term.CLASSGROUP_URI, clz.getGroupURI(),
|
||||||
Field.Store.YES, Field.Index.ANALYZED);
|
Field.Store.YES, Field.Index.NOT_ANALYZED);
|
||||||
// classGroupField.setBoost(FIELD_BOOST);
|
// classGroupField.setBoost(FIELD_BOOST);
|
||||||
doc.add(classGroupField);
|
doc.add(classGroupField);
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,7 +21,6 @@ import javax.servlet.ServletContextEvent;
|
||||||
import org.apache.commons.logging.Log;
|
import org.apache.commons.logging.Log;
|
||||||
import org.apache.commons.logging.LogFactory;
|
import org.apache.commons.logging.LogFactory;
|
||||||
import org.apache.lucene.analysis.Analyzer;
|
import org.apache.lucene.analysis.Analyzer;
|
||||||
import org.apache.lucene.analysis.KeywordAnalyzer;
|
|
||||||
import org.apache.lucene.analysis.PerFieldAnalyzerWrapper;
|
import org.apache.lucene.analysis.PerFieldAnalyzerWrapper;
|
||||||
import org.apache.lucene.analysis.standard.StandardAnalyzer;
|
import org.apache.lucene.analysis.standard.StandardAnalyzer;
|
||||||
import org.apache.lucene.search.BooleanQuery;
|
import org.apache.lucene.search.BooleanQuery;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue