This is a frequent issue.
There has been lost of discussion about this.
The Best Practice is to move the deployment info out of your projects into JNDI or some other mechanism that ties the variable information to the thing causing the variability.

Profiles is not the right way to do this.

Look through the archives for lots of threads about this.
There are a lot of reasons given for why this is a bad idea.

http://blog.artifact-software.com/tech/?p=58 might help introduce JNDI.
Read the official docs as well.
They seem to try to make JNDI look more complicated than it actually is but are the definitive docs.

Ron

On 02/02/2011 3:14 AM, nodje wrote:
Hi,

I'm facing a problem in the release process when running Integration Tests.

We have different profiles for the different environments the release is
made for, namely DEV, TEST, PROD.

Each profile has its own values for DB access.

Now the IT are made to work on the development environment, i-e with the
values of the DEV profile.

When it comes to do a release for the TEST or PROD env, Failsafe will run
with the given profile and ITs will fail due to invalid DB access values.

Ideally, I'd like to be able to specify a different profile, DEV here, for
the maven-failsafe-plugin execution.
I don't think this is possible yet.

So I don't understand how IT can be part of a systematic release process.

How do you perform your releases for a production environment with IT
validation?

Is there a trick to be able to use different profile in a single maven
execution?
Is it possible to specify one profile per plugin:

-Pprod for war plugin
-Pdev for failsafe plugin

That's be awesome.

cheers


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@maven.apache.org
For additional commands, e-mail: users-h...@maven.apache.org

Reply via email to