You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by rh...@apache.org on 2008/08/18 20:33:13 UTC

svn commit: r686843 - in /incubator/qpid/branches/qpid.0-10/java: broker/bin/ broker/src/test/java/org/apache/qpid/server/exchange/ broker/src/test/java/org/apache/qpid/server/queue/ broker/src/test/java/org/apache/qpid/server/store/ management/eclipse...

Author: rhs
Date: Mon Aug 18 11:33:09 2008
New Revision: 686843

URL: http://svn.apache.org/viewvc?rev=686843&view=rev
Log:
updated qpid.0-10/java to match trunk/qpid/java@686835

Modified:
    incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-passwd   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-server   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-server-bdb.bat   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-server.bat   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid.start   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid.stop   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid.stopall   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/bin/runAll   (props changed)
    incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/exchange/ExchangeMBeanTest.java
    incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueAlertTest.java
    incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueMBeanTest.java
    incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/SimpleAMQQueueTest.java
    incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/store/MessageStoreTest.java
    incubator/qpid/branches/qpid.0-10/java/management/eclipse-plugin/src/test/java/org/apache/qpid/management/ui/ManagementConsoleTest.java
    incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/client/AMQSessionTest.java
    incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/DurableSubscriptionTest.java
    incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/TopicSessionTest.java

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-passwd
------------------------------------------------------------------------------
    svn:executable = *

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-server
------------------------------------------------------------------------------
    svn:executable = *

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-server-bdb.bat
------------------------------------------------------------------------------
    svn:executable = *

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid-server.bat
------------------------------------------------------------------------------
    svn:executable = *

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid.start
------------------------------------------------------------------------------
    svn:executable = *

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid.stop
------------------------------------------------------------------------------
    svn:executable = *

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/qpid.stopall
------------------------------------------------------------------------------
    svn:executable = *

Propchange: incubator/qpid/branches/qpid.0-10/java/broker/bin/runAll
------------------------------------------------------------------------------
    svn:executable = *

Modified: incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/exchange/ExchangeMBeanTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/exchange/ExchangeMBeanTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/exchange/ExchangeMBeanTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/exchange/ExchangeMBeanTest.java Mon Aug 18 11:33:09 2008
@@ -129,11 +129,17 @@
     {
         super.setUp();
 
-        IApplicationRegistry applicationRegistry = ApplicationRegistry.getInstance();
+        IApplicationRegistry applicationRegistry = ApplicationRegistry.getInstance(1);
         _virtualHost = applicationRegistry.getVirtualHostRegistry().getVirtualHost("test");
         _queueRegistry = _virtualHost.getQueueRegistry();
         _queue = AMQQueueFactory.createAMQQueueImpl(new AMQShortString("testQueue"), false, new AMQShortString("ExchangeMBeanTest"), false, _virtualHost,
                                                     null);
         _queueRegistry.registerQueue(_queue);
     }
+
+    protected void tearDown()
+    {
+        ApplicationRegistry.remove(1);
+    }
+
 }

Modified: incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueAlertTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueAlertTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueAlertTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueAlertTest.java Mon Aug 18 11:33:09 2008
@@ -294,12 +294,18 @@
     protected void setUp() throws Exception
     {
         super.setUp();
-        IApplicationRegistry applicationRegistry = ApplicationRegistry.getInstance();
+        IApplicationRegistry applicationRegistry = ApplicationRegistry.getInstance(1);
         _virtualHost = applicationRegistry.getVirtualHostRegistry().getVirtualHost("test");
         _protocolSession = new InternalTestProtocolSession();
 
     }
 
