我尝试使用Spring,但在我的pom.xml中似乎存在一些问题,无法解决Spring依赖关系。项目在本地没有解决的Maven中存在依赖关系(Spring-security依赖关系)
在pom.xml中,我有以下库:
<repositories>
<repository>
<id>repository.springframework.maven.release</id>
<name>Spring Framework Maven Release Repository</name>
<url>http://maven.springframework.org/release</url>
</repository>
</repositories>
<!-- Spring Core framework -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-core</artifactId>
<version>4.3.2.RELEASE</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<version>4.3.2.RELEASE</version>
</dependency>
<!-- Spring security framework -->
<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-web</artifactId>
<version>4.1.2.RELEASE</version>
</dependency>
<dependency>
<groupId>org.springframework.security</groupId>
<artifactId>spring-security-config</artifactId>
<version>4.1.2.RELEASE</version>
</dependency>
我总是有:无法解析项目依赖,下面的文物无法解析:
org.springframework.security:spring-security-web:jar:4.1.2.RELEASE
aopalliance:aopalliance:jar:1.0
org.springframework.security:spring-security-core:jar:4.1.2.RELEASE
org.springframework:spring-expression:jar:4.3.1.RELEASE
org.springframework.security:spring-security-config:jar:4.1.2.RELEASE
即使我在pom.xml中使用另一个存储库,甚至删除存储库以使用maven中的默认存储库,它也一样,没有任何改变。从Maven的
完整的错误消息:
Failed to execute goal on project Aegyptologie: Could not resolve dependencies for project de.unileipzig.wirote:Aegyptologie:war:0.1-SNAPSHOT: The following artifacts could not be resolved: org.springframework:spring-core:jar:4.3.2.RELEASE, org.springframework:spring-web:jar:4.3.2.RELEASE, org.springframework:spring-aop:jar:4.3.2.RELEASE, org.springframework:spring-beans:jar:4.3.2.RELEASE, org.springframework:spring-context:jar:4.3.2.RELEASE, org.springframework.security:spring-security-web:jar:4.1.2.RELEASE, aopalliance:aopalliance:jar:1.0, org.springframework.security:spring-security-core:jar:4.1.2.RELEASE, org.springframework:spring-expression:jar:4.3.1.RELEASE, org.springframework.security:spring-security-config:jar:4.1.2.RELEASE: Could not transfer artifact org.springframework:spring-core:jar:4.3.2.RELEASE from/to repository.springframework.maven.release (http://maven.springframework.org/release): Connection reset -> [Help 1]
To see the full stack trace of the errors, re-run Maven with the -e switch.
Re-run Maven using the -X switch to enable full debug logging.
For more information about the errors and possible solutions, please read the following articles:
[Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
我怎样才能解决呢?
你是在代理的后面吗? –
您能否提供来自Maven的完整错误消息? – Daniel
@ A_Di-Matteo不,我不使用任何代理 –