solr

ruby 2.1 rails 4 sunspot solr tests fail in suite but pass individually

给你一囗甜甜゛ 提交于 2020-01-13 11:23:07
问题 My team has been stumped on this issue for some time now and are at a loss as to where to try next. The spec below works correctly when run individually, however, when we run this in our suite via bundle exec ./bin/rspec spec these two tests fail every single time: GET /external-products/:id/deals GET /external-products/search/deals We have tried numerous different ways to approach this issue and I am starting to suspect something else outside of the said spec. SO I have to turn to the Stack

Lucene / Hibernate Search Lock Exception

雨燕双飞 提交于 2020-01-13 10:17:11
问题 I use Hibernate Search to index and full-text search items on a web application, problem-less! From my pom.xml: <hibernate.search.version>3.4.2.Final</hibernate.search.version> <apache.lucene.version>3.6.2</apache.lucene.version> <apache.solr.version>3.6.2</apache.solr.version> <hibernate.version>3.6.9.Final</hibernate.version> Now, before going to production I tried to stress test the search feature of my web-application using Apache JMeter. When testing with more then one thread, I receive

solr8.3.1加入中文分词

偶尔善良 提交于 2020-01-13 10:01:45
solr8.3.1加入中文分词(solr在docker容器中运行) 创建的核心默认情况下没有中文分词,当我们输入一串中文,进行词语拆分时,solr会把每一个汉字都拆开,比如输入“我是中国人”,进行词语拆分的时候会拆成:“我”,“是”,“中”,“国”,“人”五个词。如下图。 这明显不是我们想要的结果。我们需要将中文分词加入到solr中,才能得到我们想要的结果。 如何加入中文分词器? 1、下载中文分词器jar包 ik-analyer-8.3.0.jar。 百度网盘下载 2、上传jar包并拷贝到 /usr/local/solr/solr/server/solr-webapp/webapp/WEB-INF/lib目录下 cp /data/soft/ik-analyer-8.3.0.jar /usr/local/solr/solr/server/solr-webapp/webapp/WEB-INF/lib chmod a+r ik-analyzer-8.3.0.jar 说明:/data/solft是docker容器中的目录,已经挂在到宿主机目录/data/coowalt/solr目录。请参考《Docker 安装solr8.3.1》一文。 3、修改/data/solr/data/meta_db/conf/目录下的managed-schema文件。加入ik-analayer配置信息 cd

Solr: best documented, easy to use, stable Python APIs

混江龙づ霸主 提交于 2020-01-13 07:50:09
问题 I want to use Lucene Solr in Python. There seems to be multiple APIs for this purpose. They seem to suffer dependency hell and stability issues, and Solr doesnt ship with python bindings anymore. And I cant find any documentation for the user who is not familiar with Solr . I am leaning on Sunburnt over pysolr and solrpy for being the most mature. Is my evaluation correct? Please recommend stable python bindings for Solr with good standalone (does not presuppose Solr knowledge) documentation

SOLR delta-import timestamp issue

半世苍凉 提交于 2020-01-13 06:09:14
问题 I'm new to SOLR and was doing some research on this technology. I now have a question regarding the delta-import function so I looked on SO and found this: Solr DataImportHandler delta import. In the answer there is a field [date_update] mentioned which seems to be a timestamp of the record. My question is: Is [date_update] a timestamp stored in the table on record creation? If so, cannot this create an issues if the date of the Database Server is not exactly in sync with the server on which

Magento 1.12 and Solr 3.6 No proper results and no spell suggestions

最后都变了- 提交于 2020-01-13 03:29:08
问题 Any idea or suggestion. I am kind of confuse , I have setup solr and magento couple of times but now with magento 1.12 its behaving strange no proper results and no spell check. We had our magento 1.11 working fine with solr 1.4 ,its still working fine I try to use 1.4 and solr 3.6 no fix. Any idea or suggestion. I am kind of confuse 回答1: We have found multiple problems with solr with Magento EE 1.12. If you run the fulltext indexer from the shell via a cronjob the following event (yes it is

配置solr数据导入

不打扰是莪最后的温柔 提交于 2020-01-13 02:09:38
第一步:新建core solr中把配置的每一个模块都叫core 1.在solr_home目录下,拷贝collection1文件夹,并起名为hotel。打开test文件夹,修改core.properties文件,将name修改为hotel(名字可以随便改) 2.打开test文件夹,修改core.properties文件,将name修改为hotel 3.重新启动tomcat,并访问solr,如出现以下界面,则表示新建hotel core成功 第二步:新建数据库配置 1.拷贝数据库连接jar包(mysql-connector-java-5.1.18.jar)到tomcat的lib目录 2.打开hotel的conf文件夹中的solrconfig.xml文件 3.在requestHandler name="/select" class="solr.SearchHandler">前面上加上一个dataimport的处理的Handler <requestHandler name="/dataimport" class="org.apache.solr.handler.dataimport.DataImportHandler"> <lst name="defaults"> <str name="config">data-config.xml</str> </lst> <

Solr PatternReplaceCharFilterFactory not replacing with specified pattern

浪子不回头ぞ 提交于 2020-01-12 18:40:09
问题 So I am very new at Solr but I am trying to use the PatternReplaceCharFilterFactory to do some pre-processing on a phone number string that will be stored. Here is the configuration for the field: <fieldType name="phone_number" class="solr.TextField" > <analyzer> <charFilter class="solr.PatternReplaceCharFilterFactory" pattern="\(?(\d{3})?\)?[-. ]?(\d{3})[-. ]?(\d{4})" replaceWith="$1-$2-$3"/> <tokenizer class="solr.StandardTokenizerFactory"/> </analyzer> </fieldType> I have tested the regex

Solr exact word result come first

强颜欢笑 提交于 2020-01-12 10:49:20
问题 In Solr-5.0.0, I have one product_name field. When I search for a word or more than words, its giving results with product names that contain the words. How can I make it as the exact match come first. My Schema.xml is below: <field name="product_name" type="text_wslc" indexed="true" stored="true" required="true" multiValued="false"/> and my field definition is also given below: <fieldType name="text_wslc" class="solr.TextField" positionIncrementGap="100"> <analyzer type="index"> <tokenizer

SolrNet: SolrConnectionException (400) bad request when attempting to Add and Commit

我们两清 提交于 2020-01-12 09:45:06
问题 I have gotten to the point where SolrNet executes the "Add" method but when I try to "Commit" is when I receive the error. The following is my schema.xml, model, code calling it, and the error I get. Even stranger is that despite the error, the model is added to my Solr index AFTER I restart Tomcat (so it still adds my model despite the error but not immediately): schema.xml (fields and fieldtypes): <!-- Fields --> <field name="part_numbers" type="my_string_exact" indexed="true" stored="true"