Re: Loggers share an Appender instance?
Hi Shef, Looks like your question is like mine ( http://old.nabble.com/Multiple-log-files%2C-multiple-logger-names-and-the-same-appender-td28024737.html ). My appender is only one by I want a logger specific file. The recommendation is a custom appender. Thanks, Mohan -- View this message in context: http://old.nabble.com/Loggers-share-an-Appender-instance--tp29741792p29969699.html Sent from the Log4j - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: log4j-user-unsubscr...@logging.apache.org For additional commands, e-mail: log4j-user-h...@logging.apache.org
Re: [SCL-2] Re: Multiple log files, multiple logger names and the same appender
My initial idea is to pass multiple file names in the XML in the appender section and maintain a list in the custome appender Java code and then based on the logger name or some other parameter pick the correct file name. Performance is one of our major concerns. -- View this message in context: http://old.nabble.com/Multiple-log-files%2C-multiple-logger-names-and-the-same-appender-tp28024737p29971726.html Sent from the Log4j - Users mailing list archive at Nabble.com. - To unsubscribe, e-mail: log4j-user-unsubscr...@logging.apache.org For additional commands, e-mail: log4j-user-h...@logging.apache.org
Re: [SCL-2] Re: Multiple log files, multiple logger names and the same appender
If you have a limited set of loggers you are concerned with, just create a separate appender for each file you want created. So, if you have 5 loggers you care about, just create 5 appenders; each with its own file. Then associate the appropriate appender with the appropriate logger. In that case, there's no need to create a custom appender. Jake On 10/15/2010 7:46 AM, Mohan.Radhakrishnan wrote: My initial idea is to pass multiple file names in the XML in the appender section and maintain a list in the custom appender Java code and then based on the logger name or some other parameter pick the correct file name. Performance is one of our major concerns. - To unsubscribe, e-mail: log4j-user-unsubscr...@logging.apache.org For additional commands, e-mail: log4j-user-h...@logging.apache.org