Hi folks,
I am a new user of Log4J ver 1.0.4.
I have come on board to an existing
implementation/project that uses Log4J for logging. I
have a requirement to log to a database. I have taken
a look at the 2 JDBC appenders that have been
contributed but unfortunately, I have to work with the
existing framework (we have our own DB connection
pooling code, DB access wrappers ..etc..)
My questions are:
(1) How can I access each piece of the LoggingEvent
before or after it gets converted to a string? I use
PatternLayout and the format specifiers are more than
enough for my needs. I need to get at these so that
each piece of it can be persisted in a DB column of a
table. Am I restricted to calling layout.format() in
my appender and then parsing thro' this myself? What
would you suggest?
(2) Is logging done via separate threads? i.e. when my
application calls someCategory.info() or other logging
methods, does the log message immediately get output
or is it handed off to a background thread? I think
AsyncAppender does this part of it, but I am unsure
about how to configure this via XML config files since
we use DOMConfigurator extensively. Also, how does
AsyncAppender know how to log to console as well as to
a file (right now, we have this setup)?
Thanks very much for your patience and help,
Dash
__________________________________________________
Do You Yahoo!?
Get email at your own domain with Yahoo! Mail.
http://personal.mail.yahoo.com/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]