本文介绍了嵌入式Solr DIH的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

谁能告诉我如何在Solrj中配置嵌入式Solr DIH?我尝试过了.

Can anyone tell me how to configure Embedded Solr DIH in Solrj?I tried this..

SolrQuery qry = new SolrQuery(); qry.setQueryType("/import"); qry.setParam("command", "full-import"); qry.setParam("clean", false); embeddedSolrServer.query(qry);

SolrQuery qry = new SolrQuery(); qry.setQueryType("/import"); qry.setParam("command", "full-import"); qry.setParam("clean", false); embeddedSolrServer.query(qry);

它到此为止.

1468 [Thread-1]信息org.apache.solr.handler.dataimport.DataImporter-完全启动 导入

1468 [Thread-1] INFO org.apache.solr.handler.dataimport.DataImporter - Starting Full Import

1468 [main]信息org.apache.solr.core.SolrCore-[main] webapp = null path =/import params = {qt =%2Fimport& command = full-import& clean = false} 状态= 0 QTime = 15

1468 [main] INFO org.apache.solr.core.SolrCore - [main] webapp=null path=/import params={qt=%2Fimport&command=full-import&clean=false} status=0 QTime=15

此后,我希望得到类似Solr HTTP Server的信息:

After this I expect to get something like this as in Solr HTTP Server :

org.apache.solr.handler.dataimport.JdbcDataSource $ 1创建一个 带有URL的实体ID的连接:jdbc:mysql://localhost/solrdb

org.apache.solr.handler.dataimport.JdbcDataSource$1 call Creating a connection for entity id with URL: jdbc:mysql://localhost/solrdb

org.apache.solr.handler.dataimport.JdbcDataSource $ 1呼叫

org.apache.solr.handler.dataimport.JdbcDataSource$1 call

依此类推...

先谢谢您了:)

推荐答案

您可以这样做:

URL url = new URL(completeUrl);
HttpURLConnection conn = (HttpURLConnection)url.openConnection();

看看我是怎么做到的此处.

这篇关于嵌入式Solr DIH的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

09-12 18:45