3 Replies Latest reply on Apr 2, 2013 4:44 PM by jamezp

    Logging errorHandler in Jboss as 7.1.1 Final

    piyush.mnnit

      Hi,

       

      We are migrating our application from Jboss 4.2.2 GA to Jboss 7.1.1 Final.

       

      We had defined  "errorHandler" in jboss-log4j.xml.

       

      <appender name="FILE" class="org.jboss.logging.appender.DailyRollingFileAppender">
          <errorHandler class="org.jboss.logging.util.OnlyOnceErrorHandler" />

       

      In Jboss as 7 I can not find errorHandler. I checked schema there is nothing like that.

       

      What is the alternative for this to have in Jboss as 7?

       

       

      Thanjs & Regards,

      Piyush Jain

        • 1. Re: Logging errorHandler in Jboss as 7.1.1 Final
          jamezp

          Currently there is not a way to override the error handler.

           

          --

          James R. Perkins

          • 2. Re: Logging errorHandler in Jboss as 7.1.1 Final
            piyush.mnnit

            Thanks a lot James. But have one more question.

             

            Found below information on internet.

             

            Functioning of OnlyOnceErrorHandler - The OnlyOnceErrorHandler implements log4j's default error handling policy which consists of emitting a message for the first error in an appender and ignoring all following errors. The error message is printed on the specified print stream. This policy aims at protecting an otherwise working application from being flooded with error messages when logging fails.

             

            Does default error handler handles above functionality?

            • 3. Re: Logging errorHandler in Jboss as 7.1.1 Final
              jamezp

              By default it just uses the java.util.logging.ErrorManager. I would most likely accept a JIRA for a feature request to allow an error manager to be defined though.

               

              That said if the log manager fails to initialize the server will likely fail to start.

               

              --

              James R. Perkins