activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rajdav...@apache.org
Subject svn commit: r896063 - in /activemq/branches/activemq-5.3: ./ activemq-core/src/main/java/org/apache/activemq/broker/region/ activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/ activemq-core/src/main/java/org/apache/activemq/transport...
Date Tue, 05 Jan 2010 14:22:34 GMT
Author: rajdavies
Date: Tue Jan  5 14:22:33 2010
New Revision: 896063

URL: http://svn.apache.org/viewvc?rev=896063&view=rev
Log:
 Merged /activemq/trunk:r881278-881313 - for http://issues.apache.org/activemq/browse/AMQ-2475

Added:
    activemq/branches/activemq-5.3/activemq-core/src/test/java/org/apache/activemq/bugs/TempStorageBlockedBrokerTest.java
      - copied unchanged from r881313, activemq/trunk/activemq-core/src/test/java/org/apache/activemq/bugs/TempStorageBlockedBrokerTest.java
    activemq/branches/activemq-5.3/activemq-core/src/test/java/org/apache/activemq/store/temp/
      - copied from r881313, activemq/trunk/activemq-core/src/test/java/org/apache/activemq/store/temp/
    activemq/branches/activemq-5.3/activemq-core/src/test/java/org/apache/activemq/store/temp/TempStoreTest.java
      - copied unchanged from r881313, activemq/trunk/activemq-core/src/test/java/org/apache/activemq/store/temp/TempStoreTest.java
Modified:
    activemq/branches/activemq-5.3/   (props changed)
    activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/TopicSubscription.java
    activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/FilePendingMessageCursor.java
    activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/transport/stomp/StompSubscription.java
  (props changed)

Propchange: activemq/branches/activemq-5.3/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Jan  5 14:22:33 2010
@@ -1 +1 @@
-/activemq/trunk:816278-816279,816298,818138,818140-818147,818155,818160-818176,818209,818211,818224-818262,818480,818484,818487,818496,818502,818504-818510,818513-818516,818609,818635,818724-818762,818888,818905,818914,818923,818947-818955,818985,820031,820713-820714,820764,821090,821103,821115,824807,825009-825084
+/activemq/trunk:816278-816279,816298,818138,818140-818147,818155,818160-818176,818209,818211,818224-818262,818480,818484,818487,818496,818502,818504-818510,818513-818516,818609,818635,818724-818762,818888,818905,818914,818923,818947-818955,818985,820031,820713-820714,820764,821090,821103,821115,824807,825009-825084,881278-881313

Modified: activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/TopicSubscription.java
URL: http://svn.apache.org/viewvc/activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/TopicSubscription.java?rev=896063&r1=896062&r2=896063&view=diff
==============================================================================
--- activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/TopicSubscription.java
(original)
+++ activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/TopicSubscription.java
Tue Jan  5 14:22:33 2010
@@ -96,8 +96,14 @@
                 }
             }
             if (maximumPendingMessages != 0) {
+            	synchronized(matchedListMutex){
+            		while (matched.isFull()){
+            			matchedListMutex.wait(20);
+            		}
+            		matched.addMessageLast(node);
+            	}
                 synchronized (matchedListMutex) {
-                    matched.addMessageLast(node);
+                    
                     // NOTE - be careful about the slaveBroker!
                     if (maximumPendingMessages > 0) {
                         // calculate the high water mark from which point we
@@ -115,7 +121,7 @@
                             // only page in a 1000 at a time - else we could
                             // blow da memory
                             pageInSize = Math.max(1000, pageInSize);
-                            LinkedList list = null;
+                            LinkedList<MessageReference> list = null;
                             MessageReference[] oldMessages=null;
                             synchronized(matched){
                             list = matched.pageInList(pageInSize);

Modified: activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/FilePendingMessageCursor.java
URL: http://svn.apache.org/viewvc/activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/FilePendingMessageCursor.java?rev=896063&r1=896062&r2=896063&view=diff
==============================================================================
--- activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/FilePendingMessageCursor.java
(original)
+++ activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/broker/region/cursors/FilePendingMessageCursor.java
Tue Jan  5 14:22:33 2010
@@ -139,7 +139,7 @@
         destroyDiskList();
     }
 
-    private void destroyDiskList() {
+    private void destroyDiskList() throws Exception {
         if (!isDiskListEmpty()) {
             Iterator<MessageReference> iterator = diskList.iterator();
             while (iterator.hasNext()) {
@@ -147,7 +147,8 @@
                 iterator.remove();
             }
             diskList.clear();
-        }
+        }   
+	    store.deleteListContainer(name, "TopicSubscription");
     }
 
     public synchronized LinkedList<MessageReference> pageInList(int maxItems) {
@@ -316,10 +317,12 @@
         last=null;
     }
 
-    public synchronized boolean isFull() {
-        // we always have space - as we can persist to disk
-        return false;
-    }
+	public synchronized boolean isFull() {
+
+		return super.isFull()
+				|| (systemUsage != null && systemUsage.getTempUsage().isFull());
+
+	}
 
     public boolean hasMessagesBufferedToDeliver() {
         return !isEmpty();

Propchange: activemq/branches/activemq-5.3/activemq-core/src/main/java/org/apache/activemq/transport/stomp/StompSubscription.java
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Tue Jan  5 14:22:33 2010
@@ -1 +1 @@
-/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/StompSubscription.java:502054-818935,818937-819035,820031,820713-820714,820764,821090,821103,821115,825009-825084
+/activemq/trunk/activemq-core/src/main/java/org/apache/activemq/transport/stomp/StompSubscription.java:502054-818935,818937-819035,820031,820713-820714,820764,821090,821103,821115,825009-825084,881278-881313



Mime
View raw message