Don't allow to update zone with new guestVlan range if the zone's network type is Basic

This commit is contained in:
alena 2010-11-16 18:51:28 -08:00
parent 745d3e816d
commit f2c1291f6d
1 changed files with 5 additions and 0 deletions

View File

@ -877,6 +877,11 @@ public class ConfigurationManagerImpl implements ConfigurationManager, Configura
if (zoneName == null) {
zoneName = zone.getName();
}
//if zone is of Basic type, don't allow to add vnet range
if (vnetRange != null && zone.getNetworkType() == DataCenterNetworkType.Basic) {
throw new InvalidParameterValueException("Can't add vnet range for the zone that supports Basic network");
}
// Make sure the zone exists
if (!validZone(zoneId)) {