Tobias Bocanegra wrote:
what running modes do you have in mind? if just 'DEBUG' and 'NORMAL' i
suggest to
use system properties.
I guess those two are the most common. I would like to have some default
configuration for these modes already provided. So the only thing you
have to do via a system property would be to switch the running mode.
With OSGi we should also be able to switch the running mode at
runtime...but I don't think that we really need this.
We've added such a support to Cocoon some time ago, and there you
specify the running mode by a system property and each jar file can
provide configuration values for a running mode (by using a convention
path to find these property files). So providing a different
configuration for a running mode is just dropping a jar into the
classpath. (We can also overwrite spring bean definitions in an easy and
convenient way.) With OSGi this could perhaps be just installing a bundle.
Now, I could imagine to have more than one running mode, like one for
testing where you have a different setup, or different debug settings.
If we are able to provide running modes it shouldn't matter if we
support two or more.
Perhaps we don't need this, but once you have a set of services that
provide lets say special debug settings, it's really convenient to just
switch all of them into debug mode (or verbose mode) by setting one
single property. Another example apart from logging is to change the
output of the json writer to pretty print and nicely indent the data
which makes checking the output much easier.
Carsten
--
Carsten Ziegeler
[EMAIL PROTECTED]