With additivity set to false there should be no logs for
org.apache.commons.httpclient that make it to the appender.  I suspect
that something else is changing your config (maybe some code in a
library).

On 5/23/07, ben short <[EMAIL PROTECTED]> wrote:
I just changed the logger configs to the following, but I still see
the httpclient log messages.

<logger name="org.springframework" additivity="false"><level
value="WARN"/></logger>

 <logger name="org.apache.commons.httpclient"
additivity="false"><level value="WARN"/></logger>

On 5/23/07, ben short <[EMAIL PROTECTED]> wrote:
> Im using spring with the following config in the web.xml.
>
> <context-param>
>         <param-name>log4jConfigLocation</param-name>
>         <param-value>/WEB-INF/log4j.xml</param-value>
>     </context-param>
>
>     <listener>
>                 
<listener-class>org.springframework.web.util.Log4jConfigListener</listener-class>
>         </listener>
>
> But I just tried commenting out that lot and putting the log4j.xml in
> the class path. Same result.
>
> On 5/23/07, James Stauffer <[EMAIL PROTECTED]> wrote:
> > The level setting should allow only WARN and higher logs to get to the
> > root logger even with additivity set to true.
> >
> > On 5/23/07, Gallagher, Ron <[EMAIL PROTECTED]> wrote:
> > > Ben --
> > >
> > > Here's your problem:
> > >
> > > log4j: Setting [org.apache.commons.httpclient] additivity to [true].
> > >
> > > With the additivity of the org.apache.commons.httpclient logger set to
> > > true, any logging output that is processed by the
> > > org.apache.commons.httpclient will also be processed by any explicitly
> > > configured loggers in it's ancestry, including the 'root' logger.
> > >
> > > To change this behavior, just set the additivity on the
> > > org.apache.commons.httpclient to false.
> > >
> > > <logger name="org.apache.commons.httpclient" additivity="false"><level
> > > value="WARN"/></logger>
> > >
> > > Ron Gallagher, AT&T Mobility
> > >
> > > -----Original Message-----
> > > From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of
> > > ben short
> > > Sent: Wednesday, May 23, 2007 10:54 AM
> > > To: Log4J Users List
> > > Subject: Re: Logger level being ignored
> > >
> > > Heres my output with -Dlog4j.debug. Seems to show the correct setup of
> > > the logger.
> > >
> > > log4j: Trying to find [log4j.properties] using
> > > ClassLoader.getSystemResource().
> > > log4j: Could not find resource: [null].
> > > log4j:WARN No appenders could be found for logger
> > > (org.apache.commons.digester.Digester.sax).
> > > log4j:WARN Please initialize the log4j system properly.
> > > log4j: System property is :null
> > > log4j: Standard DocumentBuilderFactory search succeded.
> > > log4j: DocumentBuilderFactory is:
> > > org.apache.xerces.jaxp.DocumentBuilderFactoryImpl
> > > log4j: debug attribute= "null".
> > > log4j: Ignoring debug attribute.
> > > log4j: Threshold ="null".
> > > log4j: Retreiving an instance of org.apache.log4j.Logger.
> > > log4j: Setting [org.springframework] additivity to [true].
> > > log4j: Level value for org.springframework is  [WARN].
> > > log4j: org.springframework level set to WARN
> > > log4j: Retreiving an instance of org.apache.log4j.Logger.
> > > log4j: Setting [org.apache.commons.httpclient] additivity to [true].
> > > log4j: Level value for org.apache.commons.httpclient is  [WARN].
> > > log4j: org.apache.commons.httpclient level set to WARN
> > > log4j: Level value for root is  [all].
> > > log4j: root level set to ALL
> > > log4j: Class name: [org.apache.log4j.RollingFileAppender]
> > > log4j: Setting property [maxFileSize] to [128MB].
> > > log4j: Setting property [maxBackupIndex] to [5].
> > > log4j: Setting property [file] to
> > > [/opt/apache-tomcat-5.5.23/logs/jc_core.log].
> > > log4j: Setting property [threshold] to [DEBUG].
> > > log4j: Parsing layout of class: "org.apache.log4j.PatternLayout"
> > > log4j: Setting property [conversionPattern] to [%d{ABSOLUTE} %5p %C:%L -
> > > %m%n].
> > > log4j: setFile called: /opt/apache-tomcat-5.5.23/logs/jc_core.log, true
> > > log4j: setFile ended
> > > log4j: Adding appender named [FILE] to category [root].
> > >
> > > ---------------------------------------------------------------------
> > > 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]
> > >
> > >
> >
> >
> > --
> > James Stauffer        http://www.geocities.com/stauffer_james/
> > Are you good? Take the test at http://www.livingwaters.com/good/
> >
> > ---------------------------------------------------------------------
> > 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]




--
James Stauffer        http://www.geocities.com/stauffer_james/
Are you good? Take the test at http://www.livingwaters.com/good/

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

Reply via email to