logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stadelmann Josef" <josef.stadelm...@axa-winterthur.ch>
Subject AW: configuring email appending for WARN and above
Date Tue, 17 Aug 2010 07:20:07 GMT

If I have the architecture of the log4j system correct in mind ...
It's the Appender which gets attached to the Logger feeding the Appender.
If the your Logger is at level=ERROR then the APPENDER will only receive
ERROR and above messages to append. Therefore I would check first the logger

i.e.
log4j.logger.org.apache.axiom=WARN, email, CONSOLE, R, CHAINSAW_CLIENT
means 
the Logger axiom will feed Appender email, CONSOLE, R and CHAINSAW_CLIENT

Please check your Logger definition and lower it to at least level=WARN
Josef

-----Urspr√ľngliche Nachricht-----
Von: Curtis Garman [mailto:curt.garman@gmail.com] 
Gesendet: Montag, 16. August 2010 19:26
An: log4j-user@logging.apache.org
Betreff: configuring email appending for WARN and above

Can someone tell if it is possible to configure the smtp email appender to
send email for WARN level message and above? I seem to only be able to get
ERROR level stuff to come back in email form.

log4j.appender.email=org.apache.log4j.net.SMTPAppender
log4j.appender.email.SMTPHost=smtp.server
log4j.appender.email.SMTPDebug=false
log4j.appender.email.bufferSize=1
log4j.appender.email.from=from@domain.com
log4j.appender.email.to=to@domain.com
log4j.appender.email.subject=subject
log4j.appender.email.threshold=WARN
log4j.appender.email.layout=org.apache.log4j.PatternLayout
log4j.appender.email.layout.ConversionPattern=[%p]
%d{ISO8601}%n%n%c:%L%n%n%m%n

-- 
Curtis

---------------------------------------------------------------------
To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
For additional commands, e-mail: log4j-user-help@logging.apache.org


Mime
View raw message