On 22/04/2010 11:00 AM, Halvor Platou wrote:
Hello

We have a problem concerning building of maven snapshot artifacts that seems 
very odd.

Let's say we have artifact: "A" and artifact: "B".
"A" depends on "B".
If we build both of these on one computer, everything seems fine.

If then artifact "B" is built and deployed(Nexus) on a different computer, "mvn install -U" on 
artifact "A" on the first computer will not get the new artifact "B", but use the one in the local 
repository.

It seems that when we build locally the file "maven-metadata-local.xml" is created in the 
local repository containing<localCopy>true</localCopy>. As long as this is set to true it 
will not get any new artifacts from the remote repository(Nexus) even if they are newer and we 
specify -U. Removing the localCopy line or changing it to false will make it download the new 
artifact.

  Is it supposed to be like this? And has it always been like this?

Halvor

Since you are deploying multiple times, you should be using SNAPSHOTS and you should always get the latest from the Nexus.

If they are releases, then it should not matter whether you get it from your local repo or somewhere else since releases are immutable and all copies of the same release versions are supposed to be identical.

If you make a mistake in a release, you have to delete the bad copy from everywhere that has the wrong release.


Ron



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to