Any body clear my doubt in log4j
1 posts in topic
Flat View  Flat View
TOPIC ACTIONS:
 

Posted By:   veeru_sarravanan
Posted On:   Monday, October 25, 2004 12:25 AM

hi,

Any body clear my doubt in log4j,my doubt is



For example if i set two appenders in properties file(one is for file and other one is database)can we set either one of this as on or off and then use one file to append log messages.is it possible?



for example suppose i need one message to go in file at that time database appender should in off like that when one messages to go in database at that time other appender is in off.



is it possible if possible can u sent small examples,p>

regards

veru

Re: Any body clear my doubt in log4j

Posted By:   Anonymous  
Posted On:   Monday, October 25, 2004 05:53 AM

You can define both appenders. But in another step you have to add the appender to the category. So you decide while configuration where to log. If you add both, messages are logged to both. If you define only one, the message is logged there. The application doesnt know where (or whether) it is logged.
About | Sitemap | Contact