[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [xmlblaster-devel] Deprecated logging API
Thomas Tempe wrote:
$ java -version
java version "1.3.1"
Java(TM) 2 Runtime Environment, Standard Edition (build Blackdown-1.3.1-FCS)
Java HotSpot(TM) Client VM (build Blackdown-1.3.1-FCS, mixed mode)
$ javac MyClass.java -deprecation
Registrar.java:3: warning: org.xmlBlaster.util.Log in org.xmlBlaster.util has been deprecated
import org.xmlBlaster.util.Log;
Is this something to worry about?
What's the xmlBlaster recommended way for logging events ?
Yes, please use LogChannel to do logging see for
example
HelloWorld4.java
If you use for example:
final LogChannel log = glob.getLog("myApp");
...
if (log.TRACE) log.trace("xx", "some comment");
you can switch on your specific tracing on command line
(or in the xmlBlaster.property) like:
java MyApp -trace[myApp] true
The old org.xmlBlaster.util.Log is deprecated as it was
a singleton, and singletons are devil :-)
regards,
Marcel
--
Marcel Ruff
mailto:ruff at swand.lake.de
http://www.lake.de/home/lake/swand/
http://www.xmlBlaster.org