Hi,

I want to use log4j logging for my application.
I have two options.
- Use the existing logging service provided by jboss ( it essentially menas use 
the log4j instance created by jboss)
- Use my own log4j service (create my own instance)

I had a look into the following article which explains how to integrate jboss 
logging service into our application.

http://www.jboss.org/wiki/Wiki.jsp?page=Logging

My question is what is the advantage of using jboss logging service instead of 
our own.  I require just  5 lines of code to initialize my own logging instance 
in the application , as shown below:


  | 
  | 
  |  InputStream fin = 
Thread.currentThread().getContextClassLoader().getResourceAsStream(mLogFile);
  |         Properties config = new Properties();
  |         config.load(fin);
  |         fin.close();
  |         mLogger = Logger.getLogger(LOG_NAME);
  |         PropertyConfigurator.configure(config
  | 
  | 
  | 

While this is so simple task, why bothering about using jboss logging service? 
is there any performacne advantage? 
Even if I use jboss logging service, it is going to create seperate instance 
for my application logger category. Right?

Please throw your thougts.

-Ravi Prakash

View the original post : 
http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3919286#3919286

Reply to the post : 
http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3919286


-------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc. Do you grep through log files
for problems?  Stop!  Download the new AJAX search engine that makes
searching your log files as easy as surfing the  web.  DOWNLOAD SPLUNK!
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642
_______________________________________________
JBoss-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/jboss-user

Reply via email to