Author: aconway
Date: Tue Jun 8 19:31:59 2010
New Revision: 952786
URL: http://svn.apache.org/viewvc?rev=952786&view=rev
Log:
brokertest.py: fix ready() test to create a session as well as a connection.
The change in r952692 means that just creating a connection will
return before a clustered broker is fully initialized. Creating a
session will block till the broker is initialized.
Modified:
qpid/trunk/qpid/python/qpid/brokertest.py
Modified: qpid/trunk/qpid/python/qpid/brokertest.py
URL:
http://svn.apache.org/viewvc/qpid/trunk/qpid/python/qpid/brokertest.py?rev=952786&r1=952785&r2=952786&view=diff
==============================================================================
--- qpid/trunk/qpid/python/qpid/brokertest.py (original)
+++ qpid/trunk/qpid/python/qpid/brokertest.py Tue Jun 8 19:31:59 2010
@@ -384,8 +384,12 @@ class Broker(Popen):
if not retry(self.log_ready):
raise Exception(
"Timed out waiting for broker %s%s"%(self.name,
error_line(self.log,4)))
- # Make a connection, this will wait for extended cluster init to
finish.
- try: self.connect(**kwargs).close()
+ # Create a connection and a session. For a cluster broker this will
+ # return after cluster init has finished.
+ try:
+ c = self.connect(**kwargs)
+ try: c.session()
+ finally: c.close()
except: raise RethrownException(
"Broker %s failed ready test%s"%(self.name,error_line(self.log,4)))
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:[email protected]