生命周期配置 AppEngine 未涵盖插件执行
Posted
技术标签:
【中文标题】生命周期配置 AppEngine 未涵盖插件执行【英文标题】:Plugin execution not covered by lifecycle configuration AppEngine 【发布时间】:2013-09-04 02:35:51 【问题描述】:在以下 Eclipse m2e 问题上需要帮助:
生命周期配置未涵盖插件执行:com.google.appengine:appengine-maven-plugin:1.8.3:endpoints_get_discovery_doc(执行:默认,阶段:编译)
<plugin>
<groupId>com.google.appengine</groupId>
<artifactId>appengine-maven-plugin</artifactId>
<version>1.8.3</version>
<configuration>
<enableJarClasses>false</enableJarClasses>
</configuration>
<executions>
**<execution>**
<goals>
<goal>endpoints_get_discovery_doc</goal>
</goals>
</execution>
</executions>
</plugin>
有什么想法吗? pom.xml 看起来像:https://github.com/GoogleCloudPlatform/appengine-endpoints-tictactoe-java-maven/blob/master/pom.xml
【问题讨论】:
【参考方案1】:把它放在你的 pom 的 <build>
部分
<pluginManagement>
<plugins>
<plugin>
<groupId>org.eclipse.m2e</groupId>
<artifactId>lifecycle-mapping</artifactId>
<version>1.0.0</version>
<configuration>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>com.google.appengine</groupId>
<artifactId>appengine-maven-plugin</artifactId>
<versionRange>[1.8.3,)</versionRange>
<goals>
<goal>endpoints_get_discovery_doc</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore></ignore>
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
</configuration>
</plugin>
</plugins>
</pluginManagement>
来源:M2Eclipse documentation
【讨论】:
【参考方案2】:How to solve "Plugin execution not covered by lifecycle configuration" for Spring Data Maven Builds已回答此问题
唯一的区别是,在您的情况下,您必须将 pluginExecutionFilter 标记替换为:
<pluginExecutionFilter>
<groupId>com.google.appengine</groupId>
<artifactId>appengine-maven-plugin</artifactId>
<versionRange>1.8.3</versionRange>
<goals>
<goal>test-compile</goal>
<goal>compile</goal>
</goal>
</pluginExecutionFilter>
【讨论】:
以上是关于生命周期配置 AppEngine 未涵盖插件执行的主要内容,如果未能解决你的问题,请参考以下文章
生命周期配置未涵盖插件执行(JBossas 7 EAR 原型)