Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-users] Eclipse standard m2e Maven task "generate-sources" | Custom bound plug-ins (here: "wsimport" of "jax-ws")

Dear Anders,

 

the Maven->Lifecycle Mapping has been verified. Indeed, the execution of the JAX-WS plugin is NOT listed there for the phase “generate-sources”. My question: how to modify it? Within Eclipse it seems not to be possible to do it directly in the GUI frontend. Right? Has it to be edited externally within a text editor?

 

Additionally, my understanding up to now: this lifecycle mapping does not concern the Maven lifecycle – does it? Is this file (see: Window -> Preferences -> Maven -> Lifecycle Mappings) just available for the Eclipse IDE to take care of the lifecycle mappings although they are available within the POM file?

 

The current file shows the content being attached.

 

Kind regards,

Holger

 

Von: m2e-users-bounces@xxxxxxxxxxx [mailto:m2e-users-bounces@xxxxxxxxxxx] Im Auftrag von Anders Hammar
Gesendet: Donnerstag, 28. Februar 2013 08:23
An: Maven Integration for Eclipse users mailing list
Betreff: Re: [m2e-users] Eclipse standard m2e Maven task "generate-sources" | Custom bound plug-ins (here: "wsimport" of "jax-ws")

 

Strange. I tested a project of mine which has the modello plugin bound to that phase and it works as expected. Could you right-click on your project, select Properties, then select Maven->Lifecycle Mapping. Be sure to check "Show lifecycle phases". Is the execution of the jax-ws plugin listed for the generate-sources phase?

For anyone to reproduce you will need to create a simple test project. It can later also be used to verify if this is in fact a bug in m2e.

 

/Anders

 

On Thu, Feb 28, 2013 at 8:17 AM, King Holger (CI/AFP2) <Holger.King@xxxxxxxxxxxx> wrote:

Dear m2e community,

I'm just using:
- Eclipse Juno 4.2
- Eclipse m2e 1.3.1
- Maven 3.xx

