Failed to execute goal org.springframework.boot:spring-boot-maven-plugin
问题:
Failed to execute goal org.springframework.boot:spring-boot-maven-plugin:2.5.3:repackage (default) on project microservice-eureka: Execution default of goal org.springframework.boot:spring-boot-maven-plugin:2.5.3:repackage failed: Plugin org.springframework.boot:spring-boot-maven-plugin:2.5.3 or one of its dependencies could not be resolved: Failed to collect dependencies at org.springframework.boot:spring-boot-maven-plugin:jar:2.5.3 -> org.springframework.boot:spring-boot-buildpack-platform:jar:2.5.3
原因:
由于spring-boot-maven-plugin版本不一致导致的,项目pom文件中对这个jar没有指定版本,默认使用的是最新的2.5.3版本,对于我们的项目只能是2.3.1.RELEASE这个版本。
解决办法:
在项目pom文件中指定插件的版本为2.3.1.RELEASE
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<version>2.3.1.RELEASE</version>
<executions>
<execution>
<goals>
<goal>repackage</goal>
</goals>
</execution>
</executions>
</plugin>
AtomGit 是由开放原子开源基金会联合 CSDN 等生态伙伴共同推出的新一代开源与人工智能协作平台。平台坚持“开放、中立、公益”的理念,把代码托管、模型共享、数据集托管、智能体开发体验和算力服务整合在一起,为开发者提供从开发、训练到部署的一站式体验。
更多推荐



所有评论(0)