I tried it, but still getting the same error.


Jim Reilly-2 wrote:
> 
> 
> 
> Try the xml below.
> A few problems.  The renderer tag needs to be empty (per DTD), so need to
> close the tag in same tag  (not use a </renderer>).
> 
> Also I think order matters, so need to keep in this order: 
> renderer*, appender*,(category|logger)*,root?, categoryFactory?
> 
> -Jim
> 
> 
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
> 
> 
> 
> 
>     <!-- I created a renderer for the servlet request object so that it
> -->
>     <!-- is easy to log info about it.  It's also reusable this way in all
>         servlets. -->
>     <renderer renderedClass="javax.servlet.http.HttpServletRequest"
>        
> renderingClass="com.firstpac.etools.log.HttpServletRequestRenderer"/>
> 
>     <!-- All output goes to eTools logfile ($TOMCAT_HOME/logs directory)
> -->
>     <appender name="log"
> class="org.apache.log4j.DailyRollingFileAppender">
>         <layout class="org.apache.log4j.PatternLayout">
>         </layout>
>     </appender>
> 
>     <!-- All output goes to DB for client statistics -->
>     <appender name="clientStats"
> class="org.apache.log4j.jdbc.JDBCAppender">
>     </appender>
> 
> 
>     <!-- This is our logger for the fpcServlets application. It logs all
> -->
>     <!-- info to files (error/debug...) -->
>     <logger name="com.firstpac.etools.log4j.log">
>         <level value="debug" />
>         <appender-ref ref="log" />
>     </logger>
> 
>     <!-- This is our logger for the fpcServlets application. It logs all
> -->
>     <!-- statistics info for the user -->
>     <logger name="com.firstpac.etools.log4j.clientStats">
>         <level value="info" />
>         <appender-ref ref="clientStats" />
>     </logger>
> 
> </log4j:configuration>
> 
> 
> 
> 
> ----- Original Message ----
> From: osubb <[EMAIL PROTECTED]>
> To: log4j-user@logging.apache.org
> Sent: Tuesday, February 19, 2008 2:23:12 PM
> Subject: Parsing problem
> 
> 
> 
> I 
> seem 
> to 
> get 
> warning 
> whenever 
> log4j 
> configure 
> file 
> is 
> loaded.  
> I 
> looked 
> at
> my 
> config 
> file 
> and 
> can 
> see 
> no 
> syntax 
> problems.  
> Can 
> somebody 
> point 
> me 
> in 
> the
> right 
> direction???
> 
> 
> ****WARNINGS*****
> log4j:WARN 
> Continuable 
> parsing 
> error 
> 50 
> and 
> column 
> 13
> log4j:WARN 
> The 
> content 
> of 
> element 
> type 
> "renderer" 
> must 
> match 
> "EMPTY".
> log4j:WARN 
> Continuable 
> parsing 
> error 
> 53 
> and 
> column 
> 23
> 
> **** 
> CONFIG 
> FILE 
> ****
> 
> <?xml 
> version="1.0" 
> encoding="UTF-8"?>
> <!DOCTYPE 
> log4j:configuration 
> SYSTEM 
> "log4j.dtd">
> 
> <log4j:configuration 
> xmlns:log4j="http://jakarta.apache.org/log4j/";>
> 
>     
> <!-- 
> This 
> is 
> our 
> logger 
> for 
> the 
> fpcServlets 
> application. 
> It 
> logs 
> all 
> -->
>     
> <!-- 
> info 
> to 
> files 
> (error/debug...) 
> -->
>     
> <logger 
> name="com.firstpac.etools.log4j.log">
>     
>     
> <level 
> value="debug"/>
>     
>     
> <appender-ref 
> ref="log"/>
>     
> </logger>
>     
>     
> <!-- 
> This 
> is 
> our 
> logger 
> for 
> the 
> fpcServlets 
> application. 
> It 
> logs 
> all 
> -->
>     
> <!-- 
> statistics 
> info 
> for 
> the 
> user 
> -->
>     
> <logger 
> name="com.firstpac.etools.log4j.clientStats">
>     
>     
> <level 
> value="info"/>
>     
>     
> <appender-ref 
> ref="clientStats"/>
>     
> </logger>
> 
>     
> <!-- 
> All 
> output 
> goes 
> to 
> eTools 
> logfile 
> ($TOMCAT_HOME/logs 
> directory) 
> -->
>     
> <appender 
> name="log" 
> class="org.apache.log4j.DailyRollingFileAppender">
>     
>     
>     
> 
>     
>     
>     
>     
>     
>     
>     
>     
>     
>     
> <layout 
> class="org.apache.log4j.PatternLayout">
>     
>     
>     
>     
>     
> </layout>
>     
> </appender>
> 
>     
> <!-- 
> All 
> output 
> goes 
> to 
> DB 
> for 
> client 
> statistics 
> -->
> 
>     
> <appender 
> name="clientStats" 
> class="org.apache.log4j.jdbc.JDBCAppender" 
>>
>     
>     
>     
>     
>     
> </appender>
> 
>     
>     
> <!-- 
> I 
> created 
> a 
> renderer 
> for 
> the 
> servlet 
> request 
> object 
> so 
> that 
> it 
> -->
>     
> <!-- 
> is 
> easy 
> to 
> log 
> info 
> about 
> it.  
> It's 
> also 
> reusable 
> this 
> way 
> in 
> all
> servlets. 
> -->
>     
> <renderer 
> renderedClass="javax.servlet.http.HttpServletRequest"
>     
>     
> renderingClass="com.firstpac.etools.log.HttpServletRequestRenderer" 
>>
>     
> </renderer>
> 
>     
> </log4j:configuration>
> 
> -- 
> View 
> this 
> message 
> in 
> context: 
> http://www.nabble.com/Parsing-problem-tp15562410p15562410.html
> Sent 
> from 
> the 
> Log4j 
> - 
> Users 
> mailing 
> list 
> archive 
> at 
> Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To 
> unsubscribe, 
> e-mail: 
> [EMAIL PROTECTED]
> For 
> additional 
> commands, 
> e-mail: 
> [EMAIL PROTECTED]
> 
> 
> 
> 
> 
> 
> 
>      
> ____________________________________________________________________________________
> Never miss a thing.  Make Yahoo your home page. 
> http://www.yahoo.com/r/hs
> 

-- 
View this message in context: 
http://www.nabble.com/Parsing-problem-tp15562410p15598158.html
Sent from the Log4j - Users mailing list archive at Nabble.com.


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

Reply via email to