0 Replies Latest reply on Mar 29, 2007 8:44 AM by Maciej Noname

    add custome appenders to log4j.xml

    Maciej Noname Newbie

      Hi, I created my own appender that logging data to another ejb using JNDI. My question is, how can I add my external jar package to log4j.xml, beause when I do this:

      <appender name="xxxx" class="logg.to.MyClass ">
      
       <layout class="org.apache.log4j.PatternLayout">
      
       <param name="ConversionPattern" value="%t %d %x %-5p [%c.%M] %m%n"/>
      
       </layout>
       </appender>
      
       <category name="ptk.cv.scoring">
       <priority value="INFO" />
       <appender-ref ref="xxxx"/>
       </category>
      


      I get the error:

      ?Could not create an Appender. Reported error follows.

      java.lang.ClassNotFoundException: logg.to.MyClass?

      I added jar with my appender class in: jboss/server/default/lib



      I put this appender in to log4j.xml because I have to be able change logg level dynamicly through jmx-console.

      I?m using jboss-4.0.5.GA and sdk_1.4.2_13.

      Thanks for any help.

      Lidon.