正在回答
同学你好,建议同学去本地仓库中,查找一下maven-compiler-plugin,如:
建议同学删除3.1的版本,重新创建maven项目再试试。
如果在创建的过程中还遇到错误,建议同学将报错贴一下。
祝:学习愉快~
可以了,找到的原因是lifecycleMappingMetadata配置问题导致的,这个应该怎么配置的呢,现在只是把对应的项给配置了,担心没有配置对后面还会有问题。
<?xml version="1.0" encoding="UTF-8" ?>
<lifecycleMappingMetadata>
<pluginExecutions>
<pluginExecution>
<pluginExecutionFilter>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<versionRange>[2.6, )</versionRange>
<goals>
<goal>copy</goal>
</goals>
</pluginExecutionFilter>
<action>
<ignore />
</action>
</pluginExecution>
</pluginExecutions>
</lifecycleMappingMetadata>
不行,还是报错了。
Errors occurred during the build.
Errors running builder 'Maven Project Builder' on project 'fist-maven'.
Missing parameter for pluginExecutionFilter. groupId, artifactId, versionRange and goals must be specificed, but found: groupId = 'null'
artifactId = 'null'
versionRange = 'null'
goals = '[compile, test-compile]'
An internal error occurred during: "Creating project "maven-first"".
Missing parameter for pluginExecutionFilter. groupId, artifactId, versionRange and goals must be specificed, but found: groupId = 'null'
artifactId = 'null'
versionRange = 'null'
goals = '[compile, test-compile]'
老师好,按照操作提示这个了,也没找到相关的解决方法。
An internal error occurred during: "Creating project "maven-first"".
Missing parameter for pluginExecutionFilter. groupId, artifactId, versionRange and goals must be specificed, but found: groupId = 'null'
artifactId = 'null'
versionRange = 'null'
goals = '[compile, test-compile]'
Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:3.1:testCompile (execution: default-testCompile, phase: test-compile)
CoreException: Could not get the value for parameter compilerId for plugin execution default-testCompile: PluginResolutionException: Plugin org.apache.maven.plugins:maven-compiler-plugin:3.1 or one of its dependencies could not be resolved: The following artifacts could not be resolved: org.codehaus.plexus:plexus-container-default:jar:1.5.5, org.codehaus.plexus:plexus-classworlds:jar:2.2.2, org.apache.xbean:xbean-reflect:jar:3.4, log4j:log4j:jar:1.2.12, commons-logging:commons-logging-api:jar:1.1, com.google.collections:google-collections:jar:1.0, junit:junit:jar:3.8.2: Failure to transfer org.codehaus.plexus:plexus-container-default:jar:1.5.5 from https://repo.maven.apache.org/maven2 was cached in the local repository, resolution will not be reattempted until the update interval of central has elapsed or updates are forced. Original error: Could not transfer artifact org.codehaus.plexus:plexus-container-default:jar:1.5.5 from/to central (https://repo.maven.apache.org/maven2): The operation was cancelled.
- 参与学习 人
- 提交作业 357 份
- 解答问题 8016 个
本阶段将带你学习MySQL数据库,JDBC接口,MyBatis框架等,带你掌握的数据的存放和管理。
了解课程
恭喜解决一个难题,获得1积分~
来为老师/同学的回答评分吧
0 星