[jboss-cvs] JBoss Messaging SVN: r2344 - trunk/src/main/org/jboss/jms/client/container.

jboss-cvs-commits at lists.jboss.org jboss-cvs-commits at lists.jboss.org
Sat Feb 17 03:29:02 EST 2007


Author: ovidiu.feodorov at jboss.com
Date: 2007-02-17 03:29:02 -0500 (Sat, 17 Feb 2007)
New Revision: 2344

Modified:
   trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
Log:
minor comment changes

Modified: trunk/src/main/org/jboss/jms/client/container/SessionAspect.java
===================================================================
--- trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2007-02-17 08:24:53 UTC (rev 2343)
+++ trunk/src/main/org/jboss/jms/client/container/SessionAspect.java	2007-02-17 08:29:02 UTC (rev 2344)
@@ -234,9 +234,9 @@
    
             if (trace) { log.trace("sending acknowlegment transactionally, queueing on resource manager"); }
    
-            //If the ack is for a delivery that came through via a connection consumer then we
-            //use the connectionConsumer session as the session id, otherwise we use this sessions'
-            //session id
+            // If the ack is for a delivery that came through via a connection consumer then we use
+            // the connectionConsumer session as the session id, otherwise we use this sessions'
+            // session ID
             
             ClientSessionDelegate connectionConsumerDelegate =
                (ClientSessionDelegate)info.getConnectionConsumerSession();
@@ -261,15 +261,13 @@
       if (ackMode == Session.AUTO_ACKNOWLEDGE ||
           ackMode == Session.DUPS_OK_ACKNOWLEDGE)
       {
-         //We auto acknowledge
-         //Currently DUPS_OK is treated the same as AUTO_ACKNOWLDGE
+         // We auto acknowledge. Currently DUPS_OK is treated the same as AUTO_ACKNOWLDGE.
 
          SessionDelegate sd = (SessionDelegate)mi.getTargetObject();
 
-         //It is possible that session.recover() is called inside a message listener onMessage
-         //method - i.e. between the invocations of preDeliver and postDeliver.
-         //In this case we don't want to acknowledge the last delivered messages - since it
-         //will be redelivered
+         // It is possible that session.recover() is called inside a message listener onMessage
+         // method - i.e. between the invocations of preDeliver and postDeliver. In this case we
+         // don't want to acknowledge the last delivered messages - since it will be redelivered.
          if (!state.isRecoverCalled())
          {
             DeliveryInfo delivery = state.getAutoAckInfo();
@@ -281,10 +279,9 @@
                                  
             if (trace) { log.trace(this + " auto acknowledging delivery " + delivery); }
               
-            //We clear the state before so if the ackfails then
-            //we don't get a knock on exception on the next ack since we haven't
-            //cleared the state:
-            //http://jira.jboss.org/jira/browse/JBMESSAGING-852
+            // We clear the state before so if the acknowledgment fails then we don't get a knock on
+            // exception on the next ack since we haven't cleared the state. See
+            // http://jira.jboss.org/jira/browse/JBMESSAGING-852
             
             state.setAutoAckInfo(null);
             
@@ -301,7 +298,9 @@
       return null;
    }
    
-   /* Used for client acknowledge */
+   /**
+    * Used for client acknowledge.
+    */
    public Object handleAcknowledgeAll(Invocation invocation) throws Throwable
    {    
       MethodInvocation mi = (MethodInvocation)invocation;




More information about the jboss-cvs-commits mailing list