生命周期配置未涵盖的插件执行(JBossas 7 EAR 原型) [英] Plugin execution not covered by lifecycle configuration (JBossas 7 EAR archetype)

查看:41
本文介绍了生命周期配置未涵盖的插件执行(JBossas 7 EAR 原型)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用 Eclipse 3.7 Indigo 和 Maven M2E 插件 1.0.100.

I am using Eclipse 3.7 Indigo with Maven M2E Plugin 1.0.100.

使用 JBoss 7.x JavaEE 6 EAR 原型,EAR 的 pom 给了我这个错误:

Using the JBoss 7.x JavaEE 6 EAR archetype, the pom for EAR is giving me this error:

生命周期配置未涵盖的插件执行:org.apache.maven.plugins:maven-ear-plugin:2.6:generate-application-xml(执行:default-generate-application-xml,阶段:生成资源)

Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-ear-plugin:2.6:generate-application-xml (execution: default-generate-application-xml, phase: generate-resources)

<plugin>
   <groupId>org.apache.maven.plugins</groupId>
   <artifactId>maven-ear-plugin</artifactId>
   <version>2.6</version>
   <configuration>
      <!-- Tell Maven we are using Java EE 6 -->
      <version>6</version>
      <!-- Use Java EE ear libraries as needed. Java EE ear libraries 
                  are in easy way to package any libraries needed in the ear, and automatically 
                  have any modules (EJB-JARs and WARs) use them -->
      <defaultLibBundleDir>lib</defaultLibBundleDir>
      <modules></modules>
   </configuration>
<plugin>

推荐答案

这是 M2E 插件的一个特性",它已经在不久前推出了.它与 JBoss EAR 插件没有直接关系,但也会发生在大多数其他 Maven 插件中.

This is a "feature" of the M2E plugin that had been introduced a while ago. It's not directly related to the JBoss EAR plugin but also happens with most other Maven plugins.

如果你在你的pom中定义了插件执行(比如maven-ear-plugin:generate-application-xml的执行),你还需要添加M2E 的附加配置信息,它告诉 M2E 在 Eclipse 中运行构建时要做什么,例如如果插件执行被 M2E 忽略或执行,是否也应该为增量构建完成,...如果缺少该信息,M2E 会通过显示以下错误消息来抱怨它:

If you have a plugin execution defined in your pom (like the execution of maven-ear-plugin:generate-application-xml), you also need to add additional config information for M2E that tells M2E what to do when the build is run in Eclipse, e.g. should the plugin execution be ignored or executed by M2E, should it be also done for incremental builds, ... If that information is missing, M2E complains about it by showing this error message:

生命周期配置未涵盖插件执行"

"Plugin execution not covered by lifecycle configuration"

有关更详细的说明和一些需要添加到 pom 中以消除该错误的示例配置,请参见此处:

See here for a more detailed explanation and some sample config that needs to be added to the pom to make that error go away:

https://www.eclipse.org/m2e/documentation/m2e-execution-not-covered.html

这篇关于生命周期配置未涵盖的插件执行(JBossas 7 EAR 原型)的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