我在Linux虚拟机上安装了Nexus 2.8。启动它,可以很愉快地浏览到存储库。如果我从存储库视图中查看存储库,它们都在服务中,并且没有一个被阻止。
我可以浏览单个repo索引,但有一件事我担心的是,当我更新或重建索引时,我得到以下内容,其中显示0扫描,更新读取等。
jvm 1 | 2014-07-10 12:08:02,115+0100 INFO [pxpool-1-thread-3] admin org.sonatype.nexus.index.Def
aultIndexerManager - Remote indexes updated successfully for repository "Central" [id=central]
jvm 1 | 2014-07-10 12:08:02,123+0100 INFO [pxpool-1-thread-3] admin org.sonatype.nexus.index.Nex
usScanningListener - Scanning of repositoryID="central" started.
jvm 1 | 2014-07-10 12:08:59,617+0100 INFO [pxpool-1-thread-3] admin org.sonatype.nexus.index.Nex
usScanningListener - Scanning of repositoryID="central" finished: scanned=0, added=0, updated=0, rem
oved=0, scanningDuration=0:00:57.493
jvm 1 | 2014-07-10 12:09:00,025+0100 INFO [pxpool-1-thread-3] admin org.sonatype.nexus.index.Def
aultIndexerManager - Publishing index for repository cen
我的公共存储库已配置,以便所有存储库都位于可用的存储库框中。我不认为我需要为此做任何其他配置,因为我还没有开始玩它只是想让默认设置先工作。我已经为每个repo设置了下载远程索引为true。
当我尝试通过eclipse创建maven项目时,我无法创建它。我在控制台中收到以下错误
10/07/2014 12:27:40 BST: [WARN] The POM for org.apache.maven.plugins:maven-compiler-plugin:jar:2.3.2 is missing, no dependency information available
10/07/2014 12:27:41 BST: [WARN] The POM for org.apache.maven.plugins:maven-compiler-plugin:jar:2.3.2 is missing, no dependency information available
10/07/2014 12:27:41 BST: [INFO] Using org.eclipse.m2e.jdt.JarLifecycleMapping lifecycle mapping for MavenProject: dcdw:dccd:0.0.1-SNAPSHOT @ C:\projects\lloyds\dccd\pom.xml.
10/07/2014 12:27:41 BST: [WARN] The POM for org.apache.maven.plugins:maven-resources-plugin:jar:2.5 is missing, no dependency information available
10/07/2014 12:27:41 BST: [WARN] The POM for org.apache.maven.plugins:maven-resources-plugin:jar:2.5 is missing, no dependency information available
10/07/2014 12:27:42 BST: [WARN] The POM for org.apache.maven.plugins:maven-resources-plugin:jar:2.5 is missing, no dependency information available
10/07/2014 12:27:42 BST: [WARN] The POM for org.apache.maven.plugins:maven-compiler-plugin:jar:2.3.2 is missing, no dependency information available
10/07/2014 12:27:42 BST: [WARN] The POM for org.apache.maven.plugins:maven-compiler-plugin:jar:2.3.2 is missing, no dependency information available
10/07/2014 12:27:42 BST: [INFO] Using org.eclipse.m2e.jdt.JarLifecycleMapping lifecycle mapping for MavenProject: dcdw:dccd:0.0.1-SNAPSHOT @ C:\projects\lloyds\dccd\pom.xml.
10/07/2014 12:27:42 BST: [WARN] The POM for org.apache.maven.plugins:maven-resources-plugin:jar:2.5 is missing, no dependency information available
我可以浏览遥控器并看到这些罐子存在,所以为什么我不能在我的eclipse IDE中下载它们?
我正在使用的设置xml是
<?xml version="1.0"?>
<settings xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
http://maven.apache.org/xsd/settings-1.0.0.xsd">
<localRepository>c:/maven/repository</localRepository>
<mirrors>
<mirror>
<id>nexus</id>
<mirrorOf>*</mirrorOf>
<url>http://unix.host.ip:8081/nexus/content/groups/public</url>
</mirror>
</mirrors>
<profiles>
<profile>
<id>nexus</id>
<!--Enable snapshots for the built in central repo to direct -->
<!--all requests to nexus via the mirror -->
<repositories>
<repository>
<id>central</id>
<url>http://central</url>
<releases>
<enabled>true</enabled>
<updatePolicy>daily</updatePolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>central</id>
<url>http://central</url>
<releases>
<enabled>true</enabled>
<updatePolicy>daily</updatePolicy>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
<activeProfiles>
<activeProfile>nexus</activeProfile>
</activeProfiles>
</settings>
我已经设置了代理配置,因为我在防火墙后面并且确认它有访问权限,因为没有抛出任何错误并且可以运行运行状况检查,尽管它返回0但不会抛出任何错误。
任何人都知道为什么这不起作用?
此外,如果我把它放在网址
我得到以下输出
Describe of /groups/public/org/apache/maven/plugins/maven-jar-plugin/2.3.2/maven-jar-
plugin-2.3.2.pom
This page describes the processing of a request made by external client, using information from the request, retrieved item (or exception if not item was retrieved) and some intermittent processing states.
Processing time
1.581 ms
Request Context
Key Value
request.address 10.175.42.118
request.remoteOnly false
request.user admin
request.url http://hostname:8081/nexus/content/groups/public/org/apache/maven/plugins/maven-jar-plugin/2.3.2/maven-jar-plugin-2.3.2.pom?describe
request.localOnly false
request.agent Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.153 Safari/537.36
request.asExpired false
org.sonatype.nexus.content.internal.ContentServlet.stopwatch 1.581 ms
request.external true
Response Outcome
NOT FOUND (Item not found, core threw exception)
Processed repositories (IDs)
public
Applied Routings
Key Value
public []
Exception
Type
org.sonatype.nexus.proxy.repository.GroupItemNotFoundException
Message
Path /org/apache/maven/plugins/maven-jar-plugin/2.3.2/maven-jar-plugin-2.3.2.pom not found in group repository "Public Repositories" [id=public].
Exception reasoning
public : Path /org/apache/maven/plugins/maven-jar-plugin/2.3.2/maven-jar-plugin-2.3.2.pom not found in group repository "Public Repositories" [id=public].
答案 0 :(得分:2)
您的公共存储库组必须将左侧列中的所有存储库标记为“Ordered Group Repositories”,而不是在可用的存储库列表中。在http://books.sonatype.com/nexus-book/reference/config-sect-repo-group.html和http://books.sonatype.com/nexus-book/reference/confignx-sect-managing-groups.html
中查看有关该详细信息此外,您应通过使用存储库配置中的“浏览远程”选项卡确认您可以通过代理配置访问远程存储库(以Central开头)。
检查完所有内容并修复后,我会删除本地Maven存储库(〜/ .m2 / repository)并尝试命令行构建。一旦有效......将Eclipse与M2e一起使用..