maven


Maven can't find artefact from Nexus


We have an Atlassian Bamboo instance building and deploying our projects (snapshots) to Nexus, around 11:20 pm every day.
Another Bamboo instance runs a test plan A at midnight and fails because it can't find an artefact from Nexus (although it's looking in the right repositories), artefact that was built by the other Bamboo instance and is actually in Nexus.
A test plan B starts around 00:30 on the same instance and this one finds the artefact. In the morning, when I manually launch the plan A, it works well.
So I suspect a cache/metadata issue, but I couldn't figure out what is the right configuration to set, either in Nexus or in the Maven settings.
It's running Maven 2.2.1. Other plans running Maven 3.0.5 for a different version of our project don't seem to have the problem. Nexus is 2.7.2-03.
The error is "2 required artifacts are missing." and the list of Nexus groups in "from the specified remote repositories:" is the right one. Those groups are configured like that in the project's pom:
<snapshots>
<enabled>true</enabled>
<updatePolicy>always</updatePolicy>
</snapshots>
Any idea about how to fix this issue?
Thank you!
Best practices we've identified for moving Maven 2 builds to Maven 3:
1) All of the builders (individual users running builds on personal machines plus Jenkins/CI) should be converted at the same time. In other words, once the POM for an artifact has been adjusted as needed and the built artifact deployed to the remote repository with Maven 3, then Maven 2 should not be used to build that same artifact ever again. This is because Maven 3 uses timestamped snapshots, while Maven 2 does not. Also, Maven 2 and Maven 3 handle dependency resolution and repository metadata differently. Mixing the two doesn't work well.
One symptom is someone commits changes, builds, and deploys to the remote repo with Maven 3, then another developer tries to download the changed jar with Maven 2 and gets the old one. The team may prevent the artifacts from being built with Maven 2 using the Enforcer plugin.
2) All builders should clean out their local artifact repositories. Maven 2 and Maven 3 handle dependency resolution and repository metadata differently, and a fresh repository insulates the developer from strange, hard to find problems. (Since Maven will then have to download the world on the first build, consider doing the first Maven 3 build before you go to lunch or leave work for the day.)
3) Someone with delete privileges on the remote repository (e.g. Nexus, Artifactory) should log into the remote repo, find the artifact(s) in the Snapshots repository and delete the snapshot version during which the Maven 2 to 3 migration occurred.
For example, say that the team is working on 2.0-SNAPSHOT, and there's a task to move from Maven 2 to 3 for this version. When the POM changes for the task are complete, the developer logs into the remote repo, finds com.company.some-group:myArtifact(s), and removes the 2.0-SNAPSHOT version entirely. This will remove all snapshots built by Maven 2.

Related Links

Maven site: delete
Selenium tests failing in Unix
Maven - How to build a dependency project
How to make maven consider JavaFX as a part of JRE
Maven plugin prefix resolution doesn't seem to work as expected
Javascript and CSS files combining in Maven build WITHOUT compression, minification etc
Run TestNG single test from one Group
TinyRadius maven repository
Dependency downloaded from Maven Central is free from Malware?
How to use the same target platform multiple sub-projects in Tycho
Maven Grails web.xml
Can I make a Maven profile add webResources to a war and still add non-profiled webResources?
HTTP Status 409 - The target deployment path […] does not match the POM's expected path prefix
Maven command to go back to previous day snapshot
Maven site on multi module project could not resolve dependency
Glassfish Maven Deploy Plugin - Deployment Failure

Categories

HOME
ionic-framework
google-chrome-extension
session
platform-builder
objectgears
setup-deployment
twitter-bootstrap-4
sql-server-2016
django-imagekit
swagger-ui
applepay
node-pdfkit
wheelnav.js
qt-creator
nstableview
windows-phone-7
messages
http-status-code-504
normalizr
contextmenu
paging
jasonette
microsoft-r
wijmo
lcd
fish
semantic-analysis
facebook-access-token
gitignore
fog
avcapturesession
uiswipegesturerecognizer
ghost4j
main
dosbox
code-search-engine
uft-api
hue
tasker
quadratic-programming
jvm-languages
bootstrap-dialog
http-redirect
segment
angular-resource
parentheses
datastax-startup
pebble-watch
powercli
veracode
mplayer
brightcove
akka-cluster
python-cryptography
pdfclown
gcsfuse
hittest
color-profile
medium.com
deadbolt-2
gridpane
infix-notation
android-textview
clang-static-analyzer
hover-over
itextpdf
associative-array
vhd
qtableview
cyclomatic-complexity
wireshark-dissector
sysinternals
vstest.console.exe
sniffer
truevault
system.reflection
pick
angularjs-ng-click
winddk
php-5.4
responsive-slides
starcluster
page-layout
ccss
web2py-modules
shellexecute
padarn
pygit2
flashvars
browser-detection
google-email-migration
runas
armcc
dbproviderfactories
netdna-api
php-parser
infobox
xdomainrequest
rfc1123
file-comparison
datareader
zend-translate
dentrix
perfect-hash
sustainable-pace
sector
zune
ugc
3gp
uiq3
misv

Resources

Mobile Apps Dev
Database Users
javascript
java
csharp
php
android
MS Developer
developer works
python
ios
c
html
jquery
RDBMS discuss
Cloud Virtualization
Database Dev&Adm
javascript
java
csharp
php
python
android
jquery
ruby
ios
html
Mobile App
Mobile App
Mobile App