6

I added com.ibm.mqjms maven dependency in my pom.xml:

<dependency>
 <groupId>com.ibm</groupId>
 <artifactId>com.ibm.mqjms</artifactId>
 <version>5.3.07</version>
</dependency>

And it's giving me:

The following artifacts could not be resolved: com.ibm:com.ibm.mqjms:jar:5.3.07, com.ibm:com.ibm.mq:jar:5.3.07, javax.naming:jndi:jar:1.2.1, javax.resource:connector:jar:1.0, javax.transaction:jta:jar:1.0.1B, javax.jms:jms:jar:1.1: Could not find artifact com.ibm:com.ibm.mqjms:jar:5.3.07 in central (http://repo.maven.apache.org/maven2)

Any idea how can I fix it?

Arpit Aggarwal
  • 27,626
  • 16
  • 90
  • 108
  • Post the full error message and stacktrace. – Tunaki Sep 23 '15 at 14:31
  • Yes, it exists, but it's giving me error, any additional `repository` need to be added to have the same? – Arpit Aggarwal Sep 23 '15 at 14:33
  • No need to add a custom repository since this dependency is available on Maven central. But what you posted is not the full stracktrace so it's hard to tell what's wrong. – Tunaki Sep 23 '15 at 14:36
  • It's full trace, I can see the error `Missing artifact com.ibm:com.ibm.mqjms:jar: 5.3.07` with red cross in IDE. – Arpit Aggarwal Sep 23 '15 at 14:38
  • This error comes from your IDE, not from Eclipse. Run `mvn clean install` on your project (through your IDE or on the command line) and post the resulting error. – Tunaki Sep 23 '15 at 14:39
  • Updated error logs after running `mvn clean install` – Arpit Aggarwal Sep 23 '15 at 14:52
  • 1
    This is offtopic but a suggestion to migrate away from MQ 5.3. It's very old and went out of support long back. MQ 8 is the latest version and you have to just include allclient.jar in your maven repository. – Umapathy Sep 24 '15 at 18:05

2 Answers2

9

Below JARs are proprietary - hence they will not resolve through a public Maven repository like Maven Central. These JARs need to be obtained from the WebSphere MQ installation directory and manually deployed to our local Maven repository.:

<dependency>
    <groupId>com.ibm</groupId>
    <artifactId>com.ibm.mqjms</artifactId>
    <version>${webSphereMQVersion}</version>
</dependency>
<dependency>
    <groupId>com.ibm</groupId>
    <artifactId>com.ibm.mq.jmqi</artifactId>
    <version>${webSphereMQVersion}</version>
</dependency>
<dependency>
    <groupId>com.ibm</groupId>
    <artifactId>com.ibm.disthub2.dhbcore</artifactId>
    <version>${webSphereMQVersion}</version>
</dependency>
Arpit Aggarwal
  • 27,626
  • 16
  • 90
  • 108
2

Try this it worked for me

<dependency>
<groupId>com.ibm.mq</groupId>
<artifactId>allclient</artifactId>
<version>9.0.0.0</version>
<type>jar</type>
</dependency>
  • 2
    Please add an explanation why this solves the problem or other means to make the answer less vague. – Martin Fahl May 17 '19 at 11:20
  • Thank you. This worked for me directly from maven public repo. I didn't have to manually add it to my project, like the accepted answer suggests – Cymk Apr 21 '20 at 18:15