mirror of
				https://github.com/apache/cloudstack.git
				synced 2025-10-26 08:42:29 +01:00 
			
		
		
		
	Fix CID 1114609 Log the correct number
This commit is contained in:
		
							parent
							
								
									ec43bfce90
								
							
						
					
					
						commit
						1440a1c6a0
					
				| @ -31,6 +31,8 @@ import javax.ejb.Local; | ||||
| import javax.inject.Inject; | ||||
| import javax.naming.ConfigurationException; | ||||
| 
 | ||||
| import org.apache.log4j.Logger; | ||||
| 
 | ||||
| import org.apache.cloudstack.affinity.AffinityGroupProcessor; | ||||
| import org.apache.cloudstack.affinity.AffinityGroupService; | ||||
| import org.apache.cloudstack.affinity.AffinityGroupVMMapVO; | ||||
| @ -49,7 +51,6 @@ import org.apache.cloudstack.managed.context.ManagedContextTimerTask; | ||||
| import org.apache.cloudstack.storage.datastore.db.PrimaryDataStoreDao; | ||||
| import org.apache.cloudstack.storage.datastore.db.StoragePoolVO; | ||||
| import org.apache.cloudstack.utils.identity.ManagementServerNode; | ||||
| import org.apache.log4j.Logger; | ||||
| 
 | ||||
| import com.cloud.agent.AgentManager; | ||||
| import com.cloud.agent.Listener; | ||||
| @ -695,7 +696,7 @@ public class DeploymentPlanningManagerImpl extends ManagerBase implements Deploy | ||||
|                 List<VMInstanceVO> vmsStoppingMigratingByHostId = _vmInstanceDao.findByHostInStates(hostId, State.Stopping, State.Migrating, State.Starting); | ||||
|                 if (vmsStoppingMigratingByHostId.size() > 0) { | ||||
|                     if (s_logger.isDebugEnabled()) { | ||||
|                         s_logger.debug("Cannot release reservation, Found " + vms.size() + " VMs stopping/migrating on host " + hostId); | ||||
|                         s_logger.debug("Cannot release reservation, Found " + vmsStoppingMigratingByHostId.size() + " VMs stopping/migrating/starting on host " + hostId); | ||||
|                     } | ||||
|                     return false; | ||||
|                 } | ||||
| @ -1388,7 +1389,7 @@ public class DeploymentPlanningManagerImpl extends ManagerBase implements Deploy | ||||
|                     List<Long> groupIds = _affinityGroupVMMapDao.listAffinityGroupIdsByVmId(vm.getId()); | ||||
|                     SearchCriteria<AffinityGroupVO> criteria = _affinityGroupDao.createSearchCriteria(); | ||||
|                     criteria.addAnd("id", SearchCriteria.Op.IN, groupIds.toArray(new Object[groupIds.size()])); | ||||
|                 List<AffinityGroupVO> groups = _affinityGroupDao.lockRows(criteria, null, true); | ||||
|                     _affinityGroupDao.lockRows(criteria, null, true); | ||||
| 
 | ||||
|                     for (AffinityGroupProcessor processor : _affinityProcessors) { | ||||
|                         if (!processor.check(vmProfile, plannedDestination)) { | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user