Reputation: 701
My team is using JFrog artifactory and it has a 3rd-party lib deployed to it.
My settings.xml:
<settings xmlns="http://maven.apache.org/SETTINGS/1.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/SETTINGS/1.0.0 http://maven.apache.org/xsd/settings-1.0.0.xsd">
<profiles>
<profile>
<id>dev</id>
<properties>
<artifactory.url>http://myartifactory.com</artifactory.url>
<artifactory.username>blah</artifactory.username>
<artifactory.passwd>blah</artifactory.passwd>
<artifactory.maven.snapshot>maven-integration-local</artifactory.maven.snapshot>
<artifactory.maven.thirdparty>maven-third-party-local</artifactory.maven.thirdparty>
<artifactory.maven.rc>maven-release-candidate-local</artifactory.maven.rc>
<artifactory.maven.release>maven-release-local</artifactory.maven.release>
<artifactory.maven.all>maven-repo</artifactory.maven.all>
</properties>
<activation>
<activeByDefault>true</activeByDefault>
</activation>
<repositories>
<repository>
<id>snapshot-repo</id>
<releases>
<enabled>true</enabled>
</releases>
<snapshots>
<enabled>true</enabled>
<updatePolicy>interval:1</updatePolicy>
</snapshots>
<name>maven-integration-local</name>
<url>http://myartifactory.com</url>
</repository>
</repositories>
<pluginRepositories>
<pluginRepository>
<id>jcenter</id>
<url>http://jcenter.bintray.com</url>
<snapshots>
<enabled>false</enabled>
</snapshots>
</pluginRepository>
<pluginRepository>
<id>artifactory-plugin</id>
<url>${artifactory.url}/${artifactory.maven.all}</url>
<snapshots>
<enabled>true</enabled>
</snapshots>
</pluginRepository>
</pluginRepositories>
</profile>
</profiles>
The artifactory contains a pom, which my own project is dependent on (BOM style import of pom to build my own local project). And it looks like maven is successfully downloading everything FINE until it gets to a specific jar:
Could not resolve dependencies for project xxx:1.1.0: The following artifacts could not be resolved: com.japisoft:xmlpad-res:jar:3.7
I checked and the jar does indeed exist in the artifactory (xmlpad-res-3.7.jar), but maven claims that it can't find it. I tried downloading the jar and installing it using maven install plugin, but this did not help.
Why can't maven find the file and what can I do about it?
Upvotes: 0
Views: 8600
Reputation: 2209
I encountered the same problem when mistakenly removed/modified the maven .settings file;
To fix that try the following steps:
Upvotes: 1