qpid-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rob...@apache.org
Subject svn commit: r941359 - /qpid/branches/0.5.x-dev/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/QueueEntryImpl.java
Date Wed, 05 May 2010 16:01:12 GMT
Author: robbie
Date: Wed May  5 16:01:12 2010
New Revision: 941359

URL: http://svn.apache.org/viewvc?rev=941359&view=rev
Log:
QPID-2568: null the message ref when the QueueEntry enters the deleted state

Modified:
    qpid/branches/0.5.x-dev/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/QueueEntryImpl.java

Modified: qpid/branches/0.5.x-dev/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/QueueEntryImpl.java
URL: http://svn.apache.org/viewvc/qpid/branches/0.5.x-dev/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/QueueEntryImpl.java?rev=941359&r1=941358&r2=941359&view=diff
==============================================================================
--- qpid/branches/0.5.x-dev/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/QueueEntryImpl.java
(original)
+++ qpid/branches/0.5.x-dev/qpid/java/broker/src/main/java/org/apache/qpid/server/queue/QueueEntryImpl.java
Wed May  5 16:01:12 2010
@@ -42,7 +42,7 @@ public class QueueEntryImpl implements Q
 
     private final SimpleQueueEntryList _queueEntryList;
 
-    private final AMQMessage _message;
+    private AMQMessage _message;
 
     private Set<Subscription> _rejectedBy = null;
 
@@ -387,6 +387,10 @@ public class QueueEntryImpl implements Q
         if(state != DELETED_STATE && _stateUpdater.compareAndSet(this,state,DELETED_STATE))
         {
             _queueEntryList.advanceHead();            
+            
+            //Ensure we can't hang on to the message;
+            _message = null;
+            
             return true;
         }
         else



---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org


Mime
View raw message