logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ceki Gülcü <c...@qos.ch>
Subject RE: Messages Going to Multiple Loggers
Date Fri, 19 Sep 2003 20:51:52 GMT
Dhruva,

It's actually

  log4j.additivity.notify=false

my bad.

Anyway, I'm glad switching to XML solved the problem.

At 01:45 PM 9/19/2003 -0700, you wrote:
>Well, I couldn't get this to work using a properties file, either as
>
>     log4j.additivity.logger.notify=false
>
>or
>
>     log4j.logger.notify.additivity=false
>
>However, I tried switching to XML (which is much easier to read,
>anyway):
>
>     <logger name="notify" additivity="false">
>       <level value="error" />
>       <appender-ref ref="email" />
>     </logger>
>
>and that did it.
>
>Thanks for your responses!
>Dhruva
>
>--- Ceki Gülcü <ceki@qos.ch> wrote:
> >
> > Additivity applies to loggers not appenders.
> >
> > Try:
> >
> > log4j.additivity.logger.notify=false
> >
> > which should do exactly what you want.
> >
> > HTH,
> >
> > At 12:38 PM 9/19/2003 -0700, Dhruva B. Reddy wrote:
> > >Perhaps I should rephrase the question--is there any way to prevent
> > a
> > >logger from inheriting the rootLogger's appenders?
> > >
> > >I tried adding additivity to the appender, and it didn't like it:
> > >
> > >     log4j.appender.email.additivity=false
> > >
> > >resulted in:
> > >
> > >     log4j:WARN No such property [additivity] in
> > >org.apache.log4j.net.SMTPAppender.
> > >
> > >I also tried adding it to the notify logger, and it ignored it:
> > >
> > >     log4j.logger.notify.additivity=false
> > >
> > >Thanks,
> > >Dhruva
> >
> > --
> > Ceki Gülcü
> >
> >       For log4j documentation consider "The complete log4j manual"
> >       ISBN: 2970036908 http://www.qos.ch/shop/products/clm_t.jsp
> >
> >       import org.apache.Facetime;
> >       ApacheCon US 2003, 18-21 November http://apachecon.com/
> >
> >
> >
> > ---------------------------------------------------------------------
> > To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
> > For additional commands, e-mail: log4j-user-help@jakarta.apache.org
> >
>
>
>__________________________________
>Do you Yahoo!?
>Yahoo! SiteBuilder - Free, easy-to-use web site design software
>http://sitebuilder.yahoo.com
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: log4j-user-unsubscribe@jakarta.apache.org
>For additional commands, e-mail: log4j-user-help@jakarta.apache.org

-- 
Ceki Gülcü

      For log4j documentation consider "The complete log4j manual"
      ISBN: 2970036908 http://www.qos.ch/shop/products/clm_t.jsp

      import org.apache.Facetime;
      ApacheCon US 2003, 18-21 November http://apachecon.com/



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


Mime
View raw message