logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dev2...@stefanclos.de
Subject Re: smtp appender - no email send
Date Wed, 31 Jul 2013 11:57:22 GMT
Yipiee, have solved it :)

Needed following definition:
log4j.rootCategory=DEBUG, Console, R, EMAIL


I´ve checked active Loggers with this code, Emails wasn´t in the list:

Logger l = logger.getRootLogger();
Enumeration e = l.getAllAppenders();
while(e.hasMoreElements()) {
	Appender a = (Appender)e.nextElement();
	logger.debug("Appender: " + a);
}





Zitat von dev2013@stefanclos.de:

> Hello Gokul,
>
> thanks, i took care about this.
> There is an error event, which is logged by console and file appender.
>
> [2013-07-31 10:36:28,923] ERROR [FtpClient.connect]connect: Address  
> is invalid on local machine, or port is not valid on remote machine   
>                                                          
> (FtpClient.java#connect:65)
>
>
>
> cheers
> Stefan
>
>
> Zitat von gokulvsmail <gokulvsmail@gmail.com>:
>
>> By default behavior log4j will only send the log messages when a  
>> ERROR event is happening.
>> For testing try by create some error loggs.
>>
>> gokul
>>
>> On Wednesday 31 July 2013 03:23 PM, dev2013@stefanclos.de wrote:
>>> Hello,
>>>
>>> i configured an smtp appender to get log messages by email.
>>> Console and File Appenders work well, but the smtp appender seems  
>>> not to do anything.
>>>
>>> Any ideas ? How can i debug this, i didn´t get any error messages  
>>> from log4j ?
>>>
>>> LOG4J Configuration:
>>>
>>> log4j.appender.email=org.apache.log4j.net.SMTPAppender
>>> log4j.appender.email.Threshold=DEBUG
>>> log4j.appender.EMAIL.SMTPDebug=true
>>> log4j.appender.email.SMTPHost=127.0.0.1
>>> log4j.appender.email.From=stefan.clos@helaba-invest.de
>>> log4j.appender.email.To=stefan.clos@helaba-invest.de
>>> log4j.appender.email.Subject=IBOXX_KURSE_CHECK_ERROR
>>> log4j.appender.email.BufferSize=512
>>> log4j.appender.email.layout=org.apache.log4j.PatternLayout
>>> log4j.appender.email.layout.ConversionPattern=%m
>>>
>>>
>>> cheers
>>> Stefan
>>>
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
>>> For additional commands, e-mail: log4j-user-help@logging.apache.org
>>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
>> For additional commands, e-mail: log4j-user-help@logging.apache.org
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: log4j-user-unsubscribe@logging.apache.org
> For additional commands, e-mail: log4j-user-help@logging.apache.org




---------------------------------------------------------------------
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