场景描写叙述

开发项目搞环境是一个很蛋疼的问题。总是会遇到各种奇葩的问题,上一篇文章http://blog.csdn.net/gao36951/article/details/50955526中遇到的问题,本以为攻克了就OK了。可是结果却不尽人意。攻克了一个问题,又来了另外一个问题例如以下图



查看项目的Maven生命周期例如以下



错误内容粘贴例如以下

Multiple annotations found at this line:
- Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:2.5.1:compile (execution: default-compile, phase: compile)
- Plugin execution not covered by lifecycle configuration: org.apache.maven.plugins:maven-compiler-plugin:2.5.1:testCompile (execution: default-testCompile, phase: test-compile)
- CoreException: Could not calculate build plan: Plugin org.apache.maven.plugins:maven-compiler-plugin:2.5.1 or one of its dependencies could not be resolved: Failed to read artifact descriptor for
org.apache.maven.plugins:maven-compiler-plugin:jar:2.5.1: ArtifactResolutionException: Failure to transfer org.apache.maven.plugins:maven-compiler-plugin:pom:2.5.1 from http://120.52.145.47:443/content/groups/public/ was
cached in the local repository, resolution will not be reattempted until the update interval of nexus has elapsed or updates are forced. Original error: Could not transfer artifact org.apache.maven.plugins:maven-compiler-
plugin:pom:2.5.1 from/to nexus (http://120.52.145.47:443/content/groups/public/): Not authorized by proxy , ReasonPhrase:Proxy Authorization Required.

解决方式

在project中加入例如以下。然后再看错误没有了,项目的maven生命周期也正常了

<build>
<finalName>seckill</finalName>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<version>3.0</version>
<configuration>
<source>1.6</source>
<target>1.6</target>
<encoding>UTF8</encoding>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-war-plugin</artifactId>
<version>2.4</version>
<configuration>
<webResources>
<resource>
<directory>src/main/webapp</directory>
<excludes>
<exclude>*.jsp</exclude>
</excludes>
</resource>
</webResources>
</configuration>
</plugin>
</plugins>
</pluginManagement>
</build>

參考:http://www.myexception.cn/open-source/1658207.html

Maven项目中遇到的奇葩问题(续)的更多相关文章

  1. 如何查看Maven项目中的jar包依赖树情况

    对于开发人员,我想大家对于Maven应该不会陌生吧,如何在一个Maven项目中对这个项目中所引用的第三方jar包有个直观的了解呢? 其实实现很简单,只需要借助于Maven的一条命令,如下所示: mvn ...

  2. 在maven项目中解决第三方jar包依赖的问题

    在maven项目中,对于那些在maven仓库中不存在的第三方jar,依赖解决通常有如下解决方法: 方法1:直接将jar包拷贝到项目指定目录下,然后在pom文件中指定依赖类型为system,如: < ...

  3. Java项目和maven项目中如何获取&设置配置文件中的属性

    通常情况下,我们会在一些配置文件文件中配置一些属性.如: indexPath = E\:\\Tomcat_7.0\\webapps\\ipost_stage\\lucene\\index imgUpl ...

  4. Maven项目中,系统设置的CLASSPATH环境变量问题

    在Maven项目中,系统的CLASSPATH环境变量失效了吗?在用Maven开发登录网站时,servlet-api出现错误,jdbc也出现错误,都是ClassNotFoundException,但这两 ...

  5. Intellij IDEA 中如何查看maven项目中所有jar包的依赖关系图(转载)

    Intellij IDEA 中如何查看maven项目中所有jar包的依赖关系图 2017年04月05日 10:53:13 李学凯 阅读数:104997更多 所属专栏: Intellij Idea   ...

  6. maven项目中利用jmeter-maven-plugin插件直接执行jmeter jmx脚本

    jmeter脚本需要执行脚本,先得下载jmeter并解压jmeter.如想在maven项目中通过mvn install 直接执行jmx文件,这样就能在测试服务器上通过一个命令就能执行下性能测试了,给自 ...

  7. IDEA的maven项目中 静态文件编译的问题

    IDEA的maven项目中,默认源代码目录下的xml等资源文件并不会在编译的时候一块打包进classes文件夹,而是直接舍弃掉. 如果使用的是Eclipse,Eclipse的src目录下的xml等资源 ...

  8. 在Maven项目中,指定使用阿里云仓库下载jar包

    Maven项目中,在pom.xml的</project>标签之前加入一下标签,指定使用阿里云仓库下载jar包. <!-- 使用aliyun maven --> <repo ...

  9. maven项目中的报错问题——Dynamic Web Module 3.0 requires Java 1.6 or newer.

    转自:http://www.cnblogs.com/beppezhang/p/5919221.html maven项目中的报错问题——Dynamic Web Module 3.0 requires J ...

随机推荐

  1. Chrome 引起的蓝屏 MULTIPLE_IRP_COMPLETE_REQUESTS (44)

    如果你使用Chrome的时候出现经常性蓝屏, 可以试试这么做, 或许问题就解决了.

  2. 学习嵌入式开发板的Android平台体系结构和源码结构

    本文转自迅为论坛资料:http://www.topeetboard.com 推荐学习嵌入式开发板平台:iTOP-4412开发板 下面这张图出自Google官方,展示了Android系统的主要组成部分. ...

  3. xcode 通配搜索

    class \w*<\w*> extension \w*: \w* \{\} 搜索所有泛型类.

  4. 以JSONobject形式提交http请求

    总结一下设置图标的三种方式: (1)button属性:主要用于图标大小要求不高,间隔要求也不高的场合. (2)background属性:主要用于能够以较大空间显示图标的场合. (3)drawableL ...

  5. CAD参数绘制图案填充(网页版)

    绘制工程图,常常需要将某种图案填充到某一区域,例如剖面线的绘制.MxCAD提供了丰富的填充图案,可以利用这些图案进行快速填充. js中实现代码说明: function DrawPathToHatch2 ...

  6. CAD参数绘制椭圆(网页版)

    在CAD设计时,需要绘制椭圆,用户可以设置椭圆的基本属性. 主要用到函数说明: _DMxDrawX::DrawEllipse 绘制椭圆.详细说明如下: 参数 说明 DOUBLE dCenterX 椭圆 ...

  7. viewstate 与 session 区别

    Session存在于服务器端可以跨页面.耗费服务器资源.ViewState载体是页面文件,消耗带宽. EG: viewstate是存储在客户端的隐藏信息,当服务器接受请求回传时可以将viewstate ...

  8. css hack解决方案

    现在大家做项目的时候估计很多都已经不怎么考虑兼容问题,大多数的公司都已经舍弃ie7.8了,都是从ie9+开始,所以说不会有那么多的兼容问题需要去解决了,但是由于本人力求完美的工作习惯,做项目的时候还是 ...

  9. [Python3网络爬虫开发实战] 1.5.3-redis-py的安装

    对于Redis来说,我们要使用redis-py库来与其交互,这里就来介绍一下它的安装方法. 1. 相关链接 GitHub:https://github.com/andymccurdy/redis-py ...

  10. 树莓派 -- oled

    硬件 SPI0,CE0 SPI Master Driver 设备树 arch\arm\boot\dts\bcm2710-rpi-3-b.dts &gpio { spi0_pins: spi0_ ...