logging-log4j-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Amandeep Midha" <Amandeep.Mi...@itsprojects.com>
Subject RE: PLease
Date Sat, 25 Jan 2003 11:56:13 GMT


Hi,

It worked only after I unzipped classes12_g.zip in WEB-INF/classes folder

though it sounds funny... but it worked only that way. Any fix for it ?

regards,
Amandeep



                                                                                         
                          
                    "Rich Bagley"                                                        
                          
                    <rbagley@hbs.e       To:     "Log4J Users List" <log4j-user@jakarta.apache.org>
                
                    du>                  cc:                                          
                             
                                         Subject:     RE: PLease                         
                          
                    01/25/2003                                                           
                          
                    04:18 AM                                                             
                          
                    Please respond                                                       
                          
                    to "Log4J                                                            
                          
                    Users List"                                                          
                          
                                                                                         
                          
                                                                                         
                          




Hi,

  I have classes12.zip in my classpath.  If you're using a container like
tomcat, try putting it in WEB-INF/lib.

-Rich

>> -----Original Message-----
>> From: Amandeep Midha [mailto:Amandeep.Midha@itsprojects.com]
>> Sent: Friday, January 24, 2003 3:45 PM
>> To: Log4J Users List
>> Subject: PLease
>>
>>
>>
>>
>>
>> hi,
>>
>> thanks for your code. I tried the code, but i am getting following
>> exception
>>
>> what should i do. I have classes12/classes12_g in classpath.
>>
>> regards,
>> Amandeep
>>
>>
>> log4j:ERROR Failed to load driver
>> java.lang.ClassNotFoundException: oracle.jdbc.driver.OracleDriver
>>         at
>> org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClas
>> sLoader.java:1307)
>>         at
>> org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClas
>> sLoader.java:1156)
>>         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
>>         at java.lang.Class.forName0(Native Method)
>>         at java.lang.Class.forName(Class.java:140)
>>         at
>> org.apache.log4j.jdbc.JDBCAppender.setDriver(JDBCAppender.java:332)
>>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>         at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorI
>> mpl.java:39)
>>         at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodA
>> ccessorImpl.java:25)
>>         at java.lang.reflect.Method.invoke(Method.java:324)
>>         at
>> org.apache.log4j.config.PropertySetter.setProperty(PropertySetter
>> .java:196)
>>         at
>> org.apache.log4j.config.PropertySetter.setProperty(PropertySetter
>> .java:155)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.setParameter(DOMConfigurator
>> .java:530)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurato
>> r.java:182)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfig
>> urator.java:140)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMC
>> onfigurator.java:153)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurato
>> r.java:201)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfig
>> urator.java:140)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMC
>> onfigurator.java:153)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.parseChildrenOfLoggerElement
>> (DOMConfigurator.java:415)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.parseRoot(DOMConfigurator.java:384)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.parse(DOMConfigurator.java:790)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.
>> java:673)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.
>> java:616)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.
>> java:584)
>>         at
>> org.apache.log4j.xml.DOMConfigurator.configure(DOMConfigurator.java:694)
>>
>>
>>
>>
>>
>>
>>
>>                     "Rich Bagley"
>>
>>                     <rbagley@hbs.e       To:     "Log4J Users
>> List" <log4j-user@jakarta.apache.org>
>>                     du>                  cc:
>>
>>                                          Subject:     RE: Please
>>
>>                     01/25/2003
>>
>>                     01:45 AM
>>
>>                     Please respond
>>
>>                     to "Log4J
>>
>>                     Users List"
>>
>>
>>
>>
>>
>>
>>
>>
>>
>> This works in log4j.1.2.7
>>
>> <?xml version="1.0" encoding="UTF-8" ?>
>> <!DOCTYPE log4j:configuration SYSTEM "log4j.dtd">
>>
>> <log4j:configuration xmlns:log4j="http://jakarta.apache.org/log4j/">
>>
>>     <appender name="jdbcAppender"
>> class="org.apache.log4j.jdbc.JDBCAppender">
>>         <param name="URL"
>> value="jdbc:oracle:thin:@sd1.hbs.edu:1521:sc1" />
>>         <param name="Driver" value="oracle.jdbc.driver.OracleDriver" />
>>         <param name="User" value="user" />
>>         <param name="Password" value="password" />
>>         <layout class="org.apache.log4j.PatternLayout">
>>             <param name="ConversionPattern"
>>                 value="INSERT INTO LOGGING_SAMPLES_TEST (log_date,
>> log_level, location, message) VALUES ( '%d{ISO8601}','%p',
>> '%C;%L', '%m' )"
>> />
>>         </layout>
>>     </appender>
>>
>>     <appender name="STDOUT" class="org.apache.log4j.ConsoleAppender">
>>         <layout class="org.apache.log4j.PatternLayout">
>>             <param name="ConversionPattern"
>>                 value="%d{ISO8601} %p (%C;%L) %m%n"/>
>>         </layout>
>>     </appender>
>>
>>     <logger name="logging.simple.jdbcLogger">
>>         <level value="debug"/>
>>         <appender-ref ref="jdbcAppender"/>
>>     </logger>
>>
>>     <root>
>>         <priority value="error"/>
>>         <appender-ref ref="STDOUT"/>
>>     </root>
>>
>> </log4j:configuration>
>>
>> >> -----Original Message-----
>> >> From: Amandeep Midha [mailto:Amandeep.Midha@itsprojects.com]
>> >> Sent: Friday, January 24, 2003 3:04 PM
>> >> To: log4j-user@jakarta.apache.org
>> >> Subject: Please
>> >>
>> >>
>> >>
>> >> Can you send me sample xml to configure JDBC appender?
>> >>
>> >> thanks in advance
>> >>
>> >> regards,
>> >> Amandeep
>> >>
>> >>
>> >> --
>> >> To unsubscribe, e-mail:
>> >> <mailto:log4j-user-unsubscribe@jakarta.apache.org>
>> >> For additional commands, e-mail:
>> >> <mailto:log4j-user-help@jakarta.apache.org>
>> >>
>>
>>
>> --
>> To unsubscribe, e-mail:
<mailto:log4j-user-unsubscribe@jakarta.apache.org
>
For additional commands, e-mail: <mailto:log4j-user-help@jakarta.apache.org
>






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


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






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


Mime
View raw message