Using jira rest API in J2EE failed

I try to add a maven dependency in my J2EE eclipse project. I found this dependency, when I look for 'maven dependency jira rest api':

<dependency>
        <groupId>com.atlassian.jira</groupId>
        <artifactId>jira-rest-java-client-core</artifactId>
        <version>4.0.0</version>
</dependency>

If I add it to my POM.xml I was told, that the depending jar was not found. I tried also older version, but get the same error like this:

The container 'Maven Dependencies' references non existing library 'C:\Users\Arno\.m2\repository\com\atlassian\jira\jira-rest-java-client-core\4.0.0\jira-rest-java-client-core-4.0.0.jar'

other dependencies in the same project work. This is my first maven project. Do I miss something or should I use an other artifact?

best regards

Arno

1 answer

0 vote
Alexey Matveev Community Champion Nov 09, 2017

Hello,

I just tried it. I could get this dependency. There must be something with your maven setups.

Thanks for your answer. Can you give me an advise where should I look for this issue in maven (as I told this is my first maven project).

I try to get an old webserver project running in this infrastructure. As I wrote, other dependencies worked.

Because the build of the project has only 3 errors with this dependency and over 10000 without, perhaps it is possible, that the download of the jar will be blocked? But I see now errors, what point to this possibility.

Some hints to analyse more?

Here my actual pom.xml:

<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <groupId>de.test</groupId>
  <artifactId>ppm</artifactId>
  <version>11.0.0-01</version>
  <packaging>war</packaging>
  <dependencies>
      <dependency>
          <groupId>javax</groupId>
          <artifactId>javaee-web-api</artifactId>
          <version>6.0</version>
          <scope>provided</scope>
      </dependency>
    <dependency>
        <groupId>org.apache.struts</groupId>
        <artifactId>struts-core</artifactId>
        <version>1.3.5</version>
    </dependency>
    <dependency>
        <groupId>org.apache.axis</groupId>
        <artifactId>axis</artifactId>
        <version>1.4</version>
    </dependency>
    <dependency>
        <groupId>commons-beanutils</groupId>
        <artifactId>commons-beanutils</artifactId>
        <version>1.8.3</version>
    </dependency>
    <dependency>
        <groupId>com.atlassian.jira</groupId>
        <artifactId>jira-rest-java-client-core</artifactId>
        <version>4.0.0</version>
    </dependency>
    <dependency>
        <groupId>org.apache.struts</groupId>
        <artifactId>struts2-core</artifactId>
        <version>2.5.13</version>
    </dependency>
    <dependency>
        <groupId>de.test</groupId>
        <artifactId>common.license</artifactId>
        <version>1.0</version>
        <scope>system</scope>
        <systemPath>C:\app\WEB-INF\lib\sqslmgr.jar</systemPath>
    </dependency>
  </dependencies>
 
  <build>
      <pluginManagement>
          <plugins>
              <plugin>
                  <groupId>org.apache.maven.plugins</groupId>
                  <artifactId>maven-compiler-plugin</artifactId>
                  <version>3.2</version>
                  <configuration>
                      <verbose>true</verbose>
                      <source>1.7</source>
                      <target>1.7</target>
                      <showWarnings>true</showWarnings>
                  </configuration>
              </plugin>
              <plugin>
                  <groupId>org.apache.tomcat.maven</groupId>
                  <artifactId>tomcat7-maven-plugin</artifactId>
                  <version>2.2</version>
                  <configuration>
                      <path>/</path>
                      <contextReloadable>true</contextReloadable>
                  </configuration>
              </plugin>
          </plugins>
      </pluginManagement>
  </build>
</project>
Alexey Matveev Community Champion Nov 09, 2017

I can not see anything wrong with your pom.xml. I think the problem is with your mvn settings. How are your jars downloaded? mvn goes straight to the internet or uses artifactory or nexus as a proxy? When you package your war, you can see from which path the required jar is being downloaded. Look at the path. Make sure it is accessible.

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Posted Wednesday in Jira

Join our webinar: How 1B+ feature flag events helped us build the new Jira

Every time you release software, there's a bit of risk – that there's a bug, that something breaks, or that the feature doesn't resonate with customers. Feature flagging helps make high stakes s...

93 views 0 1
Join discussion

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you