Hi
We are using log4plsql with log4j to log messages to external appenders.
Appenders are getting the messages from log4plsql if the threshold is set.
If the threshold is set in log4j configuration file then appenders are not getting the 
messages.

Problem:
Levels in log4plsql using are 
        10,OFF
        20,FATAL
        30,ERROR
        40,WARN
        50,INFO
        60,DEBUG
        70,ALL

which are different from Log4j
Log4j default level are :
        Integer.MAX_VALUE, OFF
        50000,FATAL
        40000,ERROR
        30000,WARN
        20000,INFO
        10000,DEBUG
        Integer.MIN_VALUE,ALL
        
And these are reverse orders also ( as compared with the levels log4plsql levels in 
the table).

Is it possible to change the code log4plsql Background process according to log4j 
levels?
        
        a).Instead of callAppenders in ReaderLogDatabase.sqlj

                switch (piped_LLEVEL) {
                        case 20:
                                dbLogger.fatal(piped_LTEXTE);
                                break;
                        case 30:
                                dbLogger.error(piped_LTEXTE);
                                break;
                        case 40:
                                dbLogger.warn(piped_LTEXTE);
                                break;
                        case 50:
                                dbLogger.info(piped_LTEXTE);
                                break;
                        case 60:
                                dbLogger.debug(piped_LTEXTE);
                                break;
                        default:
                                dbLogger.error(piped_LTEXTE);
                                break;                          
                
        or
        b).     we can extend level class and write a new class for log4plsql for 
log4j and for setting threshold give the class                name in the 
configuration file. For this code change in log4plsql background process is 

                public
                        boolean isGreaterOrEqual(Priority r) {
                                return r.isGreaterOrEqual(this);
                        }

                As the check for the Priority is different for log4j and log4plsql.

or

Any other solution please let me know.

Thanks&Regards,
Ramakrishna.

Visit our website at http://www.ubs.com

This message contains confidential information and is intended only
for the individual named.  If you are not the named addressee you
should not disseminate, distribute or copy this e-mail.  Please
notify the sender immediately by e-mail if you have received this
e-mail by mistake and delete this e-mail from your system.

E-mail transmission cannot be guaranteed to be secure or error-free
as information could be intercepted, corrupted, lost, destroyed,
arrive late or incomplete, or contain viruses.  The sender therefore
does not accept liability for any errors or omissions in the contents
of this message which arise as a result of e-mail transmission.  If
verification is required please request a hard-copy version.  This
message is provided for informational purposes and should not be
construed as a solicitation or offer to buy or sell any securities or
related financial instruments.



-------------------------------------------------------
This SF.Net email is sponsored by: GNOME Foundation
Hackers Unite!  GUADEC: The world's #1 Open Source Desktop Event.
GNOME Users and Developers European Conference, 28-30th June in Norway
http://2004/guadec.org
_______________________________________________
Log4plsql-all-info mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/log4plsql-all-info
log4plsq : http://log4plsql.sourceforge.net

Reply via email to