java 由于modernizer插件,Maven构建失败

pbpqsu0x  于 2023-08-01  发布在  Java
关注(0)|答案(1)|浏览(246)

我创建了一个jhipster项目。在Java代码中做了一些更改后,我无法运行“mvn clean install”命令。我为API创建了一个MapstructMap器类。这是我做的唯一改变。下面给出了日志。

[[1;34mINFO[m] [1;31mBUILD FAILURE[m
[[1;34mINFO[m] [1m------------------------------------------------------------------------[m
[[1;34mINFO[m] Total time:  02:20 min
[[1;34mINFO[m] Finished at: 2023-07-19T20:28:55+05:30
[[1;34mINFO[m] [1m------------------------------------------------------------------------[m
[[1;31mERROR[m] Failed to execute goal [32morg.gaul:modernizer-maven-plugin:2.4.0:modernizer[m [1m(modernizer)[m on project [36mbuyyinn[m: [1;31mExecution modernizer of goal org.gaul:modernizer-maven-plugin:2.4.0:modernizer failed: A required class was missing while executing org.gaul:modernizer-maven-plugin:2.4.0:modernizer: org/codehaus/plexus/util/StringUtils[m
[[1;31mERROR[m] [1;31m-----------------------------------------------------[m
[[1;31mERROR[m] [1;31mrealm =    plugin>org.gaul:modernizer-maven-plugin:2.4.0[m
[[1;31mERROR[m] [1;31mstrategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy[m
[[1;31mERROR[m] [1;31murls[0] = file:/C:/Users/sanal/.m2/repository/org/gaul/modernizer-maven-plugin/2.4.0/modernizer-maven-plugin-2.4.0.jar[m
[[1;31mERROR[m] [1;31murls[1] = file:/C:/Users/sanal/.m2/repository/backport-util-concurrent/backport-util-concurrent/3.1/backport-util-concurrent-3.1.jar[m
[[1;31mERROR[m] [1;31murls[2] = file:/C:/Users/sanal/.m2/repository/org/codehaus/plexus/plexus-interpolation/1.11/plexus-interpolation-1.11.jar[m
[[1;31mERROR[m] [1;31murls[3] = file:/C:/Users/sanal/.m2/repository/junit/junit/3.8.1/junit-3.8.1.jar[m
[[1;31mERROR[m] [1;31murls[4] = file:/C:/Users/sanal/.m2/repository/org/ow2/asm/asm/9.2/asm-9.2.jar[m
[[1;31mERROR[m] [1;31murls[5] = file:/C:/Users/sanal/.m2/repository/org/ow2/asm/asm-commons/9.2/asm-commons-9.2.jar[m
[[1;31mERROR[m] [1;31murls[6] = file:/C:/Users/sanal/.m2/repository/org/ow2/asm/asm-tree/9.2/asm-tree-9.2.jar[m
[[1;31mERROR[m] [1;31murls[7] = file:/C:/Users/sanal/.m2/repository/org/ow2/asm/asm-analysis/9.2/asm-analysis-9.2.jar[m
[[1;31mERROR[m] [1;31murls[8] = file:/C:/Users/sanal/.m2/repository/org/gaul/modernizer-maven-annotations/2.4.0/modernizer-maven-annotations-2.4.0.jar[m
[[1;31mERROR[m] [1;31mNumber of foreign imports: 1[m
[[1;31mERROR[m] [1;31mimport: Entry[import  from realm ClassRealm[maven.api, parent: null]][m
[[1;31mERROR[m] [1;31m[m
[[1;31mERROR[m] [1;31m-----------------------------------------------------[m
[[1;31mERROR[m] [1;31m[m: org.codehaus.plexus.util.StringUtils
[[1;31mERROR[m] -> [1m[Help 1]

字符串
我使用的Jhipster版本是7.9.3
我不能理解这个问题。有人能帮忙吗?

kxkpmulp

kxkpmulp1#

我相信如果升级你的Modernizer插件到2.6.0,它应该解决你的问题。他们删除了Plexus StringUtils的使用,以便与新版本的Maven兼容。这可能是你的问题的原因。

相关问题