1
我用apache nutch爬行網站,並將其索引到Apache Solr.i不知道如何搜索與solr網站和html標籤之間的字符串? 謝謝如何在solr中搜索html標籤?
我用apache nutch爬行網站,並將其索引到Apache Solr.i不知道如何搜索與solr網站和html標籤之間的字符串? 謝謝如何在solr中搜索html標籤?
最簡單的方法是從HTML中提取數據並索引提取的數據。您可以使用HTMLStripCharFilterFactory從輸入流中去除HTML。
<analyzer>
<charFilter class="solr.HTMLStripCharFilterFactory"/>
<tokenizer class="solr.StandardTokenizerFactory"/>
</analyzer>