having a typical JAX-WS Maven plug-in mentioned in my POM whose default goal "wsimport" by default is assigned to the Maven "generate-sources" lifecycle phase (see: https://repository.sonatype.org/service/local/repositories/central-proxy/archive/org/jvnet/jax-ws-commons/jaxws-maven-plugin/2.2/jaxws-maven-plugin-2.2.jar/!/META-INF/maven/plugin.xml):

...
<plugin>
            <!-- the plug-in can be called via the configured alias
                  "goalPrefix" mentioned in the plugin descriptor of the
                  plugin -->
            <groupId>org.jvnet.jax-ws-commons</groupId>
            <artifactId>jaxws-maven-plugin</artifactId>
            <version>2.2</version>
            <executions>
                        <execution>
                                   <phase>generate-sources</phase>
                                   <goals>
                                               <goal>wsimport</goal>
                                   </goals>
                        </execution>
            </executions>
...
</plugin>
...

The problem: although this plug-in is bound to lifecycle phase "generate-sources", it's not taken into account when starting the m2e run task "Maven generate-sources" via:
- right-click on Eclipse project
- choose "Run as"
- select "9 Maven generate-sources"

This run is provided by default when installing m2e via the SpringSource tool suite.

I only get the following log output:
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
[INFO] Scanning for projects...
[INFO]
[INFO] ------------------------------------------------------------------------
[INFO] Building FirstSpiritWeb 1.0.0-BUILD-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 0.142s
[INFO] Finished at: Mon Feb 25 19:41:58 CET 2013
[INFO] Final Memory: 1M/15M
[INFO] ------------------------------------------------------------------------

When creating a custom run configuration, the plug-in is executed completely successfully. Any idea why that happens and how to solve?

Kind regards,
Holger

_______________________________________________
m2e-users mailing list
m2e-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/m2e-users

 

<?xml version="1.0" encoding="UTF-8"?>
<lifecycleMappingMetadata>
  <lifecycleMappings>
    <lifecycleMapping>
      <pluginExecutions>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-clean-plugin</artifactId>
            <versionRange>2.4.1</versionRange>
            <goals>
              <goal>clean</goal>
            </goals>
          </pluginExecutionFilter>
          <ignore />
          <comment>source: uninteresting</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-resources-plugin</artifactId>
            <versionRange>[2.4,)</versionRange>
            <goals>
              <goal>resources</goal>
              <goal>testResources</goal>
              <goal>copy-resources</goal>
            </goals>
          </pluginExecutionFilter>
          <action>
            <execute>
              <runOnIncremental>true</runOnIncremental>
            </execute>
          </action>
          <comment>source: default</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <versionRange>[2.0,)</versionRange>
            <goals>
              <goal>compile</goal>
              <goal>testCompile</goal>
            </goals>
            <parameters>
              <compilerId>javac</compilerId>
            </parameters>
          </pluginExecutionFilter>
          <action>
            <configurator>
              <id>org.eclipse.m2e.jdt.javaConfigurator</id>
            </configurator>
          </action>
          <comment>source: extension(org.eclipse.m2e.jdt_1.3.1.20130219-1424),extension(org.springframework.ide.eclipse.maven_3.1.0.201210040510-RELEASE)</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <versionRange>[2.0,)</versionRange>
            <goals>
              <goal>compile</goal>
              <goal>testCompile</goal>
            </goals>
          </pluginExecutionFilter>
          <action>
            <configurator>
              <id>com.springsource.sts.ide.maven.core.springProjectConfigurator</id>
            </configurator>
          </action>
          <comment>source: extension(org.eclipse.m2e.jdt_1.3.1.20130219-1424),extension(org.springframework.ide.eclipse.maven_3.1.0.201210040510-RELEASE)</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-resources-plugin</artifactId>
            <versionRange>[2.4,)</versionRange>
            <goals>
              <goal>resources</goal>
              <goal>testResources</goal>
              <goal>copy-resources</goal>
            </goals>
          </pluginExecutionFilter>
          <action>
            <execute>
              <runOnIncremental>true</runOnIncremental>
            </execute>
          </action>
          <comment>source: default</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <versionRange>[2.0,)</versionRange>
            <goals>
              <goal>compile</goal>
              <goal>testCompile</goal>
            </goals>
            <parameters>
              <compilerId>javac</compilerId>
            </parameters>
          </pluginExecutionFilter>
          <action>
            <configurator>
              <id>org.eclipse.m2e.jdt.javaConfigurator</id>
            </configurator>
          </action>
          <comment>source: extension(org.eclipse.m2e.jdt_1.3.1.20130219-1424),extension(org.springframework.ide.eclipse.maven_3.1.0.201210040510-RELEASE)</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-compiler-plugin</artifactId>
            <versionRange>[2.0,)</versionRange>
            <goals>
              <goal>compile</goal>
              <goal>testCompile</goal>
            </goals>
          </pluginExecutionFilter>
          <action>
            <configurator>
              <id>com.springsource.sts.ide.maven.core.springProjectConfigurator</id>
            </configurator>
          </action>
          <comment>source: extension(org.eclipse.m2e.jdt_1.3.1.20130219-1424),extension(org.springframework.ide.eclipse.maven_3.1.0.201210040510-RELEASE)</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-surefire-plugin</artifactId>
            <versionRange>2.10</versionRange>
            <goals>
              <goal>test</goal>
            </goals>
          </pluginExecutionFilter>
          <ignore />
          <comment>source: uninteresting</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-war-plugin</artifactId>
            <versionRange>2.2</versionRange>
            <goals>
              <goal>war</goal>
            </goals>
          </pluginExecutionFilter>
          <ignore />
          <comment>source: uninteresting</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-install-plugin</artifactId>
            <versionRange>2.3.1</versionRange>
            <goals>
              <goal>install</goal>
            </goals>
          </pluginExecutionFilter>
          <ignore />
          <comment>source: uninteresting</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-deploy-plugin</artifactId>
            <versionRange>2.7</versionRange>
            <goals>
              <goal>deploy</goal>
            </goals>
          </pluginExecutionFilter>
          <ignore />
          <comment>source: uninteresting</comment>
        </pluginExecution>
        <pluginExecution>
          <pluginExecutionFilter>
            <groupId>org.apache.maven.plugins</groupId>
            <artifactId>maven-site-plugin</artifactId>
            <versionRange>3.0</versionRange>
            <goals>
              <goal>site</goal>
            </goals>
          </pluginExecutionFilter>
          <ignore />
          <comment>source: uninteresting</comment>
        </pluginExecution>
      </pluginExecutions>
    </lifecycleMapping>
  </lifecycleMappings>
</lifecycleMappingMetadata>

Back to the top