Error in converted maven project in Eclipse

I am using Eclipse Juno with the m2e plugin. I converted a java project to a maven project via Eclipse

Right click on project> goo configuration menu> Convert to maven project.

thats my pom.xml file

And these are the errors:

Multiple annotations found at this line:
- Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-
 plugin:2.3.2:compile (execution: default-compile, phase: compile)
- Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-
 plugin:2.3.2:testCompile (execution: default-testCompile, phase: test-compile)
- CoreException: Could not get the value for parameter compilerId for plugin execution default-
 compile: PluginResolutionException: Plugin org.apache.maven.plugins:maven-compiler-plugin:2.3.2 or one of 
 its dependencies could not be resolved: The following artifacts could not be resolved: 
 org.codehaus.plexus:plexus-compiler-manager:jar:1.8.1, org.codehaus.plexus:plexus-compiler-javac:jar:1.8.1: 
 Failure to transfer org.codehaus.plexus:plexus-compiler-manager:jar:1.8.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.codehaus.plexus:plexus-compiler-
 manager:jar:1.8.1 from/to central (http://repo.maven.apache.org/maven2): connection timed out to http://
 repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-compiler-manager/1.8.1/plexus-compiler-
 manager-1.8.1.jar
- CoreException: Could not get the value for parameter compilerId for plugin execution default-
 testCompile: PluginResolutionException: Plugin org.apache.maven.plugins:maven-compiler-plugin:2.3.2 or one 
 of its dependencies could not be resolved: The following artifacts could not be resolved: 
 org.codehaus.plexus:plexus-compiler-manager:jar:1.8.1, org.codehaus.plexus:plexus-compiler-javac:jar:1.8.1: 
 Failure to transfer org.codehaus.plexus:plexus-compiler-manager:jar:1.8.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.codehaus.plexus:plexus-compiler-
 manager:jar:1.8.1 from/to central (http://repo.maven.apache.org/maven2): connection timed out to http://
 repo.maven.apache.org/maven2/org/codehaus/plexus/plexus-compiler-manager/1.8.1/plexus-compiler-
 manager-1.8.1.jar

How to solve this problem? Please, help.

+5
source share
1 answer

Eclipse Juno has some problems when creating a Maven project, the best way is to create a Maven project, create Java and transform it.

Juno also has a problem with configuring the Maven lifecycle, in creating, compiling, installing. so please turn off your build automatically.

Follow the instructions below to resolve this issue.

, Eclipse .

goto- > window- > prefernces- > General- > .

-, Manaul . -, , , "".

.

Goto- > window- > prefernces- > Maven- > user settings

, xml settings.xml, .

: users\your name.m2

<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0
                      http://maven.apache.org/xsd/settings-1.0.0.xsd">
  <localRepository/>
  <interactiveMode/>
  <usePluginRegistry/>
  <offline/>
  <pluginGroups/>
  <servers/>
  <mirrors/>
  <proxies>
    <proxy>
      <id>myproxy</id>
      <active>true</active>
      <protocol>http</protocol>
      <host>proxy name</host>
      <port>number</port>
      <username></username>
      <password></password>
      <nonProxyHosts>localhost,127.0.0.1</nonProxyHosts>
    </proxy>
  </proxies>
  <profiles/>
  <activeProfiles/>
</settings>

, , . . . - mvn clean - mvn - mvn install

, .

+1

All Articles