2012-01-31 15 views
0

我使用nutch 1.4,我想将静态字段映射到Solr。nutch和solr之间的映射静态字段

我知道有索引静态插件。我这样配置它在nutch-site.xml中:

<property> 
     <name>index-static</name> 
     <value>field:value</value> 
    </property> 

但是,该值不会发送到Solr。

有没有人有解决方案?

回答

1

它看起来像nutch-default.xml中的条目是错误的。 根据插件来源“index.static”而不是“index-static”是属性的正确名称。

String fieldsString = conf.get("index.static", null); 

在我的nutch-site.xml中使用后,我能够发送多个字段到我的solr服务器。

还要确保插件已添加到“plugin.includes”属性中包含的插件列表中。