【发布时间】:2018-04-06 23:11:01
【问题描述】:
我要删除:
“com.vaadin.external.google:androidjson:0.0.20131108.vaadin1”
来自我的类路径。通过依赖树,我看到这个依赖来自:
'org.springframework.boot:spring-boot-configuration-processesor:1.5.8.RELEASE'。
因此我将其更改为以下内容:
compile ('org.springframework.boot:spring-boot-configuration-processor:1.5.8.RELEASE'){
exclude group: 'com.vaadin.external.google', module: 'android-json'
}
我的问题是依赖项仍然被拉取:
...
+--- org.springframework.boot:spring-boot-configuration-processor:1.5.8.RELEASE
| \--- com.vaadin.external.google:android-json:0.0.20131108.vaadin1
...
我做错了什么?
【问题讨论】:
-
在测试编译依赖项也引入依赖项之前,我遇到过这个问题: testCompile("org.springframework.boot:spring-boot-starter-test") { exclude group : 'com.vaadin.external.google', module: 'android-json'} 如果添加可以解决问题,请告诉我。
-
谢谢,问题已解决。你是怎么想出来的。有趣的是,在运行人工制品时,这种依赖关系仍在类路径中。
-
如果我没记错的话,我有一个非常大的依赖树,我开始通过专注于编译来缩小它,然后使用命令
gradle dependencies --configuration [compile|testCompile]进行测试编译。那时我碰巧注意到带有测试编译依赖项的 vaadin。但不确定它是否在完整的报告中。
标签: java spring spring-mvc spring-boot gradle