+    protected void tearDown()
+    {
+        ApplicationRegistry.remove(1);
+    }
+
+
     private void sendMessages(long messageCount, final long size) throws AMQException
     {
         IncomingMessage[] messages = new IncomingMessage[(int) messageCount];

Modified: incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueMBeanTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueMBeanTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueMBeanTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/AMQQueueMBeanTest.java Mon Aug 18 11:33:09 2008
@@ -301,7 +301,7 @@
     protected void setUp() throws Exception
     {
         super.setUp();
-        IApplicationRegistry applicationRegistry = ApplicationRegistry.getInstance();
+        IApplicationRegistry applicationRegistry = ApplicationRegistry.getInstance(1);
         _virtualHost = applicationRegistry.getVirtualHostRegistry().getVirtualHost("test");
         _messageStore = _virtualHost.getMessageStore();
 
@@ -317,6 +317,11 @@
         _protocolSession = new InternalTestProtocolSession();
     }
 
+    public void tearDown()
+    {
+        ApplicationRegistry.remove(1);
+    }
+
     private void sendMessages(int messageCount, boolean persistent) throws AMQException
     {
         for (int i = 0; i < messageCount; i++)

Modified: incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/SimpleAMQQueueTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/SimpleAMQQueueTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/SimpleAMQQueueTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/queue/SimpleAMQQueueTest.java Mon Aug 18 11:33:09 2008
@@ -12,6 +12,7 @@
 import org.apache.qpid.server.txn.NonTransactionalContext;
 import org.apache.qpid.server.txn.TransactionalContext;
 import org.apache.qpid.server.virtualhost.VirtualHost;
+import org.apache.qpid.server.registry.ApplicationRegistry;
 
 import junit.framework.TestCase;
 
@@ -56,11 +57,20 @@
     protected void setUp() throws Exception
     {
         super.setUp();
+        //Create Application Registry for test
+        ApplicationRegistry.getInstance(1);
+
         AMQShortString qname = new AMQShortString("qname");
         AMQShortString owner = new AMQShortString("owner");
         _queue = new SimpleAMQQueue(qname, false, owner, false, new VirtualHost("vhost", store));
     }
 
+    @Override
+    protected void tearDown()
+    {
+        ApplicationRegistry.remove(1);
+    }
+
     public void testGetFirstMessageId() throws Exception
     {
         // Create message

Modified: incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/store/MessageStoreTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/store/MessageStoreTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/store/MessageStoreTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/broker/src/test/java/org/apache/qpid/server/store/MessageStoreTest.java Mon Aug 18 11:33:09 2008
@@ -37,6 +37,7 @@
 import org.apache.qpid.server.queue.ExchangeBinding;
 import org.apache.qpid.server.txn.NonTransactionalContext;
 import org.apache.qpid.server.protocol.InternalTestProtocolSession;
+import org.apache.qpid.server.registry.ApplicationRegistry;
 import org.apache.qpid.framing.AMQShortString;
 import org.apache.qpid.framing.FieldTable;
 import org.apache.qpid.framing.ContentHeaderBody;
@@ -130,6 +131,16 @@
     AMQShortString directRouting = new AMQShortString("MST-direct");
     AMQShortString topicRouting = new AMQShortString("MST-topic");
 
+    protected void setUp()
+    {
+        ApplicationRegistry.getInstance(1);
+    }
+
+    protected void tearDown()
+    {
+        ApplicationRegistry.remove(1);
+    }
+
     protected void runTestWithStore(Configuration configuration)
     {
         //Ensure Environment Path is empty

Modified: incubator/qpid/branches/qpid.0-10/java/management/eclipse-plugin/src/test/java/org/apache/qpid/management/ui/ManagementConsoleTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/management/eclipse-plugin/src/test/java/org/apache/qpid/management/ui/ManagementConsoleTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/management/eclipse-plugin/src/test/java/org/apache/qpid/management/ui/ManagementConsoleTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/management/eclipse-plugin/src/test/java/org/apache/qpid/management/ui/ManagementConsoleTest.java Mon Aug 18 11:33:09 2008
@@ -55,6 +55,12 @@
         _virtualHost = applicationRegistry.getVirtualHostRegistry().getVirtualHost("test");
     }
 
+    @Override
+    protected void tearDown() throws Exception
+    {
+        ApplicationRegistry.removeAll();
+    }
+
     /**
      * Test for AMQQueueMBean attribute and operation names, which are used in the management console
      * @throws Exception

Modified: incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/client/AMQSessionTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/client/AMQSessionTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/client/AMQSessionTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/client/AMQSessionTest.java Mon Aug 18 11:33:09 2008
@@ -79,6 +79,8 @@
 
         subscriber = _session.createDurableSubscriber(_topic, "mysubname2", "abc", false);
         assertEquals("Topic names should match from durable TopicSubscriber with selector", _topic.getTopicName(), subscriber.getTopic().getTopicName());
+        _session.unsubscribe("mysubname");
+        _session.unsubscribe("mysubname2");
     }
 
     public void testCreateQueueReceiver() throws JMSException

Modified: incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/DurableSubscriptionTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/DurableSubscriptionTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/DurableSubscriptionTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/DurableSubscriptionTest.java Mon Aug 18 11:33:09 2008
@@ -188,6 +188,8 @@
         consumer1.close();
         consumer3.close();
 
+        session3.unsubscribe("MySubscription");
+
         con.close();
     }
 
@@ -266,6 +268,8 @@
         consumer1.close();
         consumer3.close();
 
+        session3.unsubscribe("MySubscription");
+
         con0.close();
         con1.close();
         con3.close();
@@ -305,6 +309,7 @@
     	assertNotNull ("Message should have been received", msg);
     	assertEquals ("testDurableWithInvalidSelector2", ((TextMessage) msg).getText());
     	assertNull("Should not receive subsequent message", liveSubscriber.receive(200));
+        session.unsubscribe("testDurableWithInvalidSelectorSub");
     }
     
     /***
@@ -339,6 +344,8 @@
     	assertNotNull ("Message should have been received", msg);
     	assertEquals ("testDurableWithInvalidSelector2", ((TextMessage) msg).getText());
     	assertNull("Should not receive subsequent message", liveSubscriber.receive(200));
+
+        session.unsubscribe("testDurableWithInvalidDestinationsub");
     }
     
     public static junit.framework.Test suite()

Modified: incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/TopicSessionTest.java
URL: http://svn.apache.org/viewvc/incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/TopicSessionTest.java?rev=686843&r1=686842&r2=686843&view=diff
==============================================================================
--- incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/TopicSessionTest.java (original)
+++ incubator/qpid/branches/qpid.0-10/java/systests/src/main/java/org/apache/qpid/test/unit/topic/TopicSessionTest.java Mon Aug 18 11:33:09 2008
@@ -134,6 +134,7 @@
         m = (TextMessage) sub2.receive(2000);
         assertNotNull(m);
         assertEquals("goodbye", m.getText());
+        session1.unsubscribe("subscription0");
         con.close();
     }
 
@@ -163,6 +164,7 @@
         tm = (TextMessage) sub.receive(2000);
         assertNotNull(tm);
         assertEquals("Hello2", tm.getText());
+        session2.unsubscribe("subscription0");
         con1.close();
         con2.close();
     }