mirror of https://github.com/apache/cloudstack.git
Bug 7845 - Productize DeploymentPlanner
The user concentrated pod heuristic should consider VMs for the given account that are in 'Running' or 'Stopped' state only.
This commit is contained in:
parent
37ad7069c2
commit
95c071e179
|
|
@ -72,7 +72,8 @@ public class UserVmDaoImpl extends GenericDaoBase<UserVmVO, Long> implements Use
|
|||
protected SearchBuilder<UserVmVO> UserVmSearch;
|
||||
protected final Attribute _updateTimeAttr;
|
||||
|
||||
private static final String LIST_PODS_HAVING_VMS_FOR_ACCOUNT = "SELECT pod_id FROM cloud.vm_instance WHERE data_center_id = ? AND account_id = ? AND pod_id IS NOT NULL GROUP BY pod_id HAVING count(id) > 0 ORDER BY count(id) DESC";
|
||||
private static final String LIST_PODS_HAVING_VMS_FOR_ACCOUNT = "SELECT pod_id FROM cloud.vm_instance WHERE data_center_id = ? AND account_id = ? AND pod_id IS NOT NULL AND state = 'Running' OR state = 'Stopped' " +
|
||||
"GROUP BY pod_id HAVING count(id) > 0 ORDER BY count(id) DESC";
|
||||
|
||||
|
||||
protected final UserVmDetailsDaoImpl _detailsDao = ComponentLocator.inject(UserVmDetailsDaoImpl.class);
|
||||
|
|
|
|||
Loading…
Reference in New Issue