[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Handling propeties files

From: Brian Brophy <brianbrophy_at_email.com>
Date: 2006-07-11 13:43:06 CEST

We have a similar requirement that as the application migrates through
environments (dev, test, qa, prod), the configuration usually changes in
each env (different databases, backend services, etc).

What we do is stage a utility jar as follows:
dev
   |-- app.properties
test
   |-- app.properties
qa
   |-- app.properties
prod
   |-- app.properties

We then use a system property (for example -DdeployEnv) to tell the
runtime code which env it is running in. For example, if we pass the
application -DdeployEnv=test it loads from test/app.properties and
-DdeployEnv=prod would equate to prod/app.properties.

~ Brian

Steven Pannell wrote:

>Hi,
>
>I'm new to subversion and would like know if someone can give me pointers to
>the best way to handle application property files for development and
>deployment.
>
>Say I have:
>
>src/com/domain/myapp/config.properties
>
>Now this property file is different for development and deployment. what's
>the best way to handle this problem? OK, I can remove it and put it
>somewhere else and get the ant file t o fix it (or is there a better way).
>Also everytime a developer goes "update" the property file will appear back
>in the tree, can I stop this somehow?
>
>thx.
>Steve.
>
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
>For additional commands, e-mail: users-help@subversion.tigris.org
>
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Tue Jul 11 13:44:39 2006

This is an archived mail posted to the Subversion Users mailing list.