You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by bf...@apache.org on 2013/04/19 00:19:03 UTC
[06/31] git commit: updated refs/heads/ui-mixed-zone-management to
e044303
(CLOUDSTACK-2068) Anti-Affinity - When Vm deployment associated with anity-affinity group fails , it is still included in the vmlist of the anti-affiity group
Changes:
- Added removal of the groups association when VM reaches 'Error' state.
Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/11244660
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/11244660
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/11244660
Branch: refs/heads/ui-mixed-zone-management
Commit: 112446602d119a7599e7077831ea73892d889a66
Parents: e8269a6
Author: Prachi Damle <pr...@cloud.com>
Authored: Wed Apr 17 14:59:04 2013 -0700
Committer: Prachi Damle <pr...@cloud.com>
Committed: Wed Apr 17 15:00:56 2013 -0700
----------------------------------------------------------------------
.../cloudstack/api/command/user/vm/ListVMsCmd.java | 2 +-
.../affinity/AffinityGroupServiceImpl.java | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/11244660/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java b/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
index 30f03b8..08f9457 100644
--- a/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
@@ -95,7 +95,7 @@ public class ListVMsCmd extends BaseListTaggedResourcesCmd {
@Parameter(name=ApiConstants.DETAILS, type=CommandType.LIST, collectionType=CommandType.STRING,
description="comma separated list of host details requested, " +
- "value can be a list of [all, group, nics, stats, secgrp, tmpl, servoff, iso, volume, min]." +
+ "value can be a list of [all, group, nics, stats, secgrp, tmpl, servoff, iso, volume, min, affgrp]." +
" If no parameter is passed in, the details will be defaulted to all" )
private List<String> viewDetails;
http://git-wip-us.apache.org/repos/asf/cloudstack/blob/11244660/server/src/org/apache/cloudstack/affinity/AffinityGroupServiceImpl.java
----------------------------------------------------------------------
diff --git a/server/src/org/apache/cloudstack/affinity/AffinityGroupServiceImpl.java b/server/src/org/apache/cloudstack/affinity/AffinityGroupServiceImpl.java
index 2b490ef..fc2cfcf 100644
--- a/server/src/org/apache/cloudstack/affinity/AffinityGroupServiceImpl.java
+++ b/server/src/org/apache/cloudstack/affinity/AffinityGroupServiceImpl.java
@@ -295,7 +295,7 @@ public class AffinityGroupServiceImpl extends ManagerBase implements AffinityGro
if (!status) {
return false;
}
- if ((newState == State.Expunging)) {
+ if ((newState == State.Expunging) || (newState == State.Error)) {
// cleanup all affinity groups associations of the Expunged VM
SearchCriteria<AffinityGroupVMMapVO> sc = _affinityGroupVMMapDao.createSearchCriteria();
sc.addAnd("instanceId", SearchCriteria.Op.EQ, vo.getId());