Thanks a lot, that's it!

I must have missed this info while reading the docu.

Sven

> -----Ursprüngliche Nachricht-----
> Von: Ceki Gülcü [mailto:[EMAIL PROTECTED]]
> Gesendet am: Donnerstag, 14. Juni 2001 11:09
> An: LOG4J Users Mailing List; 'LOG4J Users Mailing List'
> Betreff: Re: AW: Appender that sends a mail
> 
> 
> Hello,
> 
> Combinations of appenders is not an issue. The SMTPAppender 
> requires the JavaMail API which requires the JavaBeans 
> Activation Framework. Are the associated jar files accessible 
> to your servlet? Regards, Ceki
> 
> 
> At 10:44 14.06.2001 +0200, Scheil, Sven wrote:
> >I've still the problem that my jsp hangs up, when the 
> execution comes to the
> >line that initializes the log category.
> >
> >The error log of the iplanet webserver says:
> >[14/Jun/2001:10:18:12] warning (11553): Internal error: Failed to get
> >GenericServlet.
> >(uri=/eva_mp/jsp/ServiceFC.jsp,SCRIPT_NAME=/eva_mp/jsp/ServiceFC.jsp)
> >
> >Jim Moore said the default behavior of the SMTP Appender is 
> to send a mail
> >when an error event occurs. So I don't have to implement an 
> event trigger
> >unless i want to change this behavior - right? Is it 
> possible that the
> >combination of my three appenders (see config file below) 
> raises this error?
> >
> >Jim Moore suggested: Testing of the SMTP server, but it 
> doesn't come to send
> >a mail. But I've tetsted the SMTP server as well and it's 
> running under the
> >specified address and port 25.
> >
> >Here is the code of my jsp (ServiceFC.jsp):
> >
> ><%@ page errorPage="errorpage.DE.jsp" %>
> ><%@ page import="org.apache.log4j.Category" %>
> >
> ><%!     protected static Category logger;
> >        static {        
> >                logger = Category.getInstance("ServiceFC");
> >        }
> >%>
> >
> ><%      
> >   response.setDateHeader("Expires",0);
> >   response.setHeader("Pragma","no-cache");
> >   response.setHeader("Cache-Control","no-cache,must-revalidate");
> >%>
> > 
> >... my code: some bean instantiation ...
> >
> > <%  
> >  org.apache.log4j.NDC.push(session.getId());
> >
> >... my code: calling beans ...
> > 
> >  org.apache.log4j.NDC.pop();
> > %>
> >
> >
> >Any help would be appreciated,
> >Sven.
> >
> >
> >-----Ursprüngliche Nachricht-----
> >> Von: Jim Moore [mailto:[EMAIL PROTECTED]]
> >> Gesendet am: Mittwoch, 13. Juni 2001 16:47
> >> An: 'LOG4J Users Mailing List'
> >> Betreff: RE: Appender that sends a mail
> >> 
> >> log4j.appender.A3.EvaluatorClass=MyTriggeringEventEvaluator
> >> 
> >> public class MyTriggeringEventEvaluator implements 
> >> TriggeringEventEvaluator
> >> {
> >>   /**
> >>    * Is this the triggering event?
> >>    */
> >>   public boolean isTriggeringEvent(LoggingEvent event) {
> >>     // whatever criteria you want
> >>     if (event == null) {
> >>       return false;
> >>     }
> >>     else {
> >>       return event.priority.isGreaterOrEqual(Priority.ERROR);
> >>     }
> >>   }
> >> }
> >> 
> >> 
> >> Does it hang simply because of adding to A3's buffer, or when 
> >> it tries to
> >> actually send the email?
> >> 
> >> -Jim Moore
> >> 
> >> 
> >> -----Original Message-----
> >> From: Scheil, Sven [mailto:[EMAIL PROTECTED]]
> >> Sent: Wednesday, June 13, 2001 9:58 AM
> >> To: 'LOG4J Users Mailing List'
> >> Subject: AW: Appender that sends a mail
> >> 
> >> 
> >> I'am trying org.apache.log4j.net.SMTPAppender as the 3rd 
> >> appender in my
> >> log4j conf file. But every time appending the SMTPAppender my 
> >> application
> >> consiting of jsp/beans and servlet hangs up. I have no idea? 
> >> 
> >> The log4j.jar is in the web servers classpath.
> >> 
> >> I've appended my log4j config file.
> >> 
> >> 2nd Question: What do I have to do in detail to change the 
> >> triggering event?
> >> 
> >> Regards sven
> >> 
> >> 
> >> log4j.rootCategory=DEBUG, A1, A2, A3
> >> 
> >> # A1 is set to be a FileAppender which outputs to System.out. 
> >> log4j.appender.A1=org.apache.log4j.FileAppender
> >> log4j.appender.A1.File=System.out
> >> 
> >> # A1 uses PatternLayout.
> >> log4j.appender.A1.layout=org.apache.log4j.PatternLayout
> >> 
> >> # The conversion pattern uses format specifiers. You might want to
> >> # change the pattern an watch the output layout change.
> >> log4j.appender.A1.layout.ConversionPattern=%d{dd MMM yyyy 
> >> HH:mm:ss} %-5p
> >> [%t] %37c %3x %l - %m%n
> >> 
> >> 
> >> # A2 is set to be a FileAppender which outputs to System.out. 
> >> log4j.appender.A2=org.apache.log4j.FileAppender
> >> 
> log4j.appender.A2.File=/usr1/kunden/eva_mp/Web-inf/Log/EVAapp_mp.log
> >> #log4j.appender.A2.File=EVAapp_mp.log
> >> 
> >> # A2 uses PatternLayout.
> >> log4j.appender.A2.layout=org.apache.log4j.PatternLayout
> >> 
> >> # The conversion pattern uses format specifiers. You might want to
> >> # change the pattern an watch the output layout change.
> >> log4j.appender.A2.layout.ConversionPattern=%d{dd MMM yyyy 
> >> HH:mm:ss} %-5p
> >> [%t] %37c %3x %l - %m%n
> >> 
> >> 
> >> # A3 is set to be a SMTPAppender which outputs to mail
> >> log4j.appender.A3=org.apache.log4j.net.SMTPAppender
> >> [EMAIL PROTECTED]
> >> [EMAIL PROTECTED]
> >> log4j.appender.A3.Subject=EVA Fehler 
> >> log4j.appender.A3.SMTPHost=194.164.4.244
> >> #log4j.appender.A3.BufferSize=100
> >> #log4j.appender.A3.EvaluatorClass 
> >> 
> >> # A3 uses PatternLayout.
> >> #log4j.appender.A3.layout=org.apache.log4j.PatternLayout
> >> 
> >> # The conversion pattern uses format specifiers. You might want to
> >> # change the pattern an watch the output layout change.
> >> #log4j.appender.A3.layout.ConversionPattern=%d{dd MMM yyyy 
> >> HH:mm:ss} %-5p
> >> [%t] %37c %3x %l - %m%n
> >> 
> >> 
> >> 
> >> 
> >> 
> >> 
> >> > -----Ursprüngliche Nachricht-----
> >> > Von: Jim Moore [mailto:[EMAIL PROTECTED]]
> >> > Gesendet am: Mittwoch, 13. Juni 2001 15:04
> >> > An: 'LOG4J Users Mailing List'
> >> > Betreff: RE: Appender that sends a mail
> >> > 
> >> > org.apache.log4j.net.SMTPAppender
> >> > 
> >> > By default it sends it on ERROR or above, but you can change 
> >> > the trigger to
> >> > FATAL if you want.
> >> > 
> >> > -Jim Moore
> >> > 
> >> > -----Original Message-----
> >> > From: Scheil, Sven [mailto:[EMAIL PROTECTED]]
> >> > Sent: Wednesday, June 13, 2001 8:40 AM
> >> > To: 'LOG4J Users Mailing List'
> >> > Subject: Appender that sends a mail
> >> > 
> >> > 
> >> > Hi!
> >> > 
> >> > I'm looking for an appender that sends me a mail when a 
> >> fatal error is
> >> > logged. Is such an appender existing?
> >> > 
> >> > Regards
> >> > Sven
> >> > 
> >> > 
> >> 
> ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> > For additional commands, e-mail: 
> [EMAIL PROTECTED]
> >> > 
> >> > 
> >> 
> ---------------------------------------------------------------------
> >> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> > For additional commands, e-mail: 
> [EMAIL PROTECTED]
> >> > 
> >> 
> >> 
> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >> 
> >> 
> ---------------------------------------------------------------------
> >> To unsubscribe, e-mail: [EMAIL PROTECTED]
> >> For additional commands, e-mail: [EMAIL PROTECTED]
> >> 
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> 
> --
> Ceki Gülcü
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to