liangxinye的gravatar头像
liangxinye 2016-01-09 14:43:57
apache solr中SimplePostTool工具(3)

上传成功之后,查看的结果如下:

apache solr中SimplePostTool工具(3)

-Dhost=<host> (default: localhost),solr服务器地址

 

-Dport=<port> (default: 8983),solr服务器端口

 

-Dauto=yes|no (default=no),SimplePostTool工具是否进入自动模式,自动模式下,会将-Ddata数据转换成相应的内容类型,切会忽略-Dtype参数,如下示例:

java -Dauto=no -Dc=gettingstarted -jar post.jar books.json(失败)

java -Dauto=yes -Dc=gettingstarted -jar post.jar books.json(成功)

apache solr中SimplePostTool工具(3)

-Drecursive=yes|no|<depth> (default=0),递归

 

-Ddelay=<seconds> (default=0 for files, 10 for web),延迟,单位是秒

 

-Dfiletypes=<type>[,<type>,...] (default=xml,json,csv,pdf,doc,docx,ppt,pptx,xls,xlsx,odt,odp,ods,ott,otp,ots,rtf,htm,html,txt,log),文件类型

 

-Dparams="<key>=<value>[&<key>=<value>...]" (values must be URL-encoded),过滤参数

 

-Dcommit=yes|no (default=yes),自动提交

 

-Doptimize=yes|no (default=no),优化

 

-Dout=yes|no (default=no)

 

Solr支持XML结构文档索引、CSV、JSON,可以在solrconfig.xml文件中进行相应的配置,参考一下文档:

https://cwiki.apache.org/confluence/display/solr/RequestDispatcher+in+SolrConfig


打赏
最近浏览
jinghao 2017年12月28日
暂无贡献等级
weienqing  LV17 2017年11月15日
yishunyongheng  LV1 2017年3月10日
kenhomeliu  LV29 2016年9月22日
孟飞阳  LV3 2016年4月13日
sky_chou 2016年1月20日
暂无贡献等级
809204304@qq.com  LV13 2016年1月20日
遇见,  LV36 2016年1月19日
riky  LV4 2016年1月19日
smartking  LV12 2016年1月19日
顶部 客服 微信二维码 底部
>扫描二维码关注最代码为好友扫描二维码关注最代码为好友