activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r504228 - /activemq/trunk/activemq-core/src/test/java/org/apache/activemq/broker/MessageExpirationTest.java
Date Tue, 06 Feb 2007 18:06:26 GMT
Author: jstrachan
Date: Tue Feb  6 10:06:25 2007
New Revision: 504228

URL: http://svn.apache.org/viewvc?view=rev&rev=504228
Log:
fix text case by disabling spooling to disk

Modified:
    activemq/trunk/activemq-core/src/test/java/org/apache/activemq/broker/MessageExpirationTest.java

Modified: activemq/trunk/activemq-core/src/test/java/org/apache/activemq/broker/MessageExpirationTest.java
URL: http://svn.apache.org/viewvc/activemq/trunk/activemq-core/src/test/java/org/apache/activemq/broker/MessageExpirationTest.java?view=diff&rev=504228&r1=504227&r2=504228
==============================================================================
--- activemq/trunk/activemq-core/src/test/java/org/apache/activemq/broker/MessageExpirationTest.java
(original)
+++ activemq/trunk/activemq-core/src/test/java/org/apache/activemq/broker/MessageExpirationTest.java
Tue Feb  6 10:06:25 2007
@@ -29,6 +29,10 @@
 import org.apache.activemq.command.MessageAck;
 import org.apache.activemq.command.ProducerInfo;
 import org.apache.activemq.command.SessionInfo;
+import org.apache.activemq.broker.region.policy.PolicyMap;
+import org.apache.activemq.broker.region.policy.PolicyEntry;
+import org.apache.activemq.broker.region.policy.RoundRobinDispatchPolicy;
+import org.apache.activemq.broker.region.policy.VMPendingSubscriberMessageStoragePolicy;
 
 public class MessageExpirationTest extends BrokerTestSupport {
     
@@ -57,6 +61,22 @@
                 new Byte(ActiveMQDestination.QUEUE_TYPE), 
                 new Byte(ActiveMQDestination.TOPIC_TYPE), 
                 } );
+    }
+
+    @Override
+    protected BrokerService createBroker() throws Exception {
+        BrokerService broker = new BrokerService();
+        broker.setPersistent(false);
+
+        // lets disable spooling
+        PolicyEntry policy = new PolicyEntry();
+        policy.setPendingSubscriberPolicy(new VMPendingSubscriberMessageStoragePolicy());
+
+        PolicyMap map = new PolicyMap();
+        map.setDefaultEntry(policy);
+        broker.setDestinationPolicy(map);
+        
+        return broker;
     }
 
     public void testMessagesWaitingForUssageDecreaseExpire() throws Exception {



Mime
View raw message