Hi Marc,
You might get away with this if your apps have absolutely *no* transient
dependencies in common. But that is unlikely.
As I understand the current maven situation, if you have two projects
that depend on foo-1.0-snapshot for example, then two builds running
parallel *using the same repo* may try to download a new version of this
file concurrently and both try to write simultaneously to the same files
in the repo. You then have corrupted files in the repo which is
obviously not good.
Maven supports the "--settings" commandline option to specify an
alternate settings file. And a settings file can specify where the maven
repository is kept. So I would recommend that each of your "parallel"
instances use a different settings.xml file with a separate repository.
This will use more diskspace, as each repo will have its own copy of the
dependencies - but no write-race conditions can occur as the repos are
separate. Note, however, that this means that two parallel instances
will not see each other's built artifacts; they will only see artifacts
that have been deployed to a remote maven repository that is listed in
the <repository> section. In practice, this setup would be just like
having a continuum installed on multiple physical servers. Or like
having each continuum instance running as a different user (where again
there would be a separate repo for each user).
If you could somehow prevent any downloads of new files into the repo
from succeeding, eg by defining a <mirrorOf> entry that points to an
always-empty repo then that should also work, as long as two parallel
builds never try to build+install the same artifact. But of course then
if someone updates a pom.xml to add a new dependency then you will
somehow have to load that new dependency manually into your repo. That
seems like a hassle to manage, but might be ok if you already have
strict QA rules on adding new dependencies.
Regards,
Simon
Lustig, Marc (Allianz Deutschland, externer Mitarbeiter) schrieb:
so, if each mvn-project exists in only one of the Continuum-instances, no conflict should occur, right?
Deploying the artifact into Archiva is synchronized anyway, I suppose.
-----Ursprüngliche Nachricht-----
Von: Emmanuel Venisse [mailto:[EMAIL PROTECTED]
Gesendet: Dienstag, 23. September 2008 13:39
An: [email protected]
Betreff: Re: running n parallel Continuum installations
The potential issue with a single local repo with a parallel build is if two
build try to download or install the same artifact in it.
Emmanuel
On Tue, Sep 23, 2008 at 12:01 PM, Lustig, Marc (Allianz Deutschland,
externer Mitarbeiter) <[EMAIL PROTECTED]> wrote:
Our project contains several hundred Maven-projects, which need to get
tested and snaphots built using Continuum.
My plan is to install a number of Continuum-webapps into a single JBoss
AS-container, each one having its dedicated database.
Anybody sees any potential issues in such scenario?
(I read on the list that there is an issue related to accessing the local
mvn-repo, but I don't understand what actually might cause any trouble
here?!)