Open pei55 opened 9 months ago
试了好多次以后发现还是我的问题,
请问解决了吗?我也是mvn package的时候出错“class file has wrong version 55.0, should be 52.0”
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.3:compile (default-compile) on project elasticsearch-analysis-ansj: Compilation failure [ERROR] ansj/elasticsearch/plugin/AnalysisAnsjPlugin.java:[14,34] 无法访问org.apache.lucene.analysis.Analyzer [ERROR] 错误的类文件: /root/.m2/repository/org/apache/lucene/lucene-core/9.8.0/lucene-core-9.8.0.jar(org/apache/lucene/analysis/Analyzer.class) [ERROR] 类文件具有错误的版本 55.0, 应为 52.0 [ERROR] 请删除该文件或确保该文件位于正确的类路径子目录中。
在执行mvn package的时候,报错如下,怎么解决啊 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.11.0:compile (default-compile) on project elasticsearch-analysis-dynamic-synonym: Compilation failure [ERROR] /root/elasticsearch-analysis-dynamic-synonym/src/main/java/com/bellszhu/elasticsearch/plugin/synonym/analysis/DynamicSynonymGraphFilter.java:[25,34] cannot access org.apache.lucene.analysis.TokenStream [ERROR] bad class file: /root/.m2/repository/org/apache/lucene/lucene-core/9.8.0/lucene-core-9.8.0.jar(org/apache/lucene/analysis/TokenStream.class) [ERROR] class file has wrong version 55.0, should be 52.0 [ERROR] Please remove or make sure it appears in the correct subdirectory of the classpath.