Maven .m2 compiler errors in pom.xml

I need to compile my project but it fails in my pom.xml. The first error is:

Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:2.3.2:compile (execution: default- compile, phase: compile)

and the second:

Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler- plugin:2.3.2:testCompile (execution: default-testCompile, phase: test-compile)

I have tried too many things in my settings.xml.

1) Actually, mi maven=> installations is embedded pointing to my settings.xml of apache maven 2.2-1

2) Maven=> user settings. is pointing to the correct settings.xml of apache maven 2.2.1. and y erased all the folders in m2/repository.

3) I have tried to put maven offline because I have the jars so I don't need necessary to work with a repository.

4) I have tried to update=>maven prject=> force update of snapshts/releases, offline and no offline. Both cases are useless.

5) I can't enter any commands in console or in pom.xml because I have these compile errors. So maven install, clean , force or any command is impossible.

6) I've tried to put in pom.xml these plugins that say the console error but it's useless too.

7) My settings.xml proxies tags are correct

<proxies>
    <proxy>
        <active>?</active>
        <host>?</host>
        <port>?</port>

        <nonProxyHosts>?</nonProxyHosts>
    </proxy>
</proxies>

I don't know what more I can do. Please give me an advice or information.


<?xml version="1.0" encoding="UTF-8"?>
<project
    xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
    xmlns="http://maven.apache.org/POM/4.0.0" 
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <modelVersion>4.0.0</modelVersion>

<!--    <parent> -->
<!--        <groupId>es.chx</groupId> -->
<!--        <artifactId>parent-pom</artifactId> -->
<!--        <version>2.0-SNAPSHOT</version> -->
<!--    </parent> -->

    <groupId>es.chx.gestionEnvios</groupId>
    <artifactId>gestionEnvios</artifactId>
    <version>1.0</version>
    <name>gestionEnvios</name>

    <properties>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
        <org.springframework-version>2.5</org.springframework-version>
    </properties>

    <dependencies>

        <dependency>
            <groupId>es.chx</groupId>
            <artifactId>arq-chx</artifactId>
            <version>1.0-SNAPSHOT</version>
        </dependency>

<!--        <dependency> -->
<!--            <groupId>es.chx.web</groupId> -->
<!--            <artifactId>loginLiferayFromApp</artifactId> -->
<!--            <version>1.0-SNAPSHOT</version> -->
<!--        </dependency> -->

<!--        <dependency> -->
<!--            <groupId>es.chx.web</groupId> -->
<!--            <artifactId>commonWeb</artifactId>  -->
<!--            <version>1.0-SNAPSHOT</version> -->
<!--        </dependency> -->

