Solr-Tika集成索引文件

问题描述:

我跟随this link索引Solr中的文件。我在Solr文件夹中创建了一个文件夹,然后创建了名为“easy”的文件夹,然后创建了conf文件夹。 conf文件夹里面,我创建schema.xml中写了这样它里面:Solr-Tika集成索引文件

<field name="content" type="text" indexed="true" stored="true" multiValued="true"/> 

在那之后,我创建solrconfig.xml中然后写这些代码:

<requestHandler name="/dataimport"> 
    <lst name="defaults"> 
     <str name="config">data-config.xml</str> 
    </lst> 
</requestHandler> 
<lib dir="../../dist/" regex="apache-solr-dataimporthandler-.*\.jar" /> 

之后,创建数据 - config.xml文件然后写这些代码:

<dataConfig> 
    <script><![CDATA[ 
     id = 1; 
     function GenerateId(row) { 
      row.put('id', (id ++).toFixed()); 
      return row; 
     }  
     ]]></script> 
    <dataSource type="BinURLDataSource" name="data"/> 
    <dataSource type="URLDataSource" baseUrl="http://localhost/tmp/bin/" name="main"/> 
    <document> 
     <entity name="rec" processor="XPathEntityProcessor" url="data.xml" forEach="/albums/album" dataSource="main" transformer="script:GenerateId"> 
      <field column="title" xpath="//title" /> 
      <field column="description" xpath="//description" /> 
      <entity processor="TikaEntityProcessor" url="http://localhost/tmp/bin/${rec.description}" dataSource="data"> 
       <field column="text" name="content" /> 
       <field column="Author" name="author" meta="true" /> 
       <field column="title" name="title" meta="true" /> 
      </entity> 
     </entity> 
    </document> 
</dataConfig> 

然后我跑Solr的服务器,并发生错误

简单: org.apache.solr.common.SolrException:org.apache.solr.common.SolrException:从 /首页/爱丽丝/下载/ Solr的错误加载Solr的配置: 无法为核心容易加载的conf -4.10.2/example/solr/test/easy/conf/solrconfig.xml

根据the link which l am following,我缺少哪些部分? ?

有关的lib

<lib dir="../../dist/" regex="apache-solr-dataimporthandler-.*\.jar" /> 

第二个问题我需要改变” ../../dist/什么路径是

- 我删除了lib部分从solrconfig。 XML并重新启动服务器。错误仍然存​​在的。

错误说,它不能,如果你已经在conf文件夹添加solrconfig.xml中加载sorconfig.xml。 检查。