logging-log4j-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sudharma Puranik (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (LOG4J2-314) How to create multiple appenders at runtime, sharing an AsyncAppender?
Date Tue, 23 Jul 2013 12:24:50 GMT

    [ https://issues.apache.org/jira/browse/LOG4J2-314?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13716345#comment-13716345
] 

Sudharma Puranik commented on LOG4J2-314:
-----------------------------------------

hmm.. I think as of now I can go ahead but I am really counting because we have major GA in
Jan 2014. Hope log4j 2 will stabilize eventually. 
                
> How to create multiple appenders at runtime, sharing an AsyncAppender?
> ----------------------------------------------------------------------
>
>                 Key: LOG4J2-314
>                 URL: https://issues.apache.org/jira/browse/LOG4J2-314
>             Project: Log4j 2
>          Issue Type: Question
>          Components: Appenders, Configurators
>            Reporter: Sudharma Puranik
>         Attachments: asyncAppendThread.png, log4j2.xml, loggerThread.png, TestAppender.zip
>
>
> I have a log4j2.xml configuration file from which I am getting the Logger, attached is
the snapshot. when my logger is created a new thread is created.
> Programmatically,I create a RollingFileAppender and attach the it to AsyncAppender .
I attach the Async Appender to the configuration of the log4j.xml, And when I start the Async
Appender again a new thread is created.
> Is this a bug? because I get a logger a new thread is generated and when I create a async
appender another thread is created and both are doing the same job.
>  Also there is already a asyncappender in my log4j2.xml and I am creating one via program.
Will this cause a problem? I did this because I am currently unable to hook my programmatically
created appender to the AsyncAppender defined in log4j2.xml.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-dev-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-dev-help@logging.apache.org


Mime
View raw message