Can try - When your app start make sure the first class that runs does not have a log4j instance member or other reference to log4j besides the repository call. Use system out till then.
On 7/19/11, Turner, Jay <[email protected]> wrote: > I call my Library Jar which has log4j setup in it. I'm calling a static > method in my class. Before I can get to the > LogManager.setRepositorySelector, log4j gets to run, loads its configuration > from log4j.configuration, can't interpret the unrecognized parameters, and > generally finishes initialization. I suspect that when I enter the Library > to run a static method that all of the other statics are run, along with the > statics in log4j.jar. So log4j initializes before you can get a chance to > setup anything. Unless I'm missing something, how can I get around this > Catch-22? > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
