On Sat, 2010-04-10 at 23:01 +0200, Mikael Magnusson wrote:
> Customizable application config defaults
>
> Add config_defaults/0 to the YXA application behaviour, returning the
> application config defaults as a list of #cfg_entry{}.
>
> It allows setting application defaults in an (external) YXA application
> without changing core files in the yxa application and rebuilding YXA.
> For example when making an application which uses the
> presence_packagemodule and therefore needs the
> presence_default_publish_time and other config variables.
>
> git fetch git://github.com/mikma/yxa.git config
Thank you for the excellent presentation of the suggested addition =).
The idea sounds good to me, but I'd say there is precedent (hope I'm
using that word correctly) to adding a hook to local.erl for doing that
kind of thing. Was there a reason to add it to the YXA application
behaviour instead?
Also, I do think it is a good idea to break up the ?APPLICATION_DEFAULTS
into smaller defines, but I think they should be
called ?PSTNPROXY_CONFIG_DEFAULTS or similar instead
of ?PSTNPROXY_DEFAULTS in case we figure out something else than user
configuration that should have per-application defaults. Maybe I'm being
too careful here? Is it in fact per definition only configuration that
can have defaults? =)
/Fredrik
_______________________________________________
Yxa-devel mailing list
[email protected]
https://lists.su.se/mailman/listinfo/yxa-devel