Maven抱怨对WAR文件的依赖

时间:2014-01-29 09:22:08

标签: java maven

我正在尝试构建一个具有以下依赖关系的项目

<dependency>
     <groupId>org.richfaces.examples</groupId>
     <artifactId>richfaces-showcase</artifactId>
     <version>4.3.4.Final</version>
     <classifier>jbas71</classifier>
     <type>war</type>
</dependency>

虽然WAR文件似乎位于我本地仓库中的正确位置。 .m2/repository/org/richfaces/examples/richfaces-showcase/4.3.4.Final/

的内容
  • RichFaces的-陈列柜-4.3.4.Final-jbas71.war
  • RichFaces的-陈列柜-4.3.4.Final-jbas71.war.lastUpdated
  • RichFaces的-陈列柜-4.3.4.Final-jbas71.war.pom

我尝试删除*.lastUpdated文件,*.war.pom似乎还可以,但我还是

[ERROR] Failed to execute goal on project richfaces-showcase-portlet: 
Could not resolve dependencies for project org.jboss.portletbridge.examples:richfaces-showcase-portlet:war:3.3.1.Final: 
Failure to find org.richfaces.examples:richfaces-showcase:war:jbas71:4.3.4.Final in
http://repo.maven.apache.org/maven2 was cached in the local repository, resolution 
will not be reattempted until the update interval of central has elapsed or updates are 
forced -> [Help 1]

1 个答案:

答案 0 :(得分:2)

依赖性意味着错误,导致war文件不是一个依赖项。 war文件旨在用作示例,可以将其部署到Tomcat等中以查看它的外观等。

除此之外,你试图从Maven Central获得富有表面,这是不可能的,因为Richfaces不在Maven Central中。他们有自己的存储库。您需要将此存储库添加到配置或存储库管理器。

此外还有消息:

Failure to find org.richfaces.examples:richfaces-showcase:war:jbas71:4.3.4.Final in
http://repo.maven.apache.org/maven2 was cached in the local repository, resolution 
will not be reattempted until the update interval of central has elapsed or updates are 
forced -> [Help 1]

表示无法下载依赖项。我假设war文件的大小是0 ..