0

Getting error when setting up Eclipse and IntelliJ with maven:

1) Eclipse ------->

a) Error 1:

Caused by: org.eclipse.aether.transfer.ArtifactTransferException: Could not tran
sfer artifact org.apache.maven.plugins:maven-resources-plugin:pom:2.7 from/to ce
ntral (https://repo.maven.apache.org/maven2): repo.maven.apache.org

b) Error 2:

CoreException: Could not calculate build plan: Plugin org.apache.maven.plugins:maven-compiler-plugin:3.1 or one of its dependencies could not be 
     resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-compiler-plugin:jar:3.1: ArtifactResolutionException: Failure to transfer 
     org.apache.maven.plugins:maven-compiler-plugin:pom:3.1 from http://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be 
     reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer artifact org.apache.maven.plugins:maven-
     compiler-plugin:pom:3.1 from/to central (http://repo.maven.apache.org/maven2): repo.maven.apache.org
    - CoreException: Could not calculate build plan: Plugin org.apache.maven.plugins:maven-compiler-plugin:3.1 or one of its dependencies could not be 
     resolved: Failed to read artifact descriptor for org.apache.maven.plugins:maven-compiler-plugin:jar:3.1: ArtifactResolutionException: Could not transfer artifact 
     org.apache.maven.plugins:maven-compiler-plugin:pom:3.1 from/to central (http://repo.maven.apache.org/maven2): repo.maven.apache.org
    - Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:3.1:testCompile (execution: default-
     testCompile, phase: test-compile)
    - Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:3.1:compile (execution: default-compile, 
     phase: compile)

2) IntelliJ Error ------->

Failed to read Artifact descriptor 

... I have set up Maven on Windows and tried to compile from Commandline too but getting error:

3) MVN Command-Line Error ------->

a)

Caused by: org.eclipse.aether.transfer.ArtifactTransferException: Could not tran
    sfer artifact org.apache.maven.plugins:maven-resources-plugin:pom:2.7 from/to ce
    ntral (https://repo.maven.apache.org/maven2): repo.maven.apache.org

b) Caused by: java.net.UnknownHostException: repo.maven.apache.org

Voila
  • 85
  • 2
  • 15
  • Are you trying this from behind a firewall? Check that nothing is blocking your traffic to repo.maven.apache.org – randal4 Aug 21 '18 at 15:59
  • Yes I am behind a firewall and have added PROXY in IntelliJ IDEA which when tested thru the , shows its successful. I get this error for each Dependency in MAVEN POM.xml file: FAILED TO READ ARTIFACT DESCRIPTOR – Voila Aug 21 '18 at 16:16
  • Do you have your proxy setup for http AND https? How are you testing the connection? – randal4 Aug 21 '18 at 16:17
  • In INTELLIJ IDEA --> Settings --> HTTP PROXY, I have selected - Manual Proxy Configuration - HTTP (NOT SOCKS) – Voila Aug 21 '18 at 16:19
  • Take a step back and try `ping repo.maven.apache.org` and see if you get a response. If not, setup proxy settings in your machine. If your workplace gives an autoproxy use that. – Bajal Aug 21 '18 at 17:21
  • For Eclipse and the MVN command line see https://stackoverflow.com/q/7737710 – howlger Aug 21 '18 at 19:41
  • IntelliJ is fixed... I created and added Proxy information to it. Thats all, the dependencies kept flowing in. @howlger, will check the post you mentioned. Thanks all. – Voila Aug 21 '18 at 20:41

0 Answers0