水滴石穿——非一日之功

maven工程依赖的jar包,在本地仓库有,但是pom.xml文件却报错找不到jar包

启动项目eclipse报错:

严重: Error configuring application listener of class org.jeecgframework.web.system.listener.InitListener
java.lang.ClassNotFoundException: org.jeecgframework.web.system.listener.InitListener

然后发现是pom.xml有多处错误,提示缺少工件之类的,但是本地仓库确有

Missing artifact org.jeecgframework.p3:jeecg-p3-biz-mail:jar:1.0.0

中文:

缺少工件org.jeecgframework.p3:jeecg-p3-biz-mail:jar:1.0.0

 

如题:maven工程出现找不到依赖的jar包错误,但是本地仓库中有改如何解决。

现有两种解决方法:

第一种:

    在eclipse中的window->show view->other->maven Repositories打开maven Repositories视图,

    然后在maven Repositories视图中选中local Repositories->Local Repository, 右键选择Rebuild Index;

第二种:

    在找到错误中的jar包所在本地路径,找到与jar包同文件夹下的_remote.repositories,

    删除_remote.repositories文件 或者修改>XX=为>=(即删除main,当然main也可能是其他值);

    然后再右键工程maven->update project;
 

亲测用第二种方法已解决。

posted @ 2019-08-12 18:27  滑稽的鼠标  阅读(13997)  评论(0编辑  收藏  举报
/*粒子线条,鼠标移动会以鼠标为中心吸附的特效*/