利用 solrj 提交索引

首先创建一个 SolrInputDocument 对象, bottes ugg soldes 然后设置其字段值, Timberland pour hommes 通过 SolrServer’s 的 add() 方法, ugg australia pas cher 将文档提交给 solr, soldes timberland 实例代码如下:

String urlString = “http://localhost:8983/solr”; SolrServer solr = new CommonsHttpSolrServer(urlString); SolrInputDocument document = new SolrInputDocument(); document.addField(“id”, ugg pas cher “552199″); document.addField(“name”, moncler soldes “Gouda cheese wheel”); document.addField(“price”,

Copyright © All Rights Reserved · Green Hope Theme by Sivan & schiy · Proudly powered by WordPress · 闽ICP备18020075号