mirror of https://github.com/apache/cloudstack.git
CLOUDSTACK-1551: Failed to list clusters due to NPE at createClusterResponse(ApiResponseHelper.java:837) when cluster is added automatically as a part of addHostCommand
Signed-off-by: Abhinandan Prateek <aprateek@apache.org>
This commit is contained in:
parent
27b753a434
commit
6715f98087
|
|
@ -770,6 +770,13 @@ public class ResourceManagerImpl extends ManagerBase implements ResourceManager,
|
|||
}
|
||||
}
|
||||
clusterId = cluster.getId();
|
||||
if (_clusterDetailsDao.findDetail(clusterId,"cpuOvercommitRatio") == null) {
|
||||
ClusterDetailsVO cluster_cpu_detail = new ClusterDetailsVO(clusterId,"cpuOvercommitRatio","1");
|
||||
ClusterDetailsVO cluster_memory_detail = new ClusterDetailsVO(clusterId,"memoryOvercommitRatio","1");
|
||||
_clusterDetailsDao.persist(cluster_cpu_detail);
|
||||
_clusterDetailsDao.persist(cluster_memory_detail);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
try {
|
||||
|
|
|
|||
Loading…
Reference in New Issue