activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From chir...@apache.org
Subject svn commit: r1430459 - /activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueEntry.scala
Date Tue, 08 Jan 2013 19:38:16 GMT
Author: chirino
Date: Tue Jan  8 19:38:16 2013
New Revision: 1430459

URL: http://svn.apache.org/viewvc?rev=1430459&view=rev
Log:
Fixes APLO-276: Negative "swapped in" values reported by REST API

Modified:
    activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueEntry.scala

Modified: activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueEntry.scala
URL: http://svn.apache.org/viewvc/activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueEntry.scala?rev=1430459&r1=1430458&r2=1430459&view=diff
==============================================================================
--- activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueEntry.scala
(original)
+++ activemq/activemq-apollo/trunk/apollo-broker/src/main/scala/org/apache/activemq/apollo/broker/QueueEntry.scala
Tue Jan  8 19:38:16 2013
@@ -554,8 +554,10 @@ class QueueEntry(val queue:Queue, val se
     }
 
     override def remove = {
-      queue.loaded_items -= 1
-      queue.loaded_size -= size
+      if( !remove_pending ) {
+        queue.loaded_items -= 1
+        queue.loaded_size -= size
+      }
       if( storing | remove_pending ) {
         remove_pending = true
       } else {



Mime
View raw message