关于maven仓库的问题 Missing artifact

我建了一个私服nexus
nexus有公共库包含了中央库和三方库和apache的快照库

配置镜像是从私服下载

nexus
Nexus
*
http://127.0.0.1:8081/nexus/content/groups/public/


项目中配置


commons-logging
commons-logging
1.1.1

项目中报错
10-12-28 上午11时05分58秒: [WARN] The POM for commons-logging:commons-logging:jar:1.1.1 is missing, no dependency information available
10-12-28 上午11时05分58秒: Missing artifact commons-logging:commons-logging:jar:1.1.1:compile

但是我看
http://127.0.0.1:8081/nexus/content/repositories/central/commons-logging/commons-logging/1.1.1/是有这个jar的
http://127.0.0.1:8081/nexus/content/repositories/public/中没有

Download Remote Indexes 也设成了true 也reindex过了 index都很正常 jar也能搜到

我是初学者,很是不理解
是什么原因呢 哪位大侠解释下????

不应该出现这种问题的,你看看你自己有没有设置proxy,你mvn clean一下看看

*

改成

central

这样的话,就不需要所有的jar都从Nexus下载了

你这个配置是在神马地方?

[code="java"]

    <mirror>
        <id>ibiblio.org</id>
        <name>ibiblio Mirror of http://repo1.maven.org/maven2/</name>
        <url>http://mirrors.ibiblio.org/pub/mirrors/maven2</url>
        <mirrorOf>central</mirrorOf>
    </mirror>


nexus
Nexus
central
http://127.0.0.1:8081/nexus/content/groups/public/

[/code]

[code="java"]

commons-logging
commons-logging
1.1.1

[/code]

怒了.....重启你的eclipse,eclipse的插件有时候很傻比

[quote]
The POM for commons-logging:commons-logging:jar:1.1.1 is missing

但是我发现中央库是有pom的 但是私服的代理库里面只有jar包没有pom
是不是因为这个原因呢 。。 我很奇怪
只是不知道怎么让它把pom也下下来。
[/quote]

不需要pom也可以的,其实不管是私服还是神马服,都会下载这个commons-logging:jar在你的本地的,你可以去/home/${user}/.m2/repository这个目录下面找到这个文件。。如果你是windows的话,在C:\Documents and Settings\%user%.m2\repository

有个解决办法,你先让你的settings.xml
[quote]


ibiblio.org

ibiblio Mirror of http://repo1.maven.org/maven2/

http://mirrors.ibiblio.org/pub/mirrors/maven2

*



[/quote]
这样就能下载到本地,然后你再该回central

这个我看行

关于镜像仓库的更新配置这个
你可以去参考

http://maven.apache.org/guides/mini/guide-mirror-settings.html

因为这个我自己也不太懂

到Nexus去配置中央仓库

1 找到repository,然后配置maven central

2 Maven central是Maven的中央仓库,点击它并选择configuration标签栏

3 Remote storage location 修改成 http://mirrors.ibiblio.org/pub/mirrors/maven2

因为这个仓库是最大的。。。嘻嘻

首先,nexus会从你的本地仓库查找,如果找不到会到你在nexus中配置的远程仓库查找.如果你nexus中配置正确,应该不会出现下载不到jar包的问题.
[code="java"]


proxied-releases
Release Mirror
http://127.0.0.1:8081/nexus/content/groups/public/
central


[/code]
其次,修改你的m2eclipse配置,使用你本地的maven.Preferences--->Maven-->Installations--->Add.

用最高权限登陆私服,在主页面下面有图形化的配置方式 配置下 下载depengdengcy的时候 同时下载pom jar resources ;;

但是这不能解决你的根本问题,跟pom没关系 我也遇到同样的问题,,,

Downloading: http:// .../nexus/content/groups/public/net/java/dev/jets3t/jets3t/0.7.2/jets3t-0.7.2.pom
[WARNING] The POM for net.java.dev.jets3t:jets3t:jar:0.7.2 is missing, no dependency information available
Downloading: http://..../nexus/content/groups/public/net/java/dev/jets3t/jets3t/0.7.2/jets3t-0.7.2.jar
[ERROR] The build could not read 1 project -> [Help 1]
[ERROR]

[ERROR] The project org.springframework.security:spring-security-parent:3.0.0.RELEASE (/media/1464942C6494131A/linuxDevelopInW7/WorkSpace/spring-security-3.0.0.RELEASE/pom.xml) has 1 error
[ERROR] Unresolveable build extension: Plugin org.springframework.build.aws:org.springframework.build.aws.maven:3.0.0.RELEASE or one of its dependencies could not be resolved: Could not find artifact net.java.dev.jets3t:jets3t:jar:0.7.2 in nexus (http://..../groups/public/) -> [Help 2]
[ERROR]

不知道咋办。。。。