`
wxb880114
  • 浏览: 673575 次
  • 性别: Icon_minigender_1
  • 来自: 上海
社区版块
存档分类
最新评论

Maven异常处理

 
阅读更多
1.当pom.xml中引入jotm2.10版本时,报出如下错误:
Multiple annotations found at this line:
- Missing artifact javax.transaction:jta:jar:
1.0.1B
- Missing artifact
javax.resource:connector:jar:1.0
提示:Missing artifact javax.transaction:jta:jar:1.0.1B:compile,这是因为由于sun的许可协议,Maven repository中没有包含这个文件,
 
有两种解决方案,

Plan A.我们可以手工添加,具体方法是:

1、在https://cds.sun.com/is-bin/INTERSHOP.enfinity/WFS/CDS-CDS_Developer-Site/en_US/-/USD/ViewProductDetail-Start?ProductRef=7089-jta-1.0.1B-mr-class-oth-JSpec@CDS-CDS_Developer
 
页面下载jta-1_0_1B-classes.zip;

2、运行mvn install:install-file -Dfile=./jta-1_0_1B-classes.zip -DgroupId=javax.transaction -DartifactId=jta -Dversion=1.0.1B -Dpackaging=jar
 
Plan B

在 Pom.xml 里面加入









[java] view plaincopy
<repositories> 
02.    <repository> 
03.        <id>java</id> 
04.        <name>java official repository</name> 
05.        <url>http://download.java.net/maven/2/</url> 
06.    </repository> 
07.</repositories> 
分享到:
评论

相关推荐

Global site tag (gtag.js) - Google Analytics