maven下载jar的时候会去寻国外的地址,因此造成了下载jar很缓慢,影响开发效率,于是就出现maven镜像地址,可以使我们开发人员迅速下载相关的jar。
在maven的config的setting.xml文件中,我们发现:
mirror的配置就是为了镜像。
1 国内连接maven官方的仓库更新依赖库,网速一般很慢,收集一些国内快速的maven仓库镜像以备用。 2 3 ====================国内OSChina提供的镜像,非常不错=================== 4 5 <mirror> 6 7 <id>CN</id> 8 <name>OSChina Central</name> 9 <url>http://maven.oschina.net/content/groups/public/</url> 10 <mirrorOf>central</mirrorOf> 11 12 </mirror> 13 14 ======================================================== 15 16 OSChina Maven 库使用帮助 17 18 19 ==================其他maven仓库镜像========================== 20 21 <mirror> 22 <id>repo2</id> 23 <mirrorOf>central</mirrorOf> 24 <name>Human Readable Name for this Mirror.</name> 25 <url>http://repo2.maven.org/maven2/</url> 26 </mirror> 27 <mirror> 28 <id>net-cn</id> 29 <mirrorOf>central</mirrorOf> 30 <name>Human Readable Name for this Mirror.</name> 31 <url>http://maven.net.cn/content/groups/public/</url> 32 </mirror> 33 <mirror> 34 <id>ui</id> 35 <mirrorOf>central</mirrorOf> 36 <name>Human Readable Name for this Mirror.</name> 37 <url>http://uk.maven.org/maven2/</url> 38 </mirror> 39 <mirror> 40 <id>ibiblio</id> 41 <mirrorOf>central</mirrorOf> 42 <name>Human Readable Name for this Mirror.</name> 43 <url>http://mirrors.ibiblio.org/pub/mirrors/maven2/</url> 44 </mirror> 45 <mirror> 46 <id>jboss-public-repository-group</id> 47 <mirrorOf>central</mirrorOf> 48 <name>JBoss Public Repository Group</name> 49 <url>http://repository.jboss.org/nexus/content/groups/public</url> 50 </mirror> 51 52 53 <mirror> 54 <id>JBossJBPM</id> 55 <mirrorOf>central</mirrorOf> 56 <name>JBossJBPM Repository</name> 57 <url>https://repository.jboss.org/nexus/content/repositories/releases/</url> 58 </mirror> 59 -------------------------spring maven-------------------------------- 60 http://maven.springframework.org/release/ 61 --------------------------------------------------------------------- 62 http://maven.antelink.com/content/repositories/central/ 63 http://nexus.openkoala.org/nexus/content/groups/Koala-release/ 64 http://maven.tmatesoft.com/content/groups/public/ 65 http://mavensync.zkoss.org/maven2/