2 Replies Latest reply on Feb 13, 2004 4:05 PM by khohl

    how to replace default logger in 3.2.3?

      I'm a new user trying to figure out if it's possible to intercept all logging and tracing events generated by both my EJBs in JBoss, and by JBoss itself and then forward them on to both Log4j and a different logger used by our product.

      I've read about the Logging Framework in Chapter 10 of the 3.2.x Administration and Development documentation.

      It seems this should be possible by implementing LoggerPlugin and calling both Log4jLoggerPlugin and my logger from the methods.

      My 1st step was going to be to try to replace the standard Lo4j logger with the NullLoggerPlugin as this section of the documentation describes. However, I can't figure out how to follow the following direction from page 557 of the documentation -

      "To integrate an alternate logging implementation, you would provide an implementation of the LoggerPlugin interface and specify that it should be used by setting the org.jboss.logging.Logger.pluginClass system property to implementation class name."

      Is what I need to do feasible?

      How do you replace the default logger?

      Thanks.

      Ken Hohl
      Apropos Technology
      ken.hohl@apropos.com

        • 1. Re: how to replace default logger in 3.2.3?
          starksm64

          So did you:
          "To integrate an alternate logging implementation, you would provide an implementation of the LoggerPlugin interface and specify that it should be used by setting the org.jboss.logging.Logger.pluginClass system property to implementation class name."
          ?

          export JAVA_OPTS=-Dorg.jboss.logging.Logger.pluginClas=org.jboss.logging.NullLoggerPlugin
          run.sh

          • 2. Re: how to replace default logger in 3.2.3?

            Do I didn't because I misinterpretted the meaning of "system property" the documentation refers to. After following your directions, I was able to replace the default logger with the null logger and assume it will be straightforward to create my custom logger.
            _________________
            Thanks for the help.

            Ken Hohl
            Apropos Technology
            ken.hohl@apropos.com