2 Replies Latest reply on Dec 16, 2009 6:05 AM by Mark Anderson

    Logging

    Mark Anderson Newbie

      I am currently evaluating HornetQ and one of my evaluation criteria is how useful/readable the logs produced by the JMS server are. I setup the log4j delegate and set the logging level to TRACE for org.hornetq in my log4j.properties but notice that apart from on startup no logging is produced.

       

      If there some configuration that I am missing or does HornetQ not produce any logging while messages are being sent/received? If no logging is produced I am concerned about how I could debug any issues that may arise in a production environment. Is there a reason behind the lack of logging as other JMS providers will log every message sent at the TRACE level.

        • 1. Re: Logging
          Jeff Mesnil Master

          HornetQ provides metrics on the queue to see if messages are sent/received but does not log them.

          Logging each message sent and receive at a TRACE level would generate a huge number of logs which may not  be suitable for production environment. It'd also impact performance as each message sent/received will be slowed down by writing to the log file.

          But your point is valid for dev and staging environments.

           

          This is something that can be considered for 2.1, do not hesitate to add a JIRA issue.

          • 2. Re: Logging
            Mark Anderson Newbie

            After I posted this thread I noticed that there was a JIRA issue filed for adding TRACE logging.

             

            I take you point about TRACE logging being too much for a production environment (I have experienced this!!) however some kind of debug logging could still be useful in a production environment to see what is going on. I was quite surprised when I plugged HornetQ into my application, turned on logging and seen that there was no output whatsoever after startup.

             

            When you talk about metrics I take it you mean those that are available via JMX? I have looked at what is exposed via JMX and it is useful but doesn't help if, say, the application goes out of memory and then crashes. In this case you only have the log files to help debug the problem.

             

            I guess if I decided to take my usage of HornetQ further I could consider what logging I may find useful and file appropriate JIRA issues/supply patches.