"atlas-run" in Confluence plugin fails with "Failed to read artifact descriptor" message

I’m trying to begin the development of my first Confluence plugin. I’ve followed the documentation steps but, when I run “atlas-run”, the process fails.

It downloads all maven dependencies without a problem, until this point:

$ /usr/share/atlassian-plugin-sdk-6.2.14/apache-maven-3.2.1/bin/mvn -U com.atlassian.maven.plugins:maven-amps-dispatcher-plugin:6.2.11:run -gs /usr/share/atlassian-plugin-sdk-6.2.14/apache-maven-3.2.1/conf/settings.xml
[INFO] Scanning for projects...
Downloading: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-resources-plugin/maven-metadata.xml
Downloaded: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-resources-plugin/maven-metadata.xml (896 B at 3.0 KB/sec)
Downloading: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-compiler-plugin/maven-metadata.xml
Downloaded: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-compiler-plugin/maven-metadata.xml (2 KB at 26.1 KB/sec)
Downloading: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-install-plugin/maven-metadata.xml
Downloaded: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-install-plugin/maven-metadata.xml (711 B at 19.3 KB/sec)
Downloading: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata.xml
Downloaded: http://nexus-repository.local/repository/main-repository/org/apache/maven/plugins/maven-deploy-plugin/maven-metadata.xml (795 B at 26.8 KB/sec)
[INFO] 
[INFO] Using the builder org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder with a thread count of 1
[INFO]                                                                         
[INFO] ------------------------------------------------------------------------
[INFO] Building confluence-plugin 1.0.0-SNAPSHOT
[INFO] ------------------------------------------------------------------------
[INFO] 
[INFO] >>> maven-amps-dispatcher-plugin:6.2.11:run (default-cli) @ confluence-plugin >>>
Downloading: http://nexus-repository.local/repository/main-repository/com/atlassian/applinks/applinks-parent/5.2.2/applinks-parent-5.2.2.pom
Downloading: http://nexus-repository.local/repository/main-repository/org/apache/velocity/velocity/maven-metadata.xml
Downloaded: http://nexus-repository.local/repository/main-repository/org/apache/velocity/velocity/maven-metadata.xml (2 KB at 0.5 KB/sec)
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 10.229 s
[INFO] Finished at: 2017-05-05T08:50:01+01:00
[INFO] Final Memory: 31M/121M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project confluence-plugin: Could not resolve dependencies for project com.amaseguros.atlas:confluence-plugin:atlassian-plugin:1.0.0-SNAPSHOT: Failed to collect dependencies at com.atlassian.confluence:confluence:jar:5.10.7 -> com.atlassian.applinks:applinks-api:jar:5.2.2: Failed to read artifact descriptor for com.atlassian.applinks:applinks-api:jar:5.2.2: Could not find artifact com.atlassian.applinks:applinks-parent:pom:5.2.2 in AMA (http://nexus-repository.local/repository/main-repository/) -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/DependencyResolutionException

I’m using an internal Nexus repository where Atlassian repository is added. I can access to the path /com/atlassian/applinks/applinks-api/5.2.2/applinks-api-5.2.2.pom and see the content.

Any idea?

Thanks!

1 Like

I am experiencing the same issue (while doing the hello world plugin tutorial) and can’t find the solution.
Were you able to fix your problem? If yes, any help would be appreciated!

I am running into this same issue as well. I would like the build process to pass through Nexus for the remote content, but it seems we have a configuration wrong in order to allow this to happen.

This is my config, works. Hope it helps

<repositories>
        <repository>
            <id>fullcontact</id>
            <url>http://dl.bintray.com/content/fullcontact/fullcontact-oss</url>
        </repository>
        <repository>
            <id>atlassian-public</id>
            <url>https://maven.atlassian.com/repository/public</url>
        </repository>
        <repository>
            <id>releases</id>
            <name>Release Repo</name>
            <url>mynexusserver/maven-releases</url>
        </repository>
    </repositories>
<distributionManagement>
        <repository>
            <id>releases</id>
            <url>mynexsusserver/maven-releases</url>
        </repository>
        <snapshotRepository>
            <id>snapshots</id>
            <url>mynexsusserver/maven-snapshots</url>
        </snapshotRepository>
    </distributionManagement>
    <scm>
        <connection>scm:git:git@mygit</connection>
        <developerConnection>scm:git:git@mygit</developerConnection>
        <url>https://bitbucket.org/repo_location</url>
    </scm>
1 Like

The issue seems to come from Nexus 3.x having issues with the applinks-parent.pom, that is missing an XML stanza. More details and a workaround have been posted in another post in the community: Nexus 3.x and appllinks dependency