1.报错内容:

Multiple annotations found at this line:

    - Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-resources-plugin:2.5:testResources (execution: default-
     testResources, phase: process-test-resources)
    - Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-resources-plugin:2.5:resources (execution: default-

     resources, phase: process-resources)

2创建maven项目工程packaging报错创建maven项目工程packaging报错

3.解决方法:在pom.xml文件内添加如下代码:

<build>
  <pluginManagement>
        <plugins>
            <plugin>
                <groupId>org.eclipse.m2e</groupId>
                <artifactId>lifecycle-mapping</artifactId>
                <version>1.0.0</version>
                <configuration>
                    <lifecycleMappingMetadata>
                        <pluginExecutions>
                            <pluginExecution>
                                <pluginExecutionFilter>
                                    <groupId>org.apache.maven.plugins</groupId>
                                    <artifactId>maven-resources-plugin</artifactId>
                                    <versionRange>[2.0,)</versionRange>
                                    <goals>
                                        <goal>resources</goal>
                                        <goal>testResources</goal>
                                    </goals>
                                </pluginExecutionFilter>
                                <action>
                                    <ignore />
                                </action>
                            </pluginExecution>
                        </pluginExecutions>
                    </lifecycleMappingMetadata>
                </configuration>
            </plugin>
        </plugins>
    </pluginManagement>
    </build>

4此时报错问题解决

5创建maven项目工程packaging报错


6此时发现的错误是由于未刷新项目导致的,见上图按照上图提示解决即可,(alt+F5)

7创建maven项目工程packaging报错

8

9创建maven项目工程packaging报错创建maven项目工程packaging报错

10.问题解决

11.原因分析:个人猜测可能是由于jar包冲突所致(鄙人小白),希望大神给予详细解答,十分感谢!

相关文章:

  • 2021-06-10
  • 2021-12-21
  • 2021-05-03
  • 2021-10-19
  • 2021-05-17
  • 2021-12-16
  • 2021-04-21
  • 2021-10-31
猜你喜欢
  • 2021-06-12
  • 2021-12-17
  • 2021-10-19
  • 2021-10-26
  • 2021-11-27
  • 2021-10-29
  • 2021-06-06
相关资源
相似解决方案