【发布时间】:2018-03-18 15:48:12
【问题描述】:
我的项目中成功构建了 6 个左右的 maven 依赖项。但是,当我尝试添加 JDBC 依赖项时,我收到所有现有工件的错误消息:
缺少工件 mysql:mysql-connector-java:jar:5.1.6
缺少工件 org.springframework:spring-aop:jar:3.2.3.RELEASE
缺少工件 org.springframework:spring-beans:jar:3.2.3.RELEASE
缺少工件 org.springframework:spring-context:jar:3.2.3.RELEASE
缺少工件 org.springframework:spring-core:jar:3.2.3.RELEASE
缺少工件 org.springframework:spring-expression:jar:3.2.3.RELEASE
缺少工件 org.springframework:spring-jdbc:jar:4.3.10.RELEASE
这是我要添加的依赖项:(看起来像有效的 XML)
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<version>4.3.10.RELEASE</version>
</dependency>
我已经检查过,根据 Maven 站点,4.3.10.RELEASE 是一个有效的版本。
有谁知道为什么添加这个依赖会导致整个 Pom.xml 出错?
【问题讨论】: