java - idea 打包war包时候报错?
高洛峰
高洛峰 2017-04-18 10:50:52
0
2
687

我有个项目:xmlivecli 目录结构:

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:motan="http://api.weibo.com/schema/motan"
    xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans-2.5.xsd
   http://api.weibo.com/schema/motan http://api.weibo.com/schema/motan.xsd">

    <motan:protocol id="motan" default="true" name="motan" maxServerConnection="80000" maxContentLength="1048576" maxWorkerThread="800" minWorkerThread="20" />
    <!-- reference to the remote service -->
    <motan:referer id="wxClientRPCService" interface="com.njmdedu.wxapi.WxClientRPCService" directUrl="192.168.1.1:8452" requestTimeout="5000" timeout="5000" />

    <motan:referer id="userRPCService" interface="com.njmdedu.rpc.api.UserRPCService" directUrl="192.168.1.1:8492" requestTimeout="5000" timeout="5000" />

    <motan:referer id="wcUserRPCService" interface="com.njmdedu.rpc.api.WcUserRPCService" directUrl="192.168.1.1:8493" requestTimeout="5000" timeout="5000" />

    <motan:referer id="kindergartenRPCService" interface="com.njmdedu.rpc.api.KindergartenRPCService" directUrl="192.168.1.1:8495" requestTimeout="5000" timeout="5000" />

</beans> 

正式打包的时候报:

[ERROR] Failed to execute goal on project xmlivecli: Could not resolve dependencies for project com.njmdedu:xmlivecli:war:1.0.0: The following artifacts could not be resolved: com.njmdedu:wxapi:jar:0.0.1, com.njmdedu:rpcapi:jar:0.0.1: Failure to find com.njmdedu:wxapi:jar:0.0.1 in http://192.168.1.123:8081/nexus/content/groups/md_local_repo/ was cached in the local repository, resolution will not be reattempted until the update interval of md_local_repo has elapsed or updates are forced -> [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

Process finished with exit code 1
高洛峰
高洛峰

拥有18年软件开发和IT教学经验。曾任多家上市公司技术总监、架构师、项目经理、高级软件工程师等职务。 网络人气名人讲师,...

모든 응답(2)
阿神

우선install 다른 품목을 확인한 후 포장

  1. rpcapi 프로젝트에서 실행 mvn install

  2. wxtools 프로젝트에서 실행 mvn install

  3. wxapi 프로젝트에서 실행 mvn install

  4. 마침내 xmlivecli 프로젝트에서 실행 mvn package

이 종속성 순서도 내 추측입니다. 더 조정해야 할 수도 있습니다.

洪涛

해결되었습니다. 기본 Maven 홈을 로컬로 설정해도 문제가 없습니다

최신 다운로드
더>
웹 효과
웹사이트 소스 코드
웹사이트 자료
프론트엔드 템플릿
회사 소개 부인 성명 Sitemap
PHP 중국어 웹사이트:공공복지 온라인 PHP 교육,PHP 학습자의 빠른 성장을 도와주세요!