打包Dubbox到本地仓库时遇到的问题

打包Dubbox到本地仓库时报错

Dubbox下载地址:https://github.com/dangdangdotcom/dubbox
CMD里边进入解压后的文件目录
使用 mvn clean install -DskipTests命令打包时,报错如下:

[INFO] dubbo-simple ....................................... SUCCESS [  0.058 s]
[INFO] dubbo-registry-simple .............................. FAILURE [29:56 min]
[INFO] dubbo-monitor-simple ............................... SKIPPED
[INFO] dubbo-admin ........................................ SKIPPED
[INFO] dubbo-demo ......................................... SKIPPED
[INFO] dubbo-demo-api ..................................... SKIPPED
[INFO] dubbo-demo-provider ................................ SKIPPED
[INFO] dubbo-demo-consumer ................................ SKIPPED
[INFO] dubbo-test ......................................... SKIPPED
[INFO] dubbo-test-benchmark ............................... SKIPPED
[INFO] dubbo-test-compatibility ........................... SKIPPED
[INFO] dubbo-test-integration ............................. SKIPPED
[INFO] dubbo-test-examples ................................ SKIPPED
[INFO] dubbo-test-benchmark-api ........................... SKIPPED
[INFO] dubbo-test-benchmark-server ........................ SKIPPED
[INFO] dubbo-test-benchmark-client 2.8.4 .................. SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 32:20 min
[INFO] Finished at: 2019-07-09T14:38:04+08:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-dependency-plugin:2.8:
unpack (unpack) on project dubbo-registry-simple: Execution unpack of goal
org.apache.maven.plugins:maven-dependency-plugin:2.8:unpack failed:
Plugin org.apache.maven.plugins:maven-dependency-plugin:2.8 or one of its dependencies
could not be resolved: Could not transfer artifact org.codehaus.plexus:
plexus-archiver:jar:2.3 from/to nexus-aliyun (http://maven.aliyun.com/nexus/content/groups/public):
archiva-maven-storage-prod.oss-cn-beijing.aliyuncs.com:80 failed to respond -> [Help 1]

问题原因:项目编码和IDEA编码不一致
解决办法:在IDEA设置编码为UTF-8:
1.File->Settings->Editor->File Encodings,三个地方都设置为UTF-8
2.File->Other Settings->Default Settings ->Editor->File Encodings,三个地方都设置为UTF-8
3.File->Settings->Build,Execution,Deployment -> Compiler -> Java Compiler
在 Additional command line parameters处写入 -encoding utf-8
4.打开Run->Edit Configurations… -> Defaults ->Tomcat Server,
在VM options处写入 -Dfile.encoding=UTF-8

重新打包,问题解决

你可能感兴趣的:(打包Dubbox到本地仓库时遇到的问题)