Trying to add dependency to Atlassian pom.xml using IntelliJ

233 views Asked by At

I am beginning to work with IntelliJ and have not worked with Java for many years. I've been working in the .Net world. I am creating an Atlassian Crowd Custom Connector using IntelliJ. I need to add a dependency to the pom.xml file for the com.atlassian.crowd.manager.directory package. I believe the dependency block below is correct except for the version. Is the artifactid correct? I used other dependencies to derive this. How do I find the correct version?

<dependency>
    <groupId>com.atlassian.crowd</groupId>
    <artifactId>manager-directory</artifactId>
    <version>2.8.8</version>
</dependency>
1

There are 1 answers

10
Abderrazak BOUADMA On

It seems you're looking for the following dependency atlassian-crowd-components.

To be able to use it, you've to add the following section into your pom.xml

<repositories>
    <repository>
        <id>pentaho-releases</id>
        <url>http://repository.pentaho.org/artifactory/repo/</url>
    </repository>
</repositories>

An replace your dependency section by the following one:

<dependencyManagement>
 <dependency>
    <groupId>com.atlassian.crowd</groupId>
    <artifactId>atlassian-crowd-components</artifactId>
    <version>2.9.5</version>
    <type>pom</type>
 </dependency>
</dependencyManagement>

Then, within the <dependencies> section of the POM add the desired dependency without indication of the version like follow:

 <dependencies>
   <!-- other dependencies ... -->
   <dependency>
     <groupId>com.atlassian.crowd</groupId>
     <artifactId>crowd-core</artifactId>
   </dependency>
  </dependencies>

You can find all dependencies from this URL