eclipse安装WEB、javaEE插件方法以及我所遇到的问题

一、安装WEB、javaEE插件
  1.1 打开Eclipse菜单help --> install new software选项
  1.2 在work with 栏中输入 http://download.eclipse.org/releases/oxygen(官网下载地址,其中oxygen改为你的eclipse版本,查看方法见https://blog.csdn.net/Duqian94/article/details/52386076)
  1.3 选择web and java ee development选项,然后next,接受协议,next…
  1.4 下面就是简单的等待安装了
  参考博客:http://www.cnblogs.com/BestNow/
二、eclipse安装插件过程中可能出现的问题
问题描述:虽然等待安装理论上很简单,然而由于网络不稳定等各种原因,总是会出现以下:
An error occurred while collecting items to be installed
session context was:(profile=E__Eclipse2_eclipse, phase=org.eclipse.equinox.internal.p2.engine.phases.Collect, operand=, action=).

No repository found containing: osgi.bundle,com.gradleware.tooling.client,0.19.5.v20181001144510

Failed to transfer artifact canonical: osgi.bundle,org.eclipse.oomph.p2.doc,1.10.0.v20180706-1242.

Problems downloading artifact: osgi.bundle,org.eclipse.oomph.p2.doc,1.10.0.v20180706-1242.
File has invalid content:C:\Users\asus\AppData\Local\Temp\signatureFile3027356319560896387.jar

Invalid content:javadoc/org/eclipse/oomph/p2/impl/P2PackageImpl.html
The file “javadoc/org/eclipse/oomph/p2/impl/P2PackageImpl.html” in the jar “C:\Users\asus\AppData\Local\Temp\signatureFile3027356319560896387.jar” has been tampered!
No repository found containing: osgi.bundle,org.gradle.toolingapi,4.10.2.v20181001144510
No repository found containing: org.eclipse.update.feature,org.eclipse.buildship,2.2.2.v20181003-1021
以及第二次安装时出现:
An error occurred during the org.eclipse.equinox.internal.p2.engine.phases.CheckTrust phase.
session context was:(profile=E__Eclipse2_eclipse, phase=org.eclipse.equinox.internal.p2.engine.phases.CheckTrust, operand=, action=).
Error reading signed content.
Exception in opening zip file: C:\Users\asus.p2\pool\plugins\org.eclipse.jem_2.0.600.v201302011850.jar

这样类似的error details。

解决办法:cmd命令行执行命令
E:\Eclipse2\eclipse\eclipse.exe -application org.eclipse.equinox.p2.garbagecollector.application
E:\Eclipse2\eclipse\eclipse.exe -profile ****(****是configuration/concfig.ini里eclipse.p2.profile项的值)
目测上面命令的作用是将C:\Users\asus.p2\pool目录下的plugins中某些错误下载的文件及文件夹删除(可能features中的也要删掉),并且更改artifacts.xml文件。

这个解决方法也适用于:
1.安装插件报错,找不到某jar包;
2.安装插件报错An error occurred while collecting items to be installed session context was:(profile=epp.package.je…

出现错误的原因是Eclipse的更新管理P2出错了。p2有它的一个垃圾回收机制,之前删除的JAR包在未被回收之前,再次重装,系统不会做重新download的动作,但是它又找不到那个JAR包了,故而报错。(参考博客:https://blog.51cto.com/imu2008/1432637
https://blog.csdn.net/Duqian94/article/details/52640394,按照其说法,在目录下,执行eclipse命令总是提示我’eclipse’ 不是内部或外部命令…不是环境变量的锅…至今没有找到原因…或许是windows\linux的ba…)

  • 0
    点赞
  • 10
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值