[rhmessaging-commits] rhmessaging commits: r2854 - mgmt/trunk/mint/python/mint.

rhmessaging-commits at lists.jboss.org rhmessaging-commits at lists.jboss.org
Thu Nov 20 13:31:11 EST 2008


Author: justi9
Date: 2008-11-20 13:31:10 -0500 (Thu, 20 Nov 2008)
New Revision: 2854

Modified:
   mgmt/trunk/mint/python/mint/update.py
Log:
Also set the other side of the broker-registration association

Modified: mgmt/trunk/mint/python/mint/update.py
===================================================================
--- mgmt/trunk/mint/python/mint/update.py	2008-11-20 15:44:42 UTC (rev 2853)
+++ mgmt/trunk/mint/python/mint/update.py	2008-11-20 18:31:10 UTC (rev 2854)
@@ -193,6 +193,16 @@
                 {"broker_id": dbId}, {"url": self.broker.getFullUrl()})
         #log.debug("SQL: %s", sql)
         cursor.execute(sql)
+
+        sql = """
+          update broker
+          set registration_id =
+            (select id from broker_registration where broker_id = %(id)s)
+          where id = %(id)s
+        """
+
+        cursor.execute(sql, {"id": dbId})
+
         model.managedBrokers[str(self.broker.getBrokerId())] = (broker, dbId)
 
     model.requeueIfOrphanParent(cls, idFirst, idSecond)




More information about the rhmessaging-commits mailing list