I\'m trying to run mvn clean package on my Maven project and it fails with the message:
\"required artifact is missing\" for the artifact net.ezswit
Apparently error message "required artifact is missing" was hiding the actual root cause, which was not visible in the message(s). Running Maven with debug messages on (-X option) will print out additional information that gives more detailed insight as to what would be the problem.
For future reference, this time the error was
[WARNING] Unable to get resource 'net.ezswitch:ResourcesComponent:pom:0.0.14' from repository central (ezpay-dev.liquix.eu:9998/repository):
Specified destination directory cannot be created: /Users/hordine/.m2/repository/net/ezswitch/ResourcesComponent/0.0.14
Which wasn't visible without the debug flag.
Just had this problem. Went through so many solutions on my Mac. In the end changed my
~/.m2/settings.xml
changed this:
<localRepository>${USER.HOME}/.m2/repository</localRepository>
to this:
<localRepository>${env.HOME}/.m2/repository</localRepository>
you can see all the properties you have to play with on a mac by typing in a terminal
export
If you haven't already, could you please try:
mvn -U clean package
In addition updating all snapshot versions, in case they have been newly deployed to the repository since Maven's once a day snapshot check, this will also force Maven to update its other cached repo resolutions, such as 404's.