<!-- -->        <dependency> 
<!-- -->            <groupId>es.chx.intranet</groupId> 
<!--  -->           <artifactId>commonIntranet</artifactId>
<!-- -->            <version>1.0</version> 
<!-- -->        </dependency> 

        <dependency>
            <groupId>displaytag</groupId>
            <artifactId>displaytag-doc</artifactId>
            <version>1.2</version>
            <type>pom</type>
        </dependency>

        <dependency>
            <groupId>displaytag</groupId>
            <artifactId>displaytag</artifactId>
            <version>1.2</version>
        </dependency>

        <dependency>
            <groupId>displaytag</groupId>
            <artifactId>displaytag-export-poi</artifactId>
            <version>1.2</version>
        </dependency>

        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-context</artifactId>
            <version>${org.springframework-version}</version>
        </dependency>

        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-webmvc</artifactId>
            <version>${org.springframework-version}</version>
        </dependency>

        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-aop</artifactId>
            <version>${org.springframework-version}</version>
        </dependency>

        <dependency>
            <groupId>org.ajaxtags</groupId>
            <artifactId>ajaxtags</artifactId>
            <version>1.3-beta-rc7</version>
        </dependency>

        <dependency>
            <groupId>net.sf.json-lib</groupId>
            <artifactId>json-lib</artifactId>
            <version>2.2.3</version>
            <type>pom</type>
        </dependency>

        <dependency>
            <groupId>net.sf.json-lib</groupId>
            <artifactId>json-lib-ext-spring</artifactId>
            <version>1.0.2</version>
        </dependency>

        <dependency>
            <groupId>es.chx.web</groupId>
            <artifactId>dwr</artifactId>
            <version>3.0</version>
        </dependency>

        <dependency>
            <groupId>cglib</groupId>
            <artifactId>cglib</artifactId>
            <version>2.2.2</version>
            <scope>compile</scope>
        </dependency>

        <dependency>
            <groupId>javax.inject</groupId>
            <artifactId>javax.inject</artifactId>
            <version>1</version>
        </dependency>

        <dependency>
            <groupId>javax.validation</groupId>
            <artifactId>validation-api</artifactId>
            <version>1.0.0.GA</version>
            <scope>compile</scope>
        </dependency>

        <dependency>
            <groupId>org.hibernate</groupId>
            <artifactId>hibernate-validator</artifactId>
            <version>4.2.0.Final</version>
            <scope>compile</scope>
            <exclusions>
                <exclusion>
                    <artifactId>slf4j-api</artifactId>
                    <groupId>org.slf4j</groupId>
                </exclusion>
            </exclusions>
        </dependency>

        <dependency>
            <groupId>jstl</groupId>
            <artifactId>jstl</artifactId>
            <version>1.2</version>
        </dependency>

        <dependency>
            <groupId>log4j</groupId>
            <artifactId>log4j</artifactId>
            <version>1.2.14</version>
        </dependency>

        <dependency>
            <groupId>commons-validator</groupId>
            <artifactId>commons-validator</artifactId>
            <version>1.4.0</version>
        </dependency>

        <dependency>
            <groupId>commons-lang</groupId>
            <artifactId>commons-lang</artifactId>
            <version>2.6</version>
        </dependency>

        <dependency>
            <groupId>javax.servlet</groupId>
            <artifactId>jsp-api</artifactId>
            <version>2.0</version>
            <scope>provided</scope>
        </dependency>

        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-tx</artifactId>
            <version>2.5</version>
        </dependency>

        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-jdbc</artifactId>
            <version>2.5</version>
        </dependency>

        <dependency>
            <groupId>commons-dbcp</groupId>
            <artifactId>commons-dbcp</artifactId>
            <version>1.2.2</version>
        </dependency>

        <dependency>
            <groupId>com.oracle</groupId>
            <artifactId>ojdbc14</artifactId>
            <version>10.2.0.2.0</version>
        </dependency>

        <dependency>
            <groupId>junit</groupId>
            <artifactId>junit</artifactId>
            <version>4.4</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>org.springframework</groupId>
            <artifactId>spring-test</artifactId>
            <version>2.5</version>
            <scope>test</scope>
        </dependency>

        <dependency>
            <groupId>com.lowagie</groupId>
            <artifactId>itext</artifactId>
            <version>1.3</version>
        </dependency>

    </dependencies>

    <repositories>
        <repository>
            <releases>
                <enabled>true</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
            <id>nexus-chrono</id>
            <url>http://192.168.241.125:8081/nexus/content/groups/public/</url>
        </repository>
        <repository>
            <id>apache.snapshots</id>
            <name>Maven Plugin Snapshots</name>
            <url>http://repository.apache.org/snapshots/</url>
            <releases>
                <enabled>false</enabled>
            </releases>
            <snapshots>
                <enabled>true</enabled>
            </snapshots>
        </repository>
    </repositories>

    <build>
        <plugins>

            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-war-plugin</artifactId>
                <version>2.1.1</version>
                <configuration></configuration>
            </plugin>

            <plugin>
                <artifactId>maven-eclipse-plugin</artifactId>
                <version>2.9</version>
                <configuration>
                    <additionalProjectnatures>
                        <projectnature>org.springframework.ide.eclipse.core.springnature</projectnature>
                    </additionalProjectnatures>
                    <additionalBuildcommands>
                        <buildcommand>org.springframework.ide.eclipse.core.springbuilder</buildcommand>
                    </additionalBuildcommands>
                    <downloadSources>true</downloadSources>
                    <downloadJavadocs>true</downloadJavadocs>
                </configuration>
            </plugin>
        </plugins>
    </build>

</project>

And the errors that I receive:

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)


Well i think that i have solved it. Finally i installed the STS(Spring Tools Suite), with the latest plugins of m2e. The errors no exists longer. However ive got other errors but they are from rights of my repository. So... the solution was to install STS in my computer as IDE.

链接地址: http://www.djcxy.com/p/87284.html

上一篇: UnsupportedClassVersionError:org / apache / maven / plugin / compiler / TestCompilerMojo

下一篇: pom.xml中的Maven .m2编译器错误