java Ivy的transitive=“false”在从Nexus下载时被忽略
在我们公司,我们正在将旧的常春藤存储库迁移到Nexus
在将我们自己的工件上传到Nexus之后,我尝试下载一些项目的依赖项来测试设置,但是SpringWeb失败了。让我解释一下
这是常春藤的设置。仅指向本地Nexus安装的xml文件
<?xml version="1.0" encoding="ISO-8859-1"?>
<ivysettings>
<settings defaultResolver="default" />
<resolvers>
<ibiblio name="nexus" m2compatible="true" root="http://nexus.local/nexus/content/repositories/central/" />
<ibiblio name="our-nexus" m2compatible="true" root="http://nexus/nexus/content/repositories/repo" />
<chain name="default" returnFirst="true">
<resolver ref="our-nexus" />
<resolver ref="nexus" />
</chain>
</resolvers>
</ivysettings>
在我们的一个项目中,我们使用SpringWeb,但不是它的所有依赖项,所以我声明
<dependency org="org.springframework" name="spring-web" rev="3.0.5.RELEASE" transitive="false" />
这在使用Ivy存储库时效果很好。但是今天我无法执行<ivy:retrieve>
任务,因为它找不到com.caucho#hessian#3.2.1
<ivy:report>
任务说,SpringWeb需要这种版本的hessian3.2.11.RELEASE
但我已经宣布transitive="false"
为什么不起作用?我错过了什么
# 1 楼答案
应该有用。我个人更喜欢配置映射。请尝试以下方法:
有关更多详细信息,请参阅: