Java,Maven依赖项

时间:2012-09-18 08:29:16

标签: java maven compilation

我是Maven和JSF的新手,编译项目时遇到以下问题:

Failed to execute goal on project ViewController: Could not resolve dependencies for project com.km.eFarmer:ViewController:war:1.0.1-alpha1-SNAPSHOT: The following artifacts could not be resolved: com.sun.faces:jsf-api:jar:2.0.3-FCS, com.sun.faces:jsf-impl:jar:2.0.3-FCS, org.openfaces:openfaces:jar:3.0.2-KM, cssparser:cssparser:jar:0.9.5, it.eng.spago:sbi-utils:jar:3.3.0: Failure to find com.sun.faces:jsf-api:jar:2.0.3-FCS in http://repo1.maven.org/maven2/ was cached in the local repository, resolution will not be reattempted until the update interval of maven.maven2 has elapsed or updates are forced -> [Help 1

2 个答案:

答案 0 :(得分:3)

这意味着存储库com.sun.faces:jsf-api:jar:2.0.3-FCS中不存在工件http://repo1.maven.org/maven2/

事实上,此回购邮件中没有版本为jsf-api.jar的{​​{1}}。 有一个available versions列表。因此,您应该更改工件版本或存储库URL

答案 1 :(得分:-2)

简单删除文件夹local repository com / sun / faces,然后重试。