incubator-cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From alena1...@apache.org
Subject git commit: CS-15717: fail to delete the network when corresponding network elements fail to be destroyed
Date Fri, 27 Jul 2012 22:35:57 GMT
Updated Branches:
  refs/heads/master 468f2720e -> dabd85e15


CS-15717: fail to delete the network when corresponding network elements fail to be destroyed


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/dabd85e1
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/dabd85e1
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/dabd85e1

Branch: refs/heads/master
Commit: dabd85e153e2a46e243cba4b06dd13c5674a84b5
Parents: 468f272
Author: Alena Prokharchyk <alena.prokharchyk@citrix.com>
Authored: Fri Jul 27 15:07:36 2012 -0700
Committer: Alena Prokharchyk <alena.prokharchyk@citrix.com>
Committed: Fri Jul 27 15:33:53 2012 -0700

----------------------------------------------------------------------
 .../src/com/cloud/network/NetworkManagerImpl.java  |    7 +++++--
 1 files changed, 5 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/dabd85e1/server/src/com/cloud/network/NetworkManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/network/NetworkManagerImpl.java b/server/src/com/cloud/network/NetworkManagerImpl.java
index c96ea52..83acc9b 100755
--- a/server/src/com/cloud/network/NetworkManagerImpl.java
+++ b/server/src/com/cloud/network/NetworkManagerImpl.java
@@ -3215,7 +3215,10 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService,
Manag
                         s_logger.debug("Sending destroy to " + element);
                     }
 
-                    element.destroy(network);
+                    if (!element.destroy(network)) {
+                        success = false;
+                        s_logger.warn("Unable to complete destroy of the network: failed
to destroy network element " + element.getName());
+                    }
                 } catch (ResourceUnavailableException e) {
                     s_logger.warn("Unable to complete destroy of the network due to element:
" + element.getName(), e);
                     success = false;
@@ -3225,7 +3228,7 @@ public class NetworkManagerImpl implements NetworkManager, NetworkService,
Manag
                 } catch (Exception e) {
                     s_logger.warn("Unable to complete destroy of the network due to element:
" + element.getName(), e);
                     success = false;
-                }
+                } 
             }
         }
 


Mime
View raw message