Michael L. Heuer wrote:

> On Tue, 1 May 2001, Earl Hood wrote:
> 
>> My $0.02 opinion: From the goal statements on the jakarta web-site for
>> Commons, it seems that Commons components should try to provide
>> well-defined exceptions and let the component user manage any logging
>> functionality (to support the goal of minimal dependencies).
>> Well-defined exceptions, and support for listeners (where appropriate),
>> should be sufficient to support a user in whatever logging system they
>> choose to use.
> 
> 
> Very well said.
> 
> I'm not a voting member, but am against inclusion of log4j.
> Throw appropriate exceptions.
> 
>    michael
> 
Not all logs messages are exceptions. Debug logging, for example, is 
often the normal path of execution. Logs may also present information 
that should not be exposed to clients of the component. For example, it 
is entirely appropriate for a database connection pool to print out 
information about the size of the cache, whether new connections are 
being allocated, the hit rate for the cache, deallocation, disconnction 
of the physical db conn, and so on. All of which is properly hidden by 
the abstraction of the pool. Even suggesting that a client could depend 
on them by providing listener callbacks is a bad idea.

Debug logs should be noisy. The control should come through enabling and 
disabling categories, not by controlling the priority.

Assume that the java.logging.* package and log4j will coexist somehow. 
When JDK 1.4 is released, it will be a priority for enough people that 
the problem will be solved. It will be years until it can be blithely 
assumed that JDK 1.4 can be targetted. JDK 1.2 targetting is still 
controversial.

<><><><><><><><><><><><><><><><><><><><><>This electronic mail transmission
may contain confidential information and is intended only for the person(s)
named.  Any use, copying or disclosure by any other person is strictly
prohibited.  If you have received this transmission in error, please notify
the sender via e-mail. <><><><><><><><><><><><><><><><><><><><><>

Reply via email to