I don't believe you should put environment specific, such as TEST-db
connection params vs PROD-db connection params in the binary.  Put that
information in a file which can be edited outside your artifact (jar, war,
ear).  As long as this config file is in your classpath, then you can access
it from your java application.

You want to be able to TEST a binary and move that exact binary to
production without ANY modification.

On 7/30/07, Georg Öttl <[EMAIL PROTECTED]> wrote:
>
> Hi
>
> I have a different configurations (spring, Text files and so on). I really
> tried hard to figure out how I should handle those runtime configurations
> with maven. Has anybody done such a thing so far?
>
> My problem is: If I put the configuration into the src/main/resources
> directory and therefore directly into the distributed jar it will be hard
> (but possible) to override the default configuration. If I put the
> resources
> outside the resources directory I couldn't figure out how deploy it.
> Depended projects won't get the configuration if I can't deploy it to a
> remote repo :-(.
>
> The remote-resources plug-in looks somehow like what I need -  but the
> documentation is not that good. Couldn't really use it by now. If I'm
> right
> this plug-in should allow to deploy "remote-resources".
>
> I'd find it cool to be able to specify
>
> "Project-X.jar depends on Project-A-resources-1.0.SNAPSHOT.jar"
> "Project-X1.jar depends on Project-B-resources-1.0.SNAPSHOT.jar"
> "Project-X2.jar depends on Project-A-resources-1.0.SNAPSHOT.jar"
>
> Is this a feature I have to wait for or did I overlook a really simple
> solution?
>
>
> PS: Does anybody know how to deploy an assembly with the deploy plug-in?
> Or
> is this a thing "not to do".
>
> Best regards,
> Georg
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>

Reply via email to