java - mvn dependency:tree tries to get artifact from artifactory when it shouldn't -
i have moderate sized project many modules depending on each other. when run mvn compile
or mvn package
works, when try run mvn dependency:tree
root directory fails complaining cannot artifact artifactory. true artifact not exist in artifactory. 1 of modules have written , dependency of module in project. why mvn dependency:tree
searching module in artifactory when should recognize first-party module? mvn package
not complain. please advise. maven error this
[error] failed execute goal on project xxx: not resolve dependencies project xxx: not transfer artifact yyy from/to repo (zzz): failed transfer file: yyy. return code is: 503 , reasonphrase:error. -> [help 1]
this settings.xml
in case needed:
<?xml version="1.0" encoding="utf-8"?> <settings xsi:schemalocation="http://maven.apache.org/settings/1.1.0 http://maven.apache.org/xsd/settings-1.1.0.xsd" xmlns="http://maven.apache.org/settings/1.1.0" xmlns:xsi="http://www.w3.org/2001/xmlschema-instance"> <mirrors> <mirror> <mirrorof>external:*</mirrorof> <name>repo</name> <url>http://xxx/artifactory/repo/</url> <id>repo</id> </mirror> </mirrors> <profiles> <profile> <repositories> <repository> <snapshots> <enabled>false</enabled> </snapshots> <id>central</id> <name>artifactory central</name> <url>http://xxx/artifactory/libs-release/</url> </repository> <repository> <releases> <enabled>false</enabled> </releases> <id>snapshots</id> <name>artifactory snapshots</name> <url>http://xxx/artifactory/libs-snapshot/</url> </repository> </repositories> <pluginrepositories> <pluginrepository> <snapshots> <enabled>false</enabled> </snapshots> <id>central</id> <name>artifactory plugins central</name> <url>http://xxx/artifactory/plugins-release/</url> </pluginrepository> <pluginrepository> <releases> <enabled>false</enabled> </releases> <id>snapshots</id> <name>artifactory plugins snapshots</name> <url>http://xxx/artifactory/plugins-snapshot/</url> </pluginrepository> </pluginrepositories> <id>artifactory</id> </profile> </profiles> <activeprofiles> <activeprofile>artifactory</activeprofile> </activeprofiles> </settings>
'mvn package' skips 'validate' phase of maven cycle.
this way succeed 'mvn package' , never knew 'validate' issue.
Comments
Post a Comment