]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
Fix pool update error in lbaas
authorEugene Nikanorov <enikanorov@mirantis.com>
Thu, 30 May 2013 08:25:16 +0000 (12:25 +0400)
committerEugene Nikanorov <enikanorov@mirantis.com>
Thu, 30 May 2013 08:32:47 +0000 (12:32 +0400)
fixes bug 1185687

Do not notify namespace agent of modified pool
if pool doesn't have vip

Change-Id: Ibe3399aaa145d19fc758f08adb51c7ffefa5bb3a

quantum/plugins/services/agent_loadbalancer/plugin.py

index c891873dae7c81c06d09587f40a73a75b00f7d01..b29f1e771eb5f076af641ca966cbf2420415d141 100644 (file)
@@ -275,7 +275,8 @@ class LoadBalancerPlugin(loadbalancer_db.LoadBalancerPluginDb):
             pool['pool']['status'] = constants.PENDING_UPDATE
         p = super(LoadBalancerPlugin, self).update_pool(context, id, pool)
         if p['status'] in ACTIVE_PENDING:
-            self.agent_rpc.reload_pool(context, p['id'])
+            if p['vip_id'] is not None:
+                self.agent_rpc.reload_pool(context, p['id'])
         else:
             self.agent_rpc.destroy_pool(context, p['id'])
         return p