这罐子需要使用ConcurrentUpdateSolrServer? [英] Which jars are needed to use ConcurrentUpdateSolrServer?

查看:123
本文介绍了这罐子需要使用ConcurrentUpdateSolrServer?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

目前使用

solrServer = new CommonsHttpSolrServer(serverUrl);

和与这些罐子..结果

apache-solr-core-3.6.0
apache-solr-solrj-3.6.0
commons-codec-1.6
commons-httpclient-3.1
commons-io-2.1
jcl-over-slf4j-1.6.1
slf4j-api-1.6.1
slf4j-jdk14-1.6.1
lucene-core-3.5.0

不过Apache Solr实现德precated CommonHttpSolrServer ,并建议 ConcurrentUpdateSolrServer 结果
更换 CommonHttpSolrServer ConcurrentUpdateSolrServer 使运行时异常..结果

However apache solr deprecated CommonHttpSolrServer and suggested ConcurrentUpdateSolrServer
Replacing CommonHttpSolrServer by ConcurrentUpdateSolrServer gives runtime exception ..

结果

异常线程mainjava.lang.NoClassDefFoundError的:组织/阿帕奇/ HTTP / Htt的prequestInterceptor结果

Exception in thread "main" java.lang.NoClassDefFoundError: org/apache/http/HttpRequestInterceptor

它需要的jar 的HttpCore-4.0-alpha6.jar
结果异常还表明三个例外。结果
其具有额外的jar文件列表中任何人如的HttpCore-4.0-alpha6.jar 需要更换 CommonHttpSolrServer ConcurrentUpdateSolrServer

which needs the jar httpcore-4.0-alpha6.jar
Exception also indicate three more exceptions.
Anybody having list of which extra jars like httpcore-4.0-alpha6.jar are needed to replace CommonHttpSolrServer by ConcurrentUpdateSolrServer

推荐答案

看看 https://issues.apache.org/jira/browse/SOLR-3374
您需要包括的HttpCore httpmime 的HttpClient 罐子。

另外,我注意到,您使用的Solr 3.6罐子使用Lucene 3.5罐 - 这通常是一个好主意,让Solr的和Lucene JAR版本同步

Also, I noticed that you are using Solr 3.6 jars with Lucene 3.5 jars - it is generally a good idea to keep Solr and Lucene jar versions in sync.

这篇关于这罐子需要使用ConcurrentUpdateSolrServer?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