I am trying to build my project but I get this:
Non-resolvable parent POM: Could not transfer artifact org.springframework.boot:spring-boot-starter-parent:pom:1.3.0.M3 from/to spring-snapshots (http://repo.spring.io/snapshot): repo.spring.io and 'parent.relativePath' points at no local POM @ line 16, column 10: Unknown host repo.spring.io -> [Help 2]
Here is how I specify the parent of my pom.xml:
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.3.0.M3</version>
<relativePath></relativePath>
</parent>
The is empty so that it forces maven to look for the parent in the remote repository. However, it says that repo.spring.io is an unknown host.
Here is how I define the repositories in my pom.xml:
<repositories>
<repository>
<id>spring-snapshots</id>
<url>http://repo.spring.io/snapshot</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</repository>
<repository>
<id>spring-milestones</id>
<url>http://repo.spring.io/milestone</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>spring-snapshots</id>
<url>http://repo.spring.io/snapshot</url>
</pluginRepository>
<pluginRepository>
<id>spring-milestones</id>
<url>http://repo.spring.io/milestone</url>
</pluginRepository>
</pluginRepositories>
Any ideas?
Obviously it's a problem with your internet connection. Check, if you can reach http://repo.spring.io with your browser. If yes, check if you need to configure a proxy server. If no, you should contact your internet provider.
Here is the documentation, how you configure a proxy server for Maven: https://maven.apache.org/guides/mini/guide-proxies.html
For anyone stumbling upon this question, I'll post the solution to a similar problem (same error message except for the uknown host
part).
Since January 15, 2020 maven central no longer supports HTTP, in favour of HTTPS. Consequently, spring repositories switched to HTTPS as well
The solution is therefore to change the urls from http://repo.spring.io/milestone
to https://repo.spring.io/milestone
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With