Spring boot 与org.quartz调度器相关的spring boot dependencies 2.2.2.RELEASE的问题:quartz
在构建项目时,我注意到以下警告:Spring boot 与org.quartz调度器相关的spring boot dependencies 2.2.2.RELEASE的问题:quartz,spring-boot,maven,quartz-scheduler,Spring Boot,Maven,Quartz Scheduler,在构建项目时,我注意到以下警告: [WARNING] Some problems were encountered while building the effective model for org.openx.delivery.service:delivery_adserver_java:jar:170.1.2 [WARNING] 'dependencyManagement.dependencies.dependency.exclusions.exclusion.artif
[WARNING] Some problems were encountered while building the effective model for org.openx.delivery.service:delivery_adserver_java:jar:170.1.2
[WARNING] 'dependencyManagement.dependencies.dependency.exclusions.exclusion.artifactId'
for org.quartz-scheduler:quartz:jar with value '*' does not match a valid id pattern. @ org.springframework.boot:spring-boot-dependencies:2.2.2.RELEASE,
/root/.m2/repository/org/springframework/boot/spring-boot-dependencies/2.2.2.RELEASE/spring-boot-dependencies-2.2.2.RELEASE.pom, line 2753, column 25
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
在我的项目中没有直接引用'org.quartz调度器:quartz:jar'
。
当我执行“mvn dependency:tree
”时,我也看不到对该模块的任何引用
问题:我如何解决这个问题
//编辑
有更多关于我的pom.xml的详细信息”
。。。
org.springframework.boot
spring启动程序父级
2.2.2.1发布
...
org.apache.thrift
贪污腐化
0.10.0
...
org.junit.jupiter
JUnitJupiter api
${junit.jupiter.version}
测试
朱尼特
朱尼特
${junit.version}
测试
...
org.springframework.boot
弹簧靴起动器
org.springframework.boot
spring启动程序日志记录
org.springframework.boot
spring-boot-starter-log4j2
...
你能添加你正在使用的pom.xml吗?由于公司规定,我不能添加,但我会在POST中添加更多细节。根据我已经看到的片段,你有一个与JUnit 4和JUnit Jupiter相关的问题…如果你想运行JUnit 4测试,你必须添加JUnit Jupiter Vintage,否则测试将无法运行…我强烈建议switch到JUnit Jupiter…此外,为什么不使用最新版本的Spring boot(2.2.6.RELEASE)消息显示您可能正在使用旧的Maven版本?您使用的是哪个.Maven版本?代码段中没有显示包含排除项的块…?@khmarbaise感谢您的评论-我知道这个问题,但t是有意在这个项目中使用的-我在JUnit 4中有很多旧的测试,并且我正在将Spring Boot引入legacy中因此,我希望保留旧的测试并添加新的测试(JUnit5)-我同时使用了这两种方法-删除JUnit.4依赖项并添加JUnit jupiter vintage会更容易。因此,您可以在代码中保留JUnit 4测试,并随着时间的推移进行迁移…您可以添加您正在使用的pom.xml吗?我不能,因为公司的规定-但我将根据我已经看到的代码片段为POST添加更多详细信息一个与JUnit 4和JUnit Jupiter相关的问题…如果你想运行JUnit 4测试,你必须添加JUnit Jupiter Vintage,否则测试将无法运行…我强烈建议完全切换到JUnit Jupiter…此外,为什么不使用最新版本的Spring boot(2.2.6.RELEASE)消息显示您可能正在使用旧的Maven版本?您使用的是哪个.Maven版本?代码段中没有显示包含排除项的块…?@khmarbaise感谢您的评论-我知道这个问题,但t是有意在这个项目中使用的-我在JUnit 4中有很多旧的测试,并且我正在将Spring Boot引入legacy中因此,我希望保留旧的测试并添加新的测试(Junit 5)-我同时使用这两种测试只要删除Junit.4依赖项并添加Junit jupiter vintage就更容易了。因此,您可以在代码中保留Junit 4测试并随时间迁移它们。。。
...
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>2.2.2.RELEASE</version>
<relativePath/> <!-- lookup parent from repository -->
</parent>
...
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.apache.thrift</groupId>
<artifactId>libthrift</artifactId>
<version>0.10.0</version>
</dependency>
...
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter-api</artifactId>
<version>${junit.jupiter.version}</version>
<scope>test</scope>
</dependency>
<!-- For old JUnit4 tests -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
</dependencies>
</dependencyManagement>
...
<dependencies>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter</artifactId>
<exclusions>
<exclusion>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-logging</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-log4j2</artifactId>
</dependency>
...