solr
文章平均质量分 72
qq_18674585
这个作者很懒,什么都没留下…
展开
-
倒排索引的利用
1.配置需要对schema中的查询字段设置indexed="true" termPositions="true" termVectors="true" 2.termVector使用通过termVector = reader.getTermVector(int docID, String field)获取文档id对应字段向量通过字段向量,可以获取该字段中所有词和其词频,暂时还未找到方法获取其位置。3...原创 2018-07-16 10:35:47 · 474 阅读 · 0 评论 -
自定义插件
通过重写QueryParser实现 1,继承CustomScoreProvider类,重写customScore方法,从DocValues中动态读取评分有关因子,计算后,影响总评分 2,继承CustomScoreQuery类,重写getCustomScoreProvider方法,需要用到1,返回自定义的CustomScoreProvider类 到此,在lucene中就完事了,但是在solr中我们还...原创 2018-07-16 10:36:57 · 204 阅读 · 0 评论