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

问题描述

我有一个Solr的多核实现.我要配置DIH/核心.我设法使其在单核Solr上运行.我所假设的是,我必须配置/core,这意味着我在内核的conf目录中创建了data-import.xml并重写了该内核的solrconfig.xml.我还在lib中复制了dih的驱动程序,但是却收到错误消息:

I have a multicore implementation of solr. I want to configure DIH / core. I manage to make it work on single core solr. What I assume, I have to make the configurations / core, which means I create the data-import.xml in the core's conf directory and rewrite solrconfig.xml of the core. I also copied in the lib the maching driver for dih, but I get an error message:

起因: java.lang.ClassNotFoundException: org.apache.solr.handler.dataimport.DataImportHandler位于 java.net.URLClassLoader $ 1.run(URLClassLoader.java:217)在 java.security.AccessController.doPrivileged(本机方法),位于 java.net.URLClassLoader.findClass(URLClassLoader.java:205)在 java.lang.ClassLoader.loadClass(ClassLoader.java:321)在 java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:615)在 java.lang.ClassLoader.loadClass(ClassLoader.java:266)在 java.lang.Class.forName0(本机方法),位于 java.lang.Class.forName(Class.java:264)在 org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.java:373) ...还有49个

Caused by: java.lang.ClassNotFoundException: org.apache.solr.handler.dataimport.DataImportHandler at java.net.URLClassLoader$1.run(URLClassLoader.java:217) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:205) at java.lang.ClassLoader.loadClass(ClassLoader.java:321) at java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:615) at java.lang.ClassLoader.loadClass(ClassLoader.java:266) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:264) at org.apache.solr.core.SolrResourceLoader.findClass(SolrResourceLoader.java:373) ... 49 more

任何提示,我在做什么错?预先感谢.

Any clue, what I'm doing wrong? Thanks in advance.

推荐答案

solr.war中不再包含dataimporthandler.您应该将jar apache-solr-dataimporthandler-x.x.x.jar(请用当前版本替换x.x.x)添加到类路径中.您可以在已下载的solr zip文件的dist文件夹中找到它.

The dataimporthandler isn't included anymore in the solr.war. You should add the jar apache-solr-dataimporthandler-x.x.x.jar (please replace the x.x.x with your current version) to your classpath. You can find it in the dist folder of the solr zip file you've downloaded.

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

07-31 06:58