logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Integrator <j2eeres...@hotmail.com>
Subject Re: Advantages of using static log methods vs sub classes methods
Date Mon, 12 Nov 2007 20:16:48 GMT

The loggers instance are being generated from a factory pattern in a j2ee
aplication and implements the log methods from wrapper class. Rather then
calling default logging methods from Logger (Catagory) Class. 

Thanks.


James A. N. Stauffer wrote:
> 
> A wrapper class (if you use something I suggest that you use something
> that
> is has been well-tested like commons-logging instead of writing your own)
> allows you to switch logger implementations but probably prohibits the use
> of some functionality.  I would suggest using a wrapper only if you
> foresee
> the need to change logger (i.e. if you are writing a framework and want to
> leave the logger choice to someone else).
> 
> On Nov 12, 2007 1:46 PM, Integrator <j2eeresume@hotmail.com> wrote:
> 
>>
>> Hi ,
>>
>> I am comparing the advantages and disadvantages using log4j at its own vs
>> some sub classes (or wrapper classes) with methods for logging messages
>> from
>> application.
>>
>>
>> Which one is better and why ? So far i could understand Utilization of
>> wrapper ensures that you are not tied to specific logging solutions.
>>
>> Is that it or there is something more ? Please express your views and
>> experience on it.
>>
>> Thanks,
>> Integrator
>>
>> --
>> View this message in context:
>> http://www.nabble.com/Advantages-of-using-static-log-methods-vs-sub-classes-methods-tf4793407.html#a13712766
>> Sent from the Log4j - Users mailing list archive at Nabble.com.
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
>> For additional commands, e-mail: log4j-user-help@logging.apache.org
>>
>>
> 
> 
> -- 
> James A. N. Stauffer        http://www.geocities.com/stauffer_james/
> Are you good? Take the test at http://www.livingwaters.com/good/
> 
> 

-- 
View this message in context: http://www.nabble.com/Advantages-of-using-static-log-methods-vs-sub-classes-methods-tf4793407.html#a13713254
Sent from the Log4j - Users mailing list archive at Nabble.com.


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


Mime
View raw message