0 Replies Latest reply on Apr 3, 2011 11:34 AM by piotrekde

    Weird log entries when using JBoss AsyncUtils

    piotrekde

      Hello,

       

      In my JBoss-based application I have a class which uses JBoss AsyncUtils to asynchronously delegate processing to the one of pooled stateless beans. It is done in this way:

       

       

      import org.apache.commons.logging.Log;
      import org.apache.commons.logging.LogFactory;
      import org.jboss.ejb3.common.proxy.plugins.async.AsyncUtils;
      (...)
      
      public class MyClass {
      
        private static final Log LOG = LogFactory.getLog(MyClass.class);
      
        @EJB
        private MyProcessor myProcessor; // contains process(DatagramPacket) method
        // (...)  
      
        public void someMethod() {    
          DatagramPacket datagram = socket.receive();
          LOG.debug("Received");
          AsyncUtils.mixinAsync(myProcessor).process(datagram);
          LOG.debug("mixinAsync delegated");
        }
      }
      

       

      When I take a look at the JBoss console logs I can see:

       

       

      17:06:32,544 DEBUG [MyClass] Received

      17:06:32,544 INFO     [STDOUT] *
      17:06:32,544 DEBUG [MyClass] mixinAsync delegated!

      17:06:32,545 DEBUG [MyProcessor] started processing

       

      All logs excepth this one: "[STDOUT] *" comes from my application. "[MyProcessor] started processing" is logged at the very beginning of MyProcessor.process(DatagramPacket) method. So I assume that "[STDOUT] *" comes from AsyncUtils.

      I'd like to exclude this line from my logs, because it makes them very unclear (this line appear every time new packet appears), and also it slows down my application - datagram packets comes all the time and it is crucial to process them as fast as it is possible.

       

      I downloaded sources of AsyncUtils and done some research but I've found nothing logging "*". The only "suspicious" class is org.jboss.ejb3.common.thread.RedirectProcessOutputToSystemOutThread but when I search for usages nothing is found (maybe it's my IDE issue).

       

      The important clue is that "[STDOUT] *" is logged only into console (not into the file log).

      I use the newest version of jboss ejb3: jboss-ejb3-common-1.0.3.jar

       

      Any hints appreciated

      Thanks in advance,

       

      Piotr