If it works, I like it :-)
On Fri, Dec 30, 2011 at 3:01 PM, Daniel Frett <[email protected]> wrote: > > On Dec 30, 2011, at 2:33 PM, Scott Battaglia wrote: > > > > At this point, if you don't added defaults to > > the property placeholder configurer, at a minimum they will need to touch > > their cas.properties. > > True. > > > > If you add the default to the log4jConfiguration.xml > > file directly then everyone who wants to externalize those would then > need > > to override that file. > > Not true. They would override the log4j init setting in cas.properties. > > Unless you're adding a second property placeholder here that references > the same cas.properties file, how do you plan on adding the defaults if > they aren't hard-coded in the bean definition? > > Maybe the easiest way to demonstrate would be to update the pull request > with your proposed way of handling defaults? Rather than us go back and > forth probably saying the same thing differently. > > > What I've done in my local war overlay to make handling overriding > properties easier is to set the propertyPlaceholderConfigurer bean to load > multiple properties files for the settings. Using this I am able to not > need to modify cas.properties directly and just modify our own properties > file that is loaded after cas.properties that overrides any default > settings. > > We could use this approach with the stock cas deployment to address this > issue and allow future properties configuration changes that won't require > additional work for deployers. So, add a default.properties file that sets > all the default values for placeholders and leave cas.properties as the > file that deployers should override to make setting changes, and update the > propertyPlaceholderConfigurer bean in propertyFileConfigurer.xml to look > like this: > > <bean id="propertyPlaceholderConfigurer" > class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"> > <property name="locations"> > <list> > <value>/WEB-INF/default.properties</value> > <value>/WEB-INF/cas.properties</value> > </list> > </property> > </bean> > > -Daniel > > -- > You are currently subscribed to [email protected] as: > [email protected] > To unsubscribe, change settings or access archives, see > http://www.ja-sig.org/wiki/display/JSG/cas-dev > > -- You are currently subscribed to [email protected] as: [email protected] To unsubscribe, change settings or access archives, see http://www.ja-sig.org/wiki/display/JSG/cas-dev
