<bdo id='WTzVi'></bdo><ul id='WTzVi'></ul>

  • <legend id='WTzVi'><style id='WTzVi'><dir id='WTzVi'><q id='WTzVi'></q></dir></style></legend>
    <i id='WTzVi'><tr id='WTzVi'><dt id='WTzVi'><q id='WTzVi'><span id='WTzVi'><b id='WTzVi'><form id='WTzVi'><ins id='WTzVi'></ins><ul id='WTzVi'></ul><sub id='WTzVi'></sub></form><legend id='WTzVi'></legend><bdo id='WTzVi'><pre id='WTzVi'><center id='WTzVi'></center></pre></bdo></b><th id='WTzVi'></th></span></q></dt></tr></i><div id='WTzVi'><tfoot id='WTzVi'></tfoot><dl id='WTzVi'><fieldset id='WTzVi'></fieldset></dl></div>

    <small id='WTzVi'></small><noframes id='WTzVi'>

        <tfoot id='WTzVi'></tfoot>

        是什么导致错误'一个 SPI 类型的 lucene.codecs.Codec 名称'Lucene42&#

        What causes err #39; A SPI class of type lucene.codecs.Codec name #39;Lucene42#39;(是什么导致错误一个 SPI 类型的 lucene.codecs.Codec 名称Lucene42)

        <small id='6IcNQ'></small><noframes id='6IcNQ'>

            <tbody id='6IcNQ'></tbody>

          <i id='6IcNQ'><tr id='6IcNQ'><dt id='6IcNQ'><q id='6IcNQ'><span id='6IcNQ'><b id='6IcNQ'><form id='6IcNQ'><ins id='6IcNQ'></ins><ul id='6IcNQ'></ul><sub id='6IcNQ'></sub></form><legend id='6IcNQ'></legend><bdo id='6IcNQ'><pre id='6IcNQ'><center id='6IcNQ'></center></pre></bdo></b><th id='6IcNQ'></th></span></q></dt></tr></i><div id='6IcNQ'><tfoot id='6IcNQ'></tfoot><dl id='6IcNQ'><fieldset id='6IcNQ'></fieldset></dl></div>
              <bdo id='6IcNQ'></bdo><ul id='6IcNQ'></ul>

                <legend id='6IcNQ'><style id='6IcNQ'><dir id='6IcNQ'><q id='6IcNQ'></q></dir></style></legend>
                <tfoot id='6IcNQ'></tfoot>
                  本文介绍了是什么导致错误'一个 SPI 类型的 lucene.codecs.Codec 名称'Lucene42'的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着跟版网的小编来一起学习吧!

                  问题描述

                  无法弄清楚是什么原因导致不存在名称为Lucene42"的 org.apache.lucene.codecs.Codec 类型的 SPI 类.您需要将支持此 SPI 的相应 JAR 文件添加到您的类路径中'

                  Can't figure out what is causing ' A SPI class of type org.apache.lucene.codecs.Codec with name 'Lucene42' does not exist. You need to add the corresponding JAR file supporting this SPI to your classpath'

                  任何帮助将不胜感激

                  java.lang.IllegalArgumentException: A SPI class of type org.apache.lucene.codecs.Codec with name 'Lucene42' does not exist. You need to add the corresponding JAR file supporting this SPI to your classpath.The current classpath supports the following names: []
                  org.apache.lucene.util.NamedSPILoader.lookup(NamedSPILoader.java:104)
                  org.apache.lucene.codecs.Codec.forName(Codec.java:95)
                  org.apache.lucene.codecs.Codec.<clinit>(Codec.java:122)
                  org.apache.lucene.index.LiveIndexWriterConfig.<init>(LiveIndexWriterConfig.java:118)
                  org.apache.lucene.index.IndexWriterConfig.<init>(IndexWriterConfig.java:145)
                  com.damn.fr.rr.rent.getResukt(Man.java:404)
                  com.damn.fr.rr.handler.pg.setResult(pg.java:103)
                  com.damn.fr.rr.cmd.del.execute(del.java:19)
                  com.damn.fr.rr.servlet.PublicController.doPost(controller.java:199)
                  javax.servlet.http.HttpServlet.service(HttpServlet.java:754)
                  javax.servlet.http.HttpServlet.service(HttpServlet.java:847)
                  

                  Jboss 部署文件夹路径 'C:JBASmodulesorgapachelucenemain' 和目录内容

                  Jboss deployment folder path 'C:JBASmodulesorgapachelucenemain' and directory contents

                  jboss-deployment-structure.xml

                  jboss-deployment-structure.xml

                      <sub-deployment name="damn.jar">
                      <dependencies>
                          <module name="org.apache.commons.fileupload" />
                          <module name="org.apache.commons.io" />
                          <module name="org.apache.commons.lang3" />
                          <module name="org.apache.commons.validator" />
                          <module name="org.apache.lucene" />
                          <module name="net.sf.jasperreports" />
                          <module name="com.google.gson" />
                  
                      </dependencies>
                  </sub-deployment>
                  

                  模块.xml

                  <module xmlns="urn:jboss:module:1.0" name="org.apache.lucene">
                  <resources>
                  <resource-root path="lucene-analyzers-common-4.2.0.jar"/>
                  <resource-root path="lucene-core-4.2.0.jar"/>
                  <resource-root path="lucene-queryparser-4.2.0.jar"/>
                  <resource-root path="lucene-codecs-4.2.0.jar"/>
                  </resources>
                  
                  <dependencies>
                  </dependencies>
                  

                  ant 构建文件段

                  <pathelement path="${thirdPartyDir}/lucene-analyzers-common-4.2.0.jar" />
                  <pathelement path="${thirdPartyDir}/lucene-codecs-4.2.0.jar" />
                  <pathelement path="${thirdPartyDir}/lucene-queryparser-  4.2.0.jar" />
                  <pathelement path="${thirdPartyDir}/lucene-core-4.2-SNAPSHOT.jar" />
                  

                  推荐答案

                  请添加以下文件

                  文件夹:META-INF/services/

                  文件:org.apache.lucene.codecs.Codec

                  文本:org.apache.lucene.codecs.lucene54.Lucene54Codec

                  请在 https://anwaarlabs.wordpress.com/2017/02/25/lucene-an-spi-class-of-type-org-apache-lucene-codecs-codec-with-name-does-not-exist/

                  此解决方案是为 Lucene5.4 定义的,它也适用于 Lucene 4.2.谢谢

                  This solution is defined for Lucene5.4 it also works for Lucene 4.2. Thanks

                  这篇关于是什么导致错误'一个 SPI 类型的 lucene.codecs.Codec 名称'Lucene42'的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持跟版网!

                  本站部分内容来源互联网,如果有图片或者内容侵犯了您的权益,请联系我们,我们会在确认后第一时间进行删除!

                  相关文档推荐

                  Lucene Porter Stemmer not public(Lucene Porter Stemmer 未公开)
                  How to index pdf, ppt, xl files in lucene (java based or python or php any of these is fine)?(如何在 lucene 中索引 pdf、ppt、xl 文件(基于 java 或 python 或 php 中的任何一个都可以)?)
                  KeywordAnalyzer and LowerCaseFilter/LowerCaseTokenizer(KeywordAnalyzer 和 LowerCaseFilter/LowerCaseTokenizer)
                  How to search between dates (Hibernate Search)?(如何在日期之间搜索(休眠搜索)?)
                  How to get positions from a document term vector in Lucene?(如何从 Lucene 中的文档术语向量中获取位置?)
                  Java Lucene 4.5 how to search by case insensitive(Java Lucene 4.5如何按不区分大小写进行搜索)
                • <i id='bJ1b0'><tr id='bJ1b0'><dt id='bJ1b0'><q id='bJ1b0'><span id='bJ1b0'><b id='bJ1b0'><form id='bJ1b0'><ins id='bJ1b0'></ins><ul id='bJ1b0'></ul><sub id='bJ1b0'></sub></form><legend id='bJ1b0'></legend><bdo id='bJ1b0'><pre id='bJ1b0'><center id='bJ1b0'></center></pre></bdo></b><th id='bJ1b0'></th></span></q></dt></tr></i><div id='bJ1b0'><tfoot id='bJ1b0'></tfoot><dl id='bJ1b0'><fieldset id='bJ1b0'></fieldset></dl></div>
                      <bdo id='bJ1b0'></bdo><ul id='bJ1b0'></ul>
                    • <legend id='bJ1b0'><style id='bJ1b0'><dir id='bJ1b0'><q id='bJ1b0'></q></dir></style></legend>
                        <tbody id='bJ1b0'></tbody>

                        <small id='bJ1b0'></small><noframes id='bJ1b0'>

                          <tfoot id='bJ1b0'></tfoot>