logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "yacout dadoun" <yacout_dad...@hotmail.com>
Subject RE: How to add new level
Date Wed, 28 Jul 2004 13:02:16 GMT
Oh yes thanks
But iffor instance,  i put trace between warn and error(trace_int=3500 
syslog_alert=4), i will still receive a message if an error/fatal 
happensright? however i'd like to receive a message only and only if the 
trace is called
Thanks


>From: "Paul Smith" <psmith@aconex.com>
>Reply-To: "Log4J Users List" <log4j-user@logging.apache.org>
>To: "'Log4J Users List'" <log4j-user@logging.apache.org>
>Subject: RE: How to add new level
>Date: Wed, 28 Jul 2004 08:57:02 +1000
>
>In the XML file, whereever you could use the strings DEBUG/INFO/WARN/ERROR,
>just replace it with the string "trace#my.package.TraceLevel".
>
> > -----Original Message-----
> > From: yacout dadoun [mailto:yacout_dadoun@hotmail.com]
> > Sent: Wednesday, July 28, 2004 8:40 AM
> > To: log4j-user@logging.apache.org
> > Subject: RE: How to add new level
> >
> > Thanks for ur help
> > >To reference your custom level in the configuration file, you use the
> > >syntax
> > >that is at the very bottom of the example I sent:
> > >trace#my.package.TraceLevel
> > >
> > >e.g:
> > >log4j.rootLogger=trace#my.package.TraceLevel, MAIN, STDERR
> >
> > But how to add it to the xml log4j file not properties file ?
> >
> >
> > >From: "Paul Smith" <psmith@aconex.com>
> > >Reply-To: "Log4J Users List" <log4j-user@logging.apache.org>
> > >To: "'Log4J Users List'" <log4j-user@logging.apache.org>
> > >Subject: RE: How to add new level
> > >Date: Wed, 28 Jul 2004 08:36:57 +1000
> > >
> > >You won't be able to call logger.levelName because unless you come up
> > with
> > >your own LoggerFactory implementation, which is not recommended but
> > >possible.
> > >
> > >The usual way of using your custom level is to use the Logger.log(Level
> > >level, Object message) method.
> > >The numbers used are for comparing Levels with each other, so your 
>custom
> > >Level should have a number that places it, say, below DEBUG, or between
> > >INFO
> > >& WARN.  It's really up to you and what your Level is all about.
> > >
> > >To reference your custom level in the configuration file, you use the
> > >syntax
> > >that is at the very bottom of the example I sent:
> > >trace#my.package.TraceLevel
> > >
> > >e.g:
> > >log4j.rootLogger=trace#my.package.TraceLevel, MAIN, STDERR
> > >
> > >
> > > > -----Original Message-----
> > > > From: yacout dadoun [mailto:yacout_dadoun@hotmail.com]
> > > > Sent: Wednesday, July 28, 2004 8:28 AM
> > > > To: log4j-user@logging.apache.org
> > > > Subject: RE: How to add new level
> > > >
> > > >
> > > > Thanks, i 've already found this link but i dont know what values to
> > >give
> > > > to
> > > > TRACE_INT and SYSLOG_TRACE_INT they used 800 an d7 but in my case, i
> > >need
> > > > this level, to be able to call logger.levelName("------"); and in 
>the
> > > > log4j
> > > > xml file send email to certain group each time levelName is called.
> > > >
> > > >
> > > > >From: "Paul Smith" <psmith@aconex.com>
> > > > >Reply-To: "Log4J Users List" <log4j-user@logging.apache.org>
> > > > >To: "'Log4J Users List'" <log4j-user@logging.apache.org>
> > > > >Subject: RE: How to add new level
> > > > >Date: Wed, 28 Jul 2004 08:12:43 +1000
> > > > >
> > > > >http://wiki.apache.org/logging-log4j/TraceLevel
> > > > >
> > > > > > -----Original Message-----
> > > > > > From: yacout dadoun [mailto:yacout_dadoun@hotmail.com]
> > > > > > Sent: Wednesday, July 28, 2004 8:03 AM
> > > > > > To: log4j-user@jakarta.apache.org
> > > > > > Cc: log4j-dev@jakarta.apache.org
> > > > > > Subject: How to add new level
> > > > > >
> > > > > > Hi,
> > > > > > How can i add new level to log4j?
> > > > > > Thanks
> > > > > >
> > > > > > 
>_________________________________________________________________
> > > > > > Share a single photo or an entire photo slide show right inside
> > MSNR
> > > > > > Messenger.
> > > > > > http://join.msn.com/?pgmarket=en-
> > > > > >
> > > >
> > >
> > 
> >ca&page=byoa/prem&xAPID=1994&DI=1034&SU=http://hotmail.com/enca&HL=Market
> > > > _
> > > > > > MSNIS_Taglines
> > > > > >   Start enjoying all the benefits of MSNR Premium right now
and
> > get
> > > > the
> > > > > > first two months FREE*.
> > > > > >
> > > > > >
> > > > > >
> > >---------------------------------------------------------------------
> > > > > > 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
> > > > >
> > > >
> > > > _________________________________________________________________
> > > > Take advantage of powerful junk e-mail filters built on patented
> > > > MicrosoftR
> > > > SmartScreen Technology.
> > > > http://join.msn.com/?pgmarket=en-
> > > >
> > 
> >ca&page=byoa/prem&xAPID=1994&DI=1034&SU=http://hotmail.com/enca&HL=Market
> > _
> > > > MSNIS_Taglines
> > > >   Start enjoying all the benefits of MSNR Premium right now and get
> > the
> > > > first two months FREE*.
> > > >
> > > >
> > > > 
>---------------------------------------------------------------------
> > > > 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
> > >
> >
> > _________________________________________________________________
> > Scan and help eliminate destructive viruses from your inbound and 
>outbound
> > e-mail and attachments.
> > http://join.msn.com/?pgmarket=en-
> > 
>ca&page=byoa/prem&xAPID=1994&DI=1034&SU=http://hotmail.com/enca&HL=Market_
> > MSNIS_Taglines
> >   Start enjoying all the benefits of MSNR Premium right now and get the
> > first two months FREE*.
> >
> >
> > ---------------------------------------------------------------------
> > 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
>

_________________________________________________________________
Take advantage of powerful junk e-mail filters built on patented Microsoft® 
SmartScreen Technology. 
http://join.msn.com/?pgmarket=en-ca&page=byoa/prem&xAPID=1994&DI=1034&SU=http://hotmail.com/enca&HL=Market_MSNIS_Taglines

  Start enjoying all the benefits of MSN® Premium right now and get the 
first two months FREE*.


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