Interesting question. You can invoke the DOMConfigurator multiple times as much as you can invoke the PropertyConfigurator multiple times. (You can).
However, both configurators when they see a category definition in a config file will remove all the appenders in *that* specific category. Thus, in general, merging two property files and invoking PropertyConfigrator (once) is different from invoking PropertyConfigrator twice on the unmerged property files. Having said that, it is very important to remember that a category is defined in a single line (i.e. in a single property). Thus, if the separate properties are equivalent to the merged properties, then the two sets of properties are disjoint (they have no elements in common). The same principle applies to the DOMConfigurator. Thus, the short answer is just try and it should work. Regards, Ceki --- Georg Lundesgaard <[EMAIL PROTECTED]> wrote: > Hi! > > We are using Log4j in our application running on > several application > server instance. Each instance have its own set of > properties while most > of it is the same for all instances. Since all > instances use the same > database, all log messages would go here (we're > going to use > JDBCAppender for logging). So, is it possible to > invoke DOMConfigurator > twice, once for the default configuration, and > second for the custom? Or > do I have to merge the xml files first? > > When using PropertyConfigurator, doing this was easy > and problem-free > (well, it was a problem before solving the problem > with PropertySetter. > See the patch submittied earlier for this.). I just > used standard Java > properties with a default and custom part which made > it all transparent. > But I figured out that we need to use filters, and > as I can see only > DOMConfigurator allow the usage of filters. Please > correct me if I am > wrong about this. > > Regards, > Georg Lundesgaard (mailto:[EMAIL PROTECTED]) > Enonic AS (http://www.enonic.com) > > -- > To unsubscribe, e-mail: > <mailto:[EMAIL PROTECTED]> > For additional commands, e-mail: > <mailto:[EMAIL PROTECTED]> > __________________________________________________ Do You Yahoo!? Yahoo! GeoCities - quick and easy web site hosting, just $8.95/month. http://geocities.yahoo.com/ps/info1 -- To unsubscribe, e-mail: <mailto:[EMAIL PROTECTED]> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>