Can anyone please suggest me a best practice for custom properties in struts 1.2, I mean where to place the properties file (under WEB-INF or somewhere else) and how to access or address them relatively from struts Action class.
Joined: Sep 19, 2008
I put the property file in a particular place where i used to put all the property file for different appliation.
Note : the above paths are not intended appropriately
Then in the server(Application or webserver) configuration ,i pass the path to the property file as system property via JVM argument.
like -DAPP2Prop=path to app2.properties -DApp1Property=path to app1.properties.
Then whn you run the application you can read it as System.getProperty(App2Prop) and pass it to the argument as Property constructor.
Well i am not sure this is a good idea or not? But this works atlease for me so far.