commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <>
Subject [Jakarta-commons Wiki] Update of "Logging/FrequentlyAskedQuestions" by SimonKitching
Date Tue, 19 Apr 2005 07:09:45 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Jakarta-commons Wiki" for change notification.

The following page has been changed by SimonKitching:

The comment on the change is:
minor clarifications on logging init/termination

  In particular, it is intended to allow library code to contain logging calls without caring
about what concrete log implementation
  is being used by the wider application the library is deployed within.
- It is not intended to isolate applications from the logging-specific details of initialization
and termination.
+ It is not intended to isolate applications from the logging-library-specific details of
initialization and termination.
  The fact that some logging implementations auto-configure themselves when first used doesn't
mean that commons-logging guarantees to
  do this in all cases, nor that the default initialization behaviour of the concrete logging
libraries is appropriate under all circumstances.
@@ -53, +53 @@

  all libraries will work correctly in this manner, nor that commons-logging will isolate
code from this task.
  In short: when necessary, obtain a reference to the actual underlying log implementation
and use library-specific calls to initialise
- and terminate as required. 
+ and terminate as required. Yes this means that at least one part of your code will need
to know what actual logging library is being
+ used, and reference classes from that actual logging library to do the appropriate initialisation/shutdown.
  If you need a reference to the underlying object for a particular commons-logging Log object
in order to perform initialisation or
  termination, then in most cases the org.apache.commons.logging.Log class can be downcast
to a concrete type that then has a
- "getLogger" method that returns the real underlying object.
+ "getLogger" method that returns the real underlying object. However in most cases this is
not necessary, as initialisation/shutdown
+ methods need to be invoked on "the logging library as a whole" rather than the objects representing
individual logging categories.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message