java.net maven repo - 缺少JMS工件 [英] java.net maven repo - JMS artifact missing

查看:152
本文介绍了java.net maven repo - 缺少JMS工件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我刚刚使用默认原型创建了一个新的Maven项目,并将以下依赖项添加到我的POM文件中。

 <依赖> 
< dependency>
< groupId> javax.jms< / groupId>
< artifactId> jms< / artifactId>
< version> 1.1< / version>
< scope> compile< / scope>
< / dependency>
< / dependencies>

由于许可问题,我意识到Sun的JAR不在Maven中心,我添加了
以下Maven回购到我的POM(我知道这是不好的做法,需要将它添加到settings.xml)

 <库> 
< repository>
< id>回购ID< / id>
< layout>默认< / layout>
< name> Java.net Maven repo< / name>
< releases>
< enabled> true< / enabled>
< / releases>
< url> http://download.java.net/maven/2/< / url>
< / repository>
< / repositories>

我仍然在我的POM文件中看到此错误。



缺失工件javax.jms:jms:jar:1.1:compile



<有没有人知道除了我已有的配置还需要做什么?

解决方案


由于许可问题,我意识到Sun的JAR不在Maven中心,我将以下Maven回购添加到我的POM


是的,但 http://download.java.net/maven/2/javax / 没有jms工件......



好消息是JBoss Nexus存储库确实拥有它:

 < repository> 
< id> repository.jboss.org-public< / id>
< name> JBoss存储库< / name>
< url> https://repository.jboss.org/nexus/content/groups/public< / url>
< / repository>


I just created a new Maven project using the default archetype and added the following dependency to my POM file.

<dependencies>
  <dependency>
    <groupId>javax.jms</groupId>
    <artifactId>jms</artifactId>
    <version>1.1</version>
    <scope>compile</scope>
  </dependency>
</dependencies>

Realizing that the Sun's JARs are not on Maven central due to licensing issues, I added the following Maven repo to my POM (I know this is bad practice though and that it needs to be added to a settings.xml)

<repositories>
  <repository>
    <id>Repo ID</id>
    <layout>default</layout>
    <name>Java.net Maven repo</name> 
    <releases>
      <enabled>true</enabled>
    </releases>
    <url>http://download.java.net/maven/2/</url>
  </repository>
</repositories>

I still see this error in my POM file.

"Missing artifact javax.jms:jms:jar:1.1:compile"

Does anyone here know what else needs to be done in addition to the config I already have?

解决方案

Realizing that the Sun's JARs are not on Maven central due to licensing issues, I added the following Maven repo to my POM

Yeah, but http://download.java.net/maven/2/javax/ doesn't have the jms artifact...

The good news is that the JBoss Nexus repository does have it:

<repository>
  <id>repository.jboss.org-public</id>
  <name>JBoss repository</name>
  <url>https://repository.jboss.org/nexus/content/groups/public</url>
</repository>

这篇关于java.net maven repo - 缺少JMS工件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