Some problems were encountered while building the effective model for com.centerm:ipark-demo-control

D:\Java\jdk1.8.0_131\bin\java.exe -agentlib:jdwp=transport=dt_socket,address=127.0.0.1:64460,suspend=y,server=n -Dmaven.multiModuleProjectDirectory=D:\centerm\epark\v20180904\ipark-demo-controller “-Dmaven.home=D:\IntelliJ IDEA 2018.1.2\plugins\maven\lib\maven3” “-Dclassworlds.conf=D:\IntelliJ IDEA 2018.1.2\plugins\maven\lib\maven3\bin\m2.conf” -javaagent:C:\Users\Administrator\AppData\Local\Temp\capture2jars\debugger-agent.jar=file:/C:/Users/Administrator/AppData/Local/Temp/capture.props -Dfile.encoding=UTF-8 -classpath “D:\IntelliJ IDEA 2018.1.2\plugins\maven\lib\maven3\boot\plexus-classworlds-2.5.2.jar;D:\IntelliJ IDEA 2018.1.2\lib\idea_rt.jar” org.codehaus.classworlds.Launcher -Didea.version=2018.1.2 clean tomcat7:run -P !dev
Connected to the target VM, address: ‘127.0.0.1:64460’, transport: ‘socket’
[INFO] Scanning for projects…
[WARNING]
[WARNING] Some problems were encountered while building the effective model for com.centerm:ipark-demo-controller:war:1.0-SNAPSHOT
[WARNING] ‘dependencies.dependency.(groupId:artifactId:type:classifier)’ must be unique: org.slf4j:slf4j-api:jar -> duplicate declaration of version ${slf4j.version} @ com.centerm:ipark-demo-controller:[unknown-version], D:\centerm\epark\v20180904\ipark-demo-controller\pom.xml, line 48, column 21
[WARNING]
[WARNING] It is highly recommended to fix these problems because they threaten the stability of your build.
[WARNING]
[WARNING] For this reason, future Maven versions might no longer support building such malformed projects.
[WARNING]
[INFO]
[INFO] ————————————————————————
[INFO] Building ipark-demo-controller 1.0-SNAPSHOT
[INFO] ————————————————————————
[WARNING] The POM for com.centerm:ipark-demo-service:jar:1.0-SNAPSHOT is missing, no dependency information available
[INFO] ————————————————————————
[INFO] BUILD FAILURE
[INFO] ————————————————————————
[INFO] Total time: 1.651 s
[INFO] Finished at: 2018-09-04T15:22:16+08:00
[INFO] Final Memory: 9M/155M
[INFO] ————————————————————————
[ERROR] Failed to execute goal on project ipark-demo-controller: Could not resolve dependencies for project com.centerm:ipark-demo-controller:war:1.0-SNAPSHOT: Could not find artifact com.centerm:ipark-demo-service:jar:1.0-SNAPSHOT -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException
Disconnected from the target VM, address: ‘127.0.0.1:64460’, transport: ‘socket’

Process finished with exit code 1

原因一:
其实这个jar是另外一个工程A,在本工程B中引用了打成jar包的A。

由于业务需要,我修改了A工程中的实现,再将A工程pom文件中的版本号从N改为M,并将A工程上传到项目的中央仓库。

当B工程再引用A这个jar时,就要将A的版本号改为M,才能正确引入A工程作为其依赖。
解决方法:删除子项目下target的文件夹
原因二:
我用的开发工具idea,自带maven,本地仓库可能跟你安装的地址不一致,检查下,替换成你安装的maven,项目旧能引到你installl到本地仓库的包,问题解决。

  • 9
    点赞
  • 17
    收藏
    觉得还不错? 一键收藏
  • 5
    评论
评论 5
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

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

抵扣说明:

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

余额充值