On Wed, Aug 22, 2001 at 05:59:05PM -0500, Morgan Delagrange wrote:
> Hi all,
> 
> I doubt many people out there are really aware of Latka right now :).
> However, in case anyone out there is experimenting with it right now, I'm
> working on improving the methods for configuring Latka, and I want to give
> the oppportunity for feedback.
> 
> Today I removed Latka's ability to configure its variables from System
> properties.  I've replaced it with a ThreadLocal reference to a Properties
> object, which should make configuration of Latka more threadsafe while still
> making it easy to get at Properties anywhere in the application.  Now I'm
> pondering how best to set those properties from the command-line interface.
> Perhaps something like:
> 
>   java -Dlatka.userProps=<path to prop file> org.apache.commons.latka.Latka
> <path to Latka XML file> [<latka property> <latka property> ...]

Perhaps adopting log4j's strategy would work, where if a config file is
not specified, a default latka.properties is searched for in the
classpath. This is overridable from the command-line of course. The
relevant code is in o.a.log4j.Category. I'd do a straight cut'n'paste ;)

Also, how are custom Validators to be configured, if
System.getProperties(..) is no longer the mechanism? Perhaps there
should be a method added to o.a.c.latka.Validator, to define the
option-passing contract? Or perhaps simply stealing ideas, if not code,
from log4j's configuration mechanism would be best
(PropertyConfigurator, DOMConfigurator).

--Jeff

(who would like to add a validate-returned-XML-against-a-DTD Validator
if he ever gets time)

[snip]

Reply via email to