cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kous...@apache.org
Subject [48/50] [abbrv] git commit: refs/heads/cisco-vnmc-api-integration - Merge branch 'master' into cisco-vnmc-api-integration
Date Thu, 21 Mar 2013 05:22:35 GMT
Merge branch 'master' into cisco-vnmc-api-integration

Conflicts:
	api/src/com/cloud/network/Network.java
	api/src/org/apache/cloudstack/api/ApiConstants.java
	client/tomcatconf/components-nonoss.xml.in
	client/tomcatconf/nonossComponentContext.xml.in
	plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
	plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java
	setup/db/db/schema-410to420.sql
	vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java


Project: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/commit/f0c1af2b
Tree: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/tree/f0c1af2b
Diff: http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/diff/f0c1af2b

Branch: refs/heads/cisco-vnmc-api-integration
Commit: f0c1af2b5c037bf49bfc2775108600e2fbdc720f
Parents: 4f305c2 873ec27
Author: Koushik Das <koushik.das@citrix.com>
Authored: Wed Mar 20 16:20:10 2013 +0530
Committer: Koushik Das <koushik.das@citrix.com>
Committed: Wed Mar 20 16:20:10 2013 +0530

----------------------------------------------------------------------
 .gitignore                                         |    1 +
 LICENSE                                            |    2 +-
 agent/conf/agent.properties                        |    2 +-
 agent/pom.xml                                      |   24 +-
 agent/src/com/cloud/agent/AgentShell.java          |   20 +-
 .../consoleproxy/ConsoleProxyResource.java         |   25 +-
 .../com/cloud/agent/api/BackupSnapshotCommand.java |    7 +
 api/src/com/cloud/agent/api/ScaleVmAnswer.java     |   28 +
 api/src/com/cloud/agent/api/ScaleVmCommand.java    |  113 +
 .../com/cloud/agent/api/SecurityGroupRulesCmd.java |   37 +
 .../cloud/agent/api/routing/DhcpEntryCommand.java  |   10 +
 .../api/routing/HealthCheckLBConfigAnswer.java     |   42 +
 .../api/routing/HealthCheckLBConfigCommand.java    |   39 +
 api/src/com/cloud/agent/api/to/LoadBalancerTO.java |  114 +-
 api/src/com/cloud/agent/api/to/NicTO.java          |   11 +
 .../com/cloud/agent/api/to/VirtualMachineTO.java   |   31 +
 api/src/com/cloud/alert/Alert.java                 |    1 +
 api/src/com/cloud/domain/Domain.java               |    1 -
 api/src/com/cloud/event/Event.java                 |    1 +
 api/src/com/cloud/event/EventTypes.java            |    2 +
 .../cloud/exception/PermissionDeniedException.java |    4 +
 .../com/cloud/exception/RequestLimitException.java |    3 +-
 api/src/com/cloud/network/IpAddress.java           |    3 +
 api/src/com/cloud/network/Network.java             |    2 +-
 api/src/com/cloud/network/NetworkModel.java        |    2 +
 api/src/com/cloud/network/NetworkService.java      |   15 +-
 api/src/com/cloud/network/TrafficLabel.java        |   36 +
 .../element/LoadBalancingServiceProvider.java      |    8 +-
 .../com/cloud/network/lb/LoadBalancingRule.java    |   84 +-
 .../network/lb/LoadBalancingRulesService.java      |   32 +-
 .../com/cloud/network/rules/HealthCheckPolicy.java |   45 +
 api/src/com/cloud/network/rules/RulesService.java  |    5 +-
 .../network/security/SecurityGroupService.java     |    4 +-
 api/src/com/cloud/server/ManagementService.java    |   38 +-
 .../com/cloud/template/VirtualMachineTemplate.java |    1 +
 api/src/com/cloud/user/Account.java                |    2 -
 api/src/com/cloud/user/AccountService.java         |    4 +-
 api/src/com/cloud/user/DomainService.java          |    2 +-
 api/src/com/cloud/user/User.java                   |    1 -
 api/src/com/cloud/vm/Nic.java                      |    1 +
 api/src/com/cloud/vm/NicSecondaryIp.java           |   36 +
 api/src/com/cloud/vm/UserVmService.java            |    3 +-
 api/src/org/apache/cloudstack/acl/APIChecker.java  |    3 +-
 api/src/org/apache/cloudstack/api/ACL.java         |    4 +
 .../org/apache/cloudstack/api/ApiConstants.java    |   22 +-
 .../apache/cloudstack/api/ApiConstants.java.orig   |  468 ---
 .../apache/cloudstack/api/ResponseGenerator.java   |   14 +
 .../command/admin/account/CreateAccountCmd.java    |   29 +-
 .../command/admin/account/DeleteAccountCmd.java    |   11 +-
 .../command/admin/account/DisableAccountCmd.java   |   17 +-
 .../command/admin/account/EnableAccountCmd.java    |   11 +-
 .../command/admin/account/UpdateAccountCmd.java    |   11 +-
 .../api/command/admin/cluster/AddClusterCmd.java   |   28 +
 .../api/command/admin/domain/CreateDomainCmd.java  |   13 +-
 .../api/command/admin/domain/DeleteDomainCmd.java  |    9 +-
 .../api/command/admin/domain/UpdateDomainCmd.java  |   11 +-
 .../api/command/admin/region/AddRegionCmd.java     |   16 +-
 .../api/command/admin/region/RemoveRegionCmd.java  |    2 +-
 .../api/command/admin/region/UpdateRegionCmd.java  |   15 +-
 .../command/admin/resource/ArchiveAlertsCmd.java   |  100 +
 .../command/admin/resource/DeleteAlertsCmd.java    |   99 +
 .../admin/storage/CreateStoragePoolCmd.java        |    4 +-
 .../api/command/admin/user/CreateUserCmd.java      |   21 +-
 .../api/command/admin/user/DeleteUserCmd.java      |   13 +-
 .../api/command/admin/user/DisableUserCmd.java     |   11 +-
 .../api/command/admin/user/EnableUserCmd.java      |   11 +-
 .../api/command/admin/user/UpdateUserCmd.java      |   11 +-
 .../api/command/admin/vm/AssignVMCmd.java          |    8 +-
 .../command/user/config/ListCapabilitiesCmd.java   |    8 +-
 .../api/command/user/event/ArchiveEventsCmd.java   |  105 +
 .../api/command/user/event/DeleteEventsCmd.java    |  105 +
 .../user/firewall/CreatePortForwardingRuleCmd.java |   19 +-
 .../api/command/user/iso/ListIsosCmd.java          |   15 +-
 .../loadbalancer/CreateLBHealthCheckPolicyCmd.java |  168 +
 .../loadbalancer/DeleteLBHealthCheckPolicyCmd.java |  116 +
 .../loadbalancer/ListLBHealthCheckPoliciesCmd.java |   85 +
 .../api/command/user/nat/EnableStaticNatCmd.java   |   12 +-
 .../command/user/template/ListTemplatesCmd.java    |   13 +-
 .../api/command/user/vm/AddIpToVmNicCmd.java       |  197 ++
 .../api/command/user/vm/DeployVMCmd.java           |    4 +-
 .../api/command/user/vm/ListNicsCmd.java           |  133 +
 .../api/command/user/vm/RemoveIpFromVmNicCmd.java  |  172 +
 .../api/command/user/vm/UpgradeVMCmd.java          |    4 +-
 .../api/command/user/zone/ListZonesByCmd.java      |    7 +
 .../api/response/AddIpToVmNicResponse.java         |   85 +
 .../api/response/DomainRouterResponse.java         |    5 +-
 .../cloudstack/api/response/IPAddressResponse.java |    8 +
 .../api/response/LBHealthCheckPolicyResponse.java  |   98 +
 .../api/response/LBHealthCheckResponse.java        |  102 +
 .../cloudstack/api/response/NicResponse.java       |   12 +-
 .../api/response/NicSecondaryIpResponse.java       |   95 +
 .../api/response/SecurityGroupResponse.java        |    7 +-
 .../cloudstack/api/response/UserVmResponse.java    |    7 +-
 .../cloudstack/api/response/VolumeResponse.java    |    3 +-
 .../cloudstack/api/response/VpnUsersResponse.java  |   10 +
 api/src/org/apache/cloudstack/region/Region.java   |    3 -
 .../apache/cloudstack/region/RegionService.java    |    8 +-
 .../api/agent/test/BackupSnapshotAnswerTest.java   |    2 +-
 .../api/agent/test/BackupSnapshotCommandTest.java  |    4 +-
 .../api/command/test/AddIpToVmNicTest.java         |  132 +
 .../cloudstack/api/command/test/RegionCmdTest.java |    4 +-
 awsapi/pom.xml                                     |    2 +-
 .../bridge/persist/dao/CloudStackUserDaoImpl.java  |    2 +
 .../WEB-INF/classes/resources/messages.properties  |    8 +
 .../classes/resources/messages_fr_FR.properties    | 2446 +++++++--------
 client/WEB-INF/web.xml                             |    2 +-
 client/pom.xml                                     |   77 +-
 client/tomcatconf/applicationContext.xml.in        |    7 +-
 client/tomcatconf/commands.properties.in           |   12 +
 client/tomcatconf/componentContext.xml.in          |   54 +-
 client/tomcatconf/components-cloudzones.xml.in     |   33 -
 client/tomcatconf/components-nonoss.xml.in         |  100 -
 client/tomcatconf/components.xml.in                |  309 --
 client/tomcatconf/log4j-cloud.xml.in               |   25 +
 client/tomcatconf/nonossComponentContext.xml.in    |   40 +-
 .../api/NetworkRulesVmSecondaryIpCommand.java      |   71 +
 .../virtualnetwork/VirtualRoutingResource.java     |   52 +-
 core/src/com/cloud/alert/AlertManager.java         |   41 +-
 core/src/com/cloud/alert/AlertVO.java              |   38 +-
 core/src/com/cloud/event/EventVO.java              |  167 +-
 core/src/com/cloud/event/dao/EventDao.java         |    5 +
 core/src/com/cloud/event/dao/EventDaoImpl.java     |   71 +-
 core/src/com/cloud/storage/DiskOfferingVO.java     |    4 +
 .../src/com/cloud/storage/StoragePoolDetailVO.java |   81 -
 .../cloud/storage/template/RawImageProcessor.java  |    1 +
 core/src/com/cloud/user/AccountVO.java             |   13 +-
 core/src/com/cloud/user/UserVO.java                |   13 +-
 debian/README                                      |    6 -
 debian/changelog                                   |   12 +
 debian/cloud-agent-deps.install                    |   18 -
 debian/cloud-agent-libs.install                    |   19 -
 debian/cloud-agent.config                          |   17 -
 debian/cloud-agent.install                         |   25 -
 debian/cloud-agent.postinst                        |   34 -
 debian/cloud-cli.config                            |   17 -
 debian/cloud-cli.install                           |   21 -
 debian/cloud-client-ui.install                     |   19 -
 debian/cloud-client.config                         |   17 -
 debian/cloud-client.install                        |   58 -
 debian/cloud-client.postinst                       |   49 -
 debian/cloud-core.install                          |   19 -
 debian/cloud-deps.install                          |   34 -
 debian/cloud-management.config                     |   17 -
 debian/cloud-python.install                        |   18 -
 debian/cloud-scripts.install                       |   27 -
 debian/cloud-server.install                        |   32 -
 debian/cloud-setup.install                         |   25 -
 debian/cloud-system-iso.install                    |   18 -
 debian/cloud-usage.install                         |   23 -
 debian/cloud-usage.postinst                        |   47 -
 debian/cloud-utils.install                         |   22 -
 debian/cloudstack-agent.install                    |   26 +
 debian/cloudstack-agent.postinst                   |   40 +
 debian/cloudstack-awsapi.install                   |   18 +
 debian/cloudstack-cli.install                      |   16 +
 debian/cloudstack-common.install                   |   31 +
 debian/cloudstack-docs.install                     |   16 +
 debian/cloudstack-management.install               |   33 +
 debian/cloudstack-management.postinst              |   26 +
 debian/cloudstack-usage.install                    |   22 +
 debian/cloudstack-usage.postinst                   |   37 +
 debian/control                                     |  133 +-
 debian/rules                                       |  152 +-
 deps/install-non-oss.sh                            |   11 +-
 developer/pom.xml                                  |  240 +-
 docs/en-US/Developers_Guide.xml                    |    2 +-
 docs/en-US/Installation_Guide.xml                  |    1 +
 docs/en-US/Release_Notes.xml                       |    4 +-
 docs/en-US/accessing-vms.xml                       |    4 +-
 docs/en-US/add-clusters-ovm.xml                    |    6 +-
 docs/en-US/add-remove-nic.xml                      |  127 +
 docs/en-US/added-API-commands-4-1.xml              |   28 +
 docs/en-US/added-error-codes.xml                   |    2 +-
 docs/en-US/advanced-zone-guest-ip-addresses.xml    |   12 +-
 docs/en-US/autoscale.xml                           |    6 +-
 docs/en-US/aws-ec2-configuration.xml               |    5 +-
 docs/en-US/aws-ec2-user-setup.xml                  |    4 +-
 docs/en-US/best-practices.xml                      |   82 +
 docs/en-US/build-deb.xml                           |    2 +-
 docs/en-US/build-rpm.xml                           |  146 +-
 docs/en-US/building-marvin.xml                     |    4 +-
 ...change-console-proxy-ssl-certificate-domain.xml |    4 +-
 docs/en-US/changed-apicommands-4.1.xml             |  141 +-
 docs/en-US/citrix-xenserver-installation.xml       |    8 +-
 docs/en-US/cloudmonkey.xml                         |  264 ++
 docs/en-US/console-proxy.xml                       |    4 +-
 docs/en-US/create-bare-metal-template.xml          |    1 -
 docs/en-US/creating-vms.xml                        |    2 +-
 docs/en-US/dedicated-ha-hosts.xml                  |    2 +-
 docs/en-US/deployment-architecture-overview.xml    |    3 +-
 docs/en-US/devcloud-usage-mode.xml                 |    4 +-
 docs/en-US/event-framework.xml                     |  110 +
 docs/en-US/events.xml                              |   18 +-
 docs/en-US/getting-release.xml                     |   40 +-
 docs/en-US/globally-configured-limits.xml          |    2 +-
 docs/en-US/guest-traffic.xml                       |    9 +-
 docs/en-US/ipv6-support.xml                        |  191 ++
 docs/en-US/networks.xml                            |    1 +
 docs/en-US/reserved-ip-addresses-non-csvms.xml     |  163 +
 docs/en-US/shared-networks.xml                     |    3 +-
 docs/en-US/source-prereqs.xml                      |   13 +-
 docs/en-US/source.xml                              |   18 +-
 docs/en-US/tools.xml                               |    1 +
 docs/en-US/upload-existing-volume-to-vm.xml        |    6 +-
 docs/en-US/using-vpn-with-mac.xml                  |   15 +-
 docs/en-US/using-vpn-with-windows.xml              |   10 +-
 docs/en-US/verifying-source.xml                    |    2 +-
 docs/en-US/vlan-provisioning.xml                   |   23 +-
 docs/en-US/whats-new.xml                           |    4 +-
 docs/en-US/working-with-snapshots.xml              |    4 +
 docs/en-US/working-with-usage-data.xml             |    1 +
 docs/en-US/zone-add.xml                            |    2 +-
 docs/pot/build-deb.pot                             |    2 +-
 docs/publican-cloudstack/defaults.cfg              |    2 +-
 docs/publican-cloudstack/en-US/Legal_Notice.xml    |    9 +
 .../en-US/images/title_logo.svg                    |   32 +-
 docs/publican-cloudstack/publican-cloudstack.spec  |    6 +-
 .../cloud/entity/api/VirtualMachineEntity.java     |    4 +-
 .../subsystem/api/storage/AbstractScope.java       |   30 +
 .../engine/subsystem/api/storage/ClusterScope.java |    2 +-
 .../engine/subsystem/api/storage/HostScope.java    |    2 +-
 .../engine/subsystem/api/storage/Scope.java        |    1 +
 .../api/storage/StoragePoolAllocator.java          |   45 +
 .../engine/subsystem/api/storage/ZoneScope.java    |    2 +-
 .../storage/datastore/db/PrimaryDataStoreDao.java  |  148 +-
 .../datastore/db/PrimaryDataStoreDaoImpl.java      |  544 ++--
 .../storage/datastore/db/StoragePoolDetailVO.java  |   81 +
 .../datastore/db/StoragePoolDetailsDao.java        |   28 +
 .../storage/datastore/db/StoragePoolVO.java        |    9 +-
 .../engine/subsystem/api/storage/ScopeTest.java    |   59 +
 .../engine/cloud/entity/api/VMEntityManager.java   |    5 +-
 .../cloud/entity/api/VMEntityManagerImpl.java      |    9 +-
 .../entity/api/VirtualMachineEntityFactory.java    |    3 +-
 .../cloud/entity/api/VirtualMachineEntityImpl.java |   15 +-
 .../cloud/entity/api/db/dao/VMEntityDaoImpl.java   |    8 +-
 .../entity/api/db/dao/VMReservationDaoImpl.java    |    2 +-
 .../platform/orchestration/CloudOrchestrator.java  |   32 +-
 .../image/store/DefaultImageDataStoreImpl.java     |    2 +-
 .../storage/image/store/TemplateObject.java        |    2 +-
 engine/storage/integration-test/pom.xml            |   23 +
 .../storage/allocator/StorageAllocatorTest.java    |  439 +++
 .../StorageAllocatorTestConfiguration.java         |   73 +
 .../storage/test/ChildTestConfiguration.java       |  182 +-
 .../storage/test/DirectAgentManagerSimpleImpl.java |    6 +
 .../cloudstack/storage/test/TestConfiguration.java |    8 -
 .../test/resource/StorageAllocatorTestContext.xml  |   45 +
 .../test/resource/storageContext.xml               |   48 +-
 .../storage/snapshot/SnapshotObject.java           |    2 +-
 .../snapshot/strategy/AncientSnasphotStrategy.java |    4 +-
 .../storage/HypervsiorHostEndPointRpcServer.java   |   10 +-
 .../allocator/AbstractStoragePoolAllocator.java    |  192 ++
 .../ClusterScopeStoragePoolAllocator.java          |  105 +
 .../GarbageCollectingStoragePoolAllocator.java     |   91 +
 .../allocator/LocalStoragePoolAllocator.java       |  126 +
 .../allocator/UseLocalForRootAllocator.java        |   61 +
 .../allocator/ZoneWideStoragePoolAllocator.java    |   80 +
 .../storage/db/ObjectInDataStoreDaoImpl.java       |    2 +
 .../storage/motion/AncientDataMotionStrategy.java  |   24 +-
 .../storage/volume/db/VolumeDao2Impl.java          |    5 +-
 .../storage/datastore/DefaultPrimaryDataStore.java |   13 +-
 .../AncientPrimaryDataStoreLifeCyclImpl.java       |  958 ------
 .../AncientPrimaryDataStoreLifeCycleImpl.java      |  963 ++++++
 .../AncientPrimaryDataStoreProviderImpl.java       |    4 +-
 .../storage/volume/VolumeEntityImpl.java           |    2 +-
 .../cloudstack/storage/volume/VolumeObject.java    |    2 +-
 .../storage/volume/VolumeServiceImpl.java          |    1 -
 .../cloudstack/framework/events/EventBus.java      |    4 +-
 framework/rest/pom.xml                             |    4 +
 packaging/centos63/cloud-agent.rc                  |   98 +-
 packaging/centos63/cloud-ipallocator.rc            |    2 +-
 packaging/centos63/cloud-usage.rc                  |    4 +-
 packaging/centos63/cloud.spec                      |   56 +-
 packaging/centos63/cloudstack-agent.te             |   33 +
 packaging/debian/init/cloud-agent                  |  171 +
 packaging/debian/init/cloud-management             |  244 ++
 packaging/debian/init/cloud-usage                  |  127 +
 packaging/debian/replace.properties                |   32 +-
 .../debian/config/etc/init.d/cloud-early-config    |   36 +-
 .../debian/config/opt/cloud/bin/vpc_guestnw.sh     |   12 +
 .../debian/config/opt/cloud/bin/vpc_ipassoc.sh     |   12 +
 patches/systemvm/debian/config/root/edithosts.sh   |   16 +-
 patches/systemvm/debian/config/root/func.sh        |    7 +-
 .../root/redundant_router/arping_gateways.sh.templ |    4 +-
 .../config/root/redundant_router/backup.sh.templ   |    1 +
 .../root/redundant_router/check_heartbeat.sh.templ |    2 +-
 plugins/alert-handlers/snmp-alerts/pom.xml         |   45 +
 .../cloudstack/alert/snmp/CsSnmpConstants.java     |   45 +
 .../alert/snmp/SnmpEnhancedPatternLayout.java      |  107 +
 .../apache/cloudstack/alert/snmp/SnmpHelper.java   |  106 +
 .../cloudstack/alert/snmp/SnmpTrapAppender.java    |  207 ++
 .../apache/cloudstack/alert/snmp/SnmpTrapInfo.java |   90 +
 .../alert/snmp/SnmpEnhancedPatternLayoutTest.java  |   90 +
 .../alert/snmp/SnmpTrapAppenderTest.java           |   86 +
 .../discovery/ApiDiscoveryServiceImpl.java         |    1 +
 .../command/admin/ratelimit/ResetApiLimitCmd.java  |    9 +
 .../api/command/user/ratelimit/GetApiLimitCmd.java |   11 +
 .../cloudstack/ratelimit/ApiRateLimitService.java  |    2 +
 .../ratelimit/ApiRateLimitServiceImpl.java         |   21 +-
 .../cloudstack/ratelimit/ApiRateLimitTest.java     |   25 +
 .../cloudstack/mom/rabbitmq/RabbitMQEventBus.java  |  111 +-
 .../BaremetalKickStartPxeResource.java             |    2 +-
 .../BaremetalKickStartServiceImpl.java             |   33 +-
 .../PrepareKickstartPxeServerCommand.java          |   31 +-
 plugins/hypervisors/kvm/pom.xml                    |   65 +-
 .../cloud/hypervisor/kvm/resource/KVMHABase.java   |    6 +-
 .../kvm/resource/LibvirtComputingResource.java     |  473 ++--
 .../hypervisor/kvm/resource/LibvirtVMDef.java      |   25 +
 .../hypervisor/kvm/resource/LibvirtXMLParser.java  |    8 +-
 .../kvm/storage/LibvirtStorageAdaptor.java         |  161 +-
 .../kvm/resource/LibvirtComputingResourceTest.java |  184 ++
 .../kvm/resource/LibvirtVifDriverTest.java         |  226 ++
 .../resource/SimulatorSecondaryDiscoverer.java     |    2 +-
 .../src/com/cloud/ucs/database/UcsBladeDao.java    |    5 +-
 .../com/cloud/ucs/database/UcsBladeDaoImpl.java    |   10 +-
 .../ucs/src/com/cloud/ucs/database/UcsBladeVO.java |   27 +-
 .../src/com/cloud/ucs/database/UcsManagerDao.java  |    5 +-
 .../com/cloud/ucs/database/UcsManagerDaoImpl.java  |   10 +-
 .../src/com/cloud/ucs/database/UcsManagerVO.java   |   12 +-
 .../com/cloud/ucs/manager/AddUcsManagerCmd.java    |   18 +-
 .../cloud/ucs/manager/AddUcsManagerResponse.java   |   69 -
 .../ucs/manager/AssociateUcsProfileToBladeCmd.java |   18 +-
 ...sociateUcsProfileToBladesInClusterResponse.java |   22 -
 .../src/com/cloud/ucs/manager/ListUcsBladeCmd.java |   87 +
 .../com/cloud/ucs/manager/ListUcsManagerCmd.java   |   20 +-
 .../cloud/ucs/manager/ListUcsManagerResponse.java  |   58 -
 .../com/cloud/ucs/manager/ListUcsProfileCmd.java   |   16 +-
 .../cloud/ucs/manager/ListUcsProfileResponse.java  |   36 -
 .../src/com/cloud/ucs/manager/StringTemplate.java  |    5 +-
 .../com/cloud/ucs/manager/UcsBladeResponse.java    |   84 +
 .../ucs/src/com/cloud/ucs/manager/UcsCommands.java |    7 +-
 .../src/com/cloud/ucs/manager/UcsHttpClient.java   |   12 +-
 .../ucs/src/com/cloud/ucs/manager/UcsManager.java  |   18 +-
 .../src/com/cloud/ucs/manager/UcsManagerImpl.java  |  146 +-
 .../com/cloud/ucs/manager/UcsManagerResponse.java  |   73 +
 .../com/cloud/ucs/manager/UcsProfileResponse.java  |   37 +
 .../src/com/cloud/ucs/structure/ComputeBlade.java  |    7 +-
 .../src/com/cloud/ucs/structure/UcsProfile.java    |    9 +-
 plugins/hypervisors/vmware/pom.xml                 |   12 -
 .../hypervisor/vmware/VmwareServerDiscoverer.java  |  355 ++-
 .../hypervisor/vmware/manager/VmwareManager.java   |    6 -
 .../vmware/manager/VmwareManagerImpl.java          |  159 +-
 .../vmware/manager/VmwareStorageManagerImpl.java   |  366 ++--
 .../vmware/resource/VmwareContextFactory.java      |   12 +-
 .../hypervisor/vmware/resource/VmwareResource.java |  366 ++-
 .../src/com/cloud/network/VmwareTrafficLabel.java  |  118 +
 .../VmwareSecondaryStorageContextFactory.java      |   31 +-
 .../VmwareSecondaryStorageResourceHandler.java     |   18 +-
 .../xen/discoverer/XcpServerDiscoverer.java        |   10 +-
 .../hypervisor/xen/resource/CitrixHelper.java      |   41 +-
 .../xen/resource/CitrixResourceBase.java           |   43 +-
 .../xen/resource/XenServer610Resource.java         |    2 +-
 .../dns-notifier/resources/components-example.xml  |    2 +
 .../element/ElasticLoadBalancerElement.java        |    7 +
 .../network/lb/ElasticLoadBalancerManagerImpl.java |    9 +-
 .../element/F5ExternalLoadBalancerElement.java     |    8 +
 .../cloud/network/element/NetscalerElement.java    |   32 +-
 .../cloud/network/resource/NetscalerResource.java  |  291 ++-
 plugins/pom.xml                                    |    1 +
 plugins/storage-allocators/random/pom.xml          |   10 +-
 .../allocator/RandomStoragePoolAllocator.java      |   91 -
 .../allocator/RandomStoragePoolAllocator.java      |   78 +
 pom.xml                                            |  374 +--
 scripts/network/domr/dhcp_entry.sh                 |    6 +-
 .../ping/prepare_kickstart_kernel_initrd.py        |   55 +-
 scripts/storage/qcow2/resizevolume.sh              |    4 +-
 scripts/vm/hypervisor/kvm/patchviasocket.pl        |   58 +
 scripts/vm/hypervisor/kvm/rundomrpre.sh            |  147 -
 scripts/vm/hypervisor/xenserver/vmops              |  199 ++-
 scripts/vm/hypervisor/xenserver/vmopsSnapshot      |   29 +-
 .../vm/hypervisor/xenserver/xcposs/vmopsSnapshot   |   27 +-
 scripts/vm/hypervisor/xenserver/xenheartbeat.sh    |   33 +-
 scripts/vm/network/security_group.py               |  185 +-
 server/conf/cloudstack-limits.conf.in              |   21 +
 server/conf/cloudstack-sudoers.in                  |   22 +
 server/pom.xml                                     |   65 +-
 server/src/com/cloud/agent/AgentManager.java       |    2 +
 .../com/cloud/agent/manager/AgentManagerImpl.java  |   10 +-
 .../src/com/cloud/agent/manager/AgentMonitor.java  |    9 +-
 .../cloud/agent/manager/AgentMonitorService.java   |   28 +
 .../allocator/impl/RecreateHostAllocator.java      |    4 +-
 server/src/com/cloud/alert/AlertManagerImpl.java   |    6 +
 server/src/com/cloud/alert/dao/AlertDao.java       |    7 +
 server/src/com/cloud/alert/dao/AlertDaoImpl.java   |   85 +
 server/src/com/cloud/api/ApiDBUtils.java           |   15 +-
 server/src/com/cloud/api/ApiDispatcher.java        |   34 +-
 server/src/com/cloud/api/ApiResponseHelper.java    |  121 +
 server/src/com/cloud/api/ApiServer.java            |   64 +-
 server/src/com/cloud/api/ApiServerService.java     |   37 +
 server/src/com/cloud/api/ApiServlet.java           |    2 +-
 .../src/com/cloud/api/query/QueryManagerImpl.java  |   20 +-
 .../api/query/dao/DomainRouterJoinDaoImpl.java     |   23 +
 .../query/dao/ProjectInvitationJoinDaoImpl.java    |    4 +-
 .../api/query/dao/UserAccountJoinDaoImpl.java      |    9 +-
 .../com/cloud/api/query/dao/UserVmJoinDaoImpl.java |    2 +
 server/src/com/cloud/api/query/vo/EventJoinVO.java |    9 +
 .../api/query/vo/ProjectInvitationJoinVO.java      |    3 +-
 .../src/com/cloud/api/query/vo/UserVmJoinVO.java   |   13 +
 .../cloud/baremetal/BareMetalTemplateAdapter.java  |  218 --
 .../com/cloud/capacity/dao/CapacityDaoImpl.java    |   15 +-
 .../src/com/cloud/cluster/ClusterManagerImpl.java  |    5 +-
 .../agentlb/dao/HostTransferMapDaoImpl.java        |   50 +-
 server/src/com/cloud/configuration/Config.java     |   18 +-
 .../configuration/ConfigurationManagerImpl.java    |   19 +-
 .../configuration/dao/ConfigurationDaoImpl.java    |    9 -
 .../configuration/dao/ResourceCountDaoImpl.java    |    9 +-
 .../consoleproxy/ConsoleProxyManagerImpl.java      |    4 +-
 server/src/com/cloud/dc/dao/DataCenterDaoImpl.java |   10 +-
 .../com/cloud/dc/dao/DataCenterIpAddressDao.java   |    6 +
 .../dc/dao/DataCenterLinkLocalIpAddressDao.java    |   32 +
 .../dao/DataCenterLinkLocalIpAddressDaoImpl.java   |    2 +-
 server/src/com/cloud/dc/dao/DataCenterVnetDao.java |   38 +
 .../com/cloud/dc/dao/DataCenterVnetDaoImpl.java    |    2 +-
 server/src/com/cloud/dc/dao/PodVlanDao.java        |   30 +
 server/src/com/cloud/dc/dao/PodVlanDaoImpl.java    |    2 +-
 .../deploy/AbstractDeployPlannerSelector.java      |   14 +-
 server/src/com/cloud/deploy/FirstFitPlanner.java   |   15 +-
 .../cloud/deploy/HypervisorVmPlannerSelector.java  |   23 +-
 server/src/com/cloud/domain/DomainVO.java          |   16 +-
 .../com/cloud/event/ActionEventInterceptor.java    |   15 +-
 server/src/com/cloud/event/ActionEventUtils.java   |   19 +-
 server/src/com/cloud/event/AlertGenerator.java     |   21 +-
 server/src/com/cloud/event/UsageEventUtils.java    |   21 +-
 server/src/com/cloud/ha/RecreatableFencer.java     |    8 +-
 server/src/com/cloud/host/dao/HostDaoImpl.java     |    5 +
 .../com/cloud/hypervisor/HypervisorGuruBase.java   |   12 +-
 .../network/ExternalLoadBalancerDeviceManager.java |    7 +-
 .../ExternalLoadBalancerDeviceManagerImpl.java     |  107 +-
 .../ExternalLoadBalancerUsageManagerImpl.java      |  263 ++-
 .../com/cloud/network/LBHealthCheckPolicyVO.java   |  157 +
 server/src/com/cloud/network/NetworkManager.java   |   15 +
 .../src/com/cloud/network/NetworkManagerImpl.java  |  191 +-
 server/src/com/cloud/network/NetworkModelImpl.java |   53 +-
 .../src/com/cloud/network/NetworkServiceImpl.java  |  267 ++-
 .../com/cloud/network/NetworkStateListener.java    |   13 +-
 server/src/com/cloud/network/addr/PublicIp.java    |   38 +-
 .../cloud/network/dao/FirewallRulesDaoImpl.java    |    5 +-
 server/src/com/cloud/network/dao/IPAddressDao.java |    9 +-
 .../com/cloud/network/dao/IPAddressDaoImpl.java    |   31 +-
 server/src/com/cloud/network/dao/IPAddressVO.java  |   16 +-
 .../cloud/network/dao/LBHealthCheckPolicyDao.java  |   35 +
 .../network/dao/LBHealthCheckPolicyDaoImpl.java    |   71 +
 .../com/cloud/network/dao/LoadBalancerDaoImpl.java |    2 +-
 .../com/cloud/network/dao/LoadBalancerVMMapVO.java |   16 +-
 .../com/cloud/network/dao/NetworkAccountDao.java   |   22 +
 .../cloud/network/dao/NetworkAccountDaoImpl.java   |    2 +-
 .../src/com/cloud/network/dao/NetworkDaoImpl.java  |   20 +-
 server/src/com/cloud/network/dao/NetworkOpDao.java |   26 +
 .../com/cloud/network/dao/NetworkOpDaoImpl.java    |    2 +-
 .../cloud/network/dao/PhysicalNetworkDaoImpl.java  |    2 +-
 .../com/cloud/network/dao/RouterNetworkDao.java    |   26 +
 .../cloud/network/dao/RouterNetworkDaoImpl.java    |    2 +-
 .../network/dao/Site2SiteVpnConnectionDaoImpl.java |    4 +-
 .../network/dao/Site2SiteVpnGatewayDaoImpl.java    |    2 +-
 .../network/element/VirtualRouterElement.java      |   10 +-
 .../com/cloud/network/guru/DirectNetworkGuru.java  |   18 +-
 .../com/cloud/network/guru/GuestNetworkGuru.java   |    2 -
 .../com/cloud/network/lb/LBHealthCheckManager.java |   24 +
 .../cloud/network/lb/LBHealthCheckManagerImpl.java |  110 +
 .../network/lb/LoadBalancingRulesManager.java      |    2 +
 .../network/lb/LoadBalancingRulesManagerImpl.java  |  678 ++++-
 .../router/VirtualNetworkApplianceManagerImpl.java |   86 +-
 .../VpcVirtualNetworkApplianceManagerImpl.java     |   35 +-
 .../com/cloud/network/rules/RulesManagerImpl.java  |  113 +-
 .../network/rules/dao/PortForwardingRulesDao.java  |    2 +
 .../rules/dao/PortForwardingRulesDaoImpl.java      |   11 +-
 .../network/security/SecurityGroupManagerImpl.java |   93 +-
 .../security/SecurityGroupManagerImpl2.java        |   13 +-
 .../network/security/dao/SecurityGroupDaoImpl.java |    3 +-
 .../src/com/cloud/network/vpc/VpcManagerImpl.java  |    4 +-
 .../cloud/network/vpc/dao/StaticRouteDaoImpl.java  |    3 +-
 .../src/com/cloud/network/vpc/dao/VpcDaoImpl.java  |    7 +-
 .../network/vpn/RemoteAccessVpnManagerImpl.java    |    4 +-
 .../src/com/cloud/projects/ProjectManagerImpl.java |    3 +-
 .../src/com/cloud/projects/dao/ProjectDaoImpl.java |    3 +-
 server/src/com/cloud/resource/ResourceManager.java |    1 +
 .../com/cloud/resource/ResourceManagerImpl.java    |   29 +-
 .../resourcelimit/ResourceLimitManagerImpl.java    |    2 +-
 .../com/cloud/server/ConfigurationServerImpl.java  |   79 +-
 .../src/com/cloud/server/ManagementServerImpl.java |  143 +-
 .../server/auth/DefaultUserAuthenticator.java      |    3 -
 .../src/com/cloud/servlet/CloudStartupServlet.java |   17 +-
 .../cloud/storage/LocalStoragePoolListener.java    |    4 +-
 server/src/com/cloud/storage/OCFS2ManagerImpl.java |    4 +-
 .../src/com/cloud/storage/StorageManagerImpl.java  |   88 +-
 .../src/com/cloud/storage/VolumeManagerImpl.java   |   85 +-
 .../allocator/AbstractStoragePoolAllocator.java    |  209 --
 .../allocator/FirstFitStoragePoolAllocator.java    |  175 -
 .../GarbageCollectingStoragePoolAllocator.java     |  105 -
 .../allocator/LocalStoragePoolAllocator.java       |  288 --
 .../storage/allocator/StoragePoolAllocator.java    |   53 -
 .../allocator/UseLocalForRootAllocator.java        |   83 -
 .../src/com/cloud/storage/dao/SnapshotDaoImpl.java |   12 +-
 .../src/com/cloud/storage/dao/StoragePoolDao.java  |  107 -
 .../com/cloud/storage/dao/StoragePoolDaoImpl.java  |  377 ---
 .../cloud/storage/dao/StoragePoolDetailsDao.java   |   28 -
 .../storage/dao/StoragePoolDetailsDaoImpl.java     |    3 +-
 .../com/cloud/storage/dao/VMTemplateDaoImpl.java   |  161 +-
 .../src/com/cloud/storage/dao/VolumeDaoImpl.java   |    4 +-
 .../cloud/storage/download/DownloadListener.java   |    8 +-
 .../storage/download/DownloadMonitorImpl.java      |   22 +-
 .../storage/listener/SnapshotStateListener.java    |   18 +-
 .../cloud/storage/listener/StoragePoolMonitor.java |    4 +-
 .../storage/listener/VolumeStateListener.java      |   15 +-
 .../storage/snapshot/SnapshotManagerImpl.java      |    4 +-
 .../cloud/template/HyervisorTemplateAdapter.java   |  340 --
 .../cloud/template/HypervisorTemplateAdapter.java  |  339 ++
 .../com/cloud/template/TemplateManagerImpl.java    |    4 +-
 .../com/cloud/upgrade/DatabaseUpgradeChecker.java  |    4 +
 .../src/com/cloud/upgrade/dao/Upgrade40to41.java   |   78 +-
 .../src/com/cloud/upgrade/dao/Upgrade410to420.java |   88 +-
 server/src/com/cloud/user/AccountManager.java      |    4 +-
 server/src/com/cloud/user/AccountManagerImpl.java  |  133 +-
 server/src/com/cloud/user/DomainManager.java       |    2 +-
 server/src/com/cloud/user/DomainManagerImpl.java   |   47 +-
 .../com/cloud/user/dao/UserStatisticsDaoImpl.java  |   18 +-
 server/src/com/cloud/vm/NicVO.java                 |   11 +
 server/src/com/cloud/vm/UserVmManagerImpl.java     |   39 +-
 server/src/com/cloud/vm/UserVmStateListener.java   |   17 +-
 .../com/cloud/vm/VirtualMachineManagerImpl.java    |    5 +-
 .../src/com/cloud/vm/dao/DomainRouterDaoImpl.java  |   12 +-
 server/src/com/cloud/vm/dao/NicDao.java            |    4 +
 server/src/com/cloud/vm/dao/NicDaoImpl.java        |   21 +-
 server/src/com/cloud/vm/dao/NicSecondaryIpDao.java |   53 +
 .../com/cloud/vm/dao/NicSecondaryIpDaoImpl.java    |  138 +
 server/src/com/cloud/vm/dao/NicSecondaryIpVO.java  |  160 +
 .../dao/RandomlyIncreasingVMInstanceDaoImpl.java   |   36 -
 server/src/com/cloud/vm/dao/UserVmDaoImpl.java     |    3 +-
 server/src/com/cloud/vm/dao/UserVmDetailsDao.java  |    3 -
 .../cloud/vm/snapshot/VMSnapshotManagerImpl.java   |    4 +-
 .../apache/cloudstack/region/RegionManager.java    |  192 +-
 .../cloudstack/region/RegionManagerImpl.java       |  897 +-----
 .../cloudstack/region/RegionServiceImpl.java       |  270 +--
 .../src/org/apache/cloudstack/region/RegionVO.java |   27 +-
 .../apache/cloudstack/region/RegionsApiUtil.java   |  478 ++--
 .../cloudstack/region/dao/RegionSyncDao.java       |   24 -
 .../cloudstack/region/dao/RegionSyncDaoImpl.java   |   35 -
 .../test/com/cloud/agent/MockAgentManagerImpl.java |    6 +
 .../com/cloud/alert/AlertControlsUnitTest.java     |   83 +
 .../com/cloud/event/EventControlsUnitTest.java     |   84 +
 .../com/cloud/network/MockNetworkManagerImpl.java  |   57 +
 .../com/cloud/network/MockNetworkModelImpl.java    |    6 +
 .../com/cloud/network/MockRulesManagerImpl.java    |   19 +-
 .../cloud/resource/MockResourceManagerImpl.java    |    7 +
 .../com/cloud/storage/dao/StoragePoolDaoTest.java  |    3 +-
 .../dao/StoragePoolDaoTestConfiguration.java       |    3 +-
 server/test/com/cloud/upgrade/DbUpgrade22Test.java |    2 +
 .../com/cloud/user/MockAccountManagerImpl.java     |   48 +-
 .../test/com/cloud/user/MockDomainManagerImpl.java |   38 +-
 .../UserVmCloneSettingDaoTestConfiguration.java    |    2 +-
 .../cloud/vm/snapshot/VMSnapshotManagerTest.java   |    4 +-
 .../test/com/cloud/vpc/MockNetworkManagerImpl.java |   94 +
 .../test/com/cloud/vpc/MockNetworkModelImpl.java   |    6 +
 .../cloudstack/region/RegionManagerTest.java       |   17 +-
 .../src/com/cloud/consoleproxy/ConsoleProxy.java   |   29 +-
 .../ConsoleProxyHttpHandlerHelper.java             |   18 +-
 setup/bindir/cloud-setup-databases.in              |    5 +-
 setup/db/db/schema-40to410.sql                     |   95 +-
 setup/db/db/schema-410to420.sql                    |   95 +-
 test/integration/component/test_accounts.py        |    5 +-
 .../component/test_allocation_states.py            |    5 +-
 test/integration/component/test_blocker_bugs.py    |   14 +-
 test/integration/component/test_egress_rules.py    |   24 +-
 test/integration/component/test_eip_elb.py         |    6 +-
 .../integration/component/test_network_offering.py |   10 +-
 test/integration/component/test_project_configs.py |    4 +-
 test/integration/component/test_project_limits.py  |    8 +-
 .../component/test_project_resources.py            |   16 +-
 test/integration/component/test_project_usage.py   |   24 +-
 test/integration/component/test_projects.py        |    4 +-
 test/integration/component/test_resource_limits.py |   10 +-
 test/integration/component/test_routers.py         |   10 +-
 test/integration/component/test_security_groups.py |   16 +-
 test/integration/component/test_templates.py       |    8 +-
 test/integration/component/test_usage.py           |   24 +-
 test/integration/component/test_volumes.py         |   16 +-
 test/integration/smoke/test_iso.py                 |    4 +-
 test/integration/smoke/test_nic.py                 |    2 +-
 test/integration/smoke/test_vm_life_cycle.py       |    2 +-
 tools/apidoc/gen_toc.py                            |    4 +
 tools/apidoc/generateadmincommands.xsl             |    8 +
 tools/appliance/README.md                          |    8 +-
 tools/appliance/build.sh                           |   61 +-
 .../appliance/definitions/systemvmtemplate/base.sh |    6 +-
 .../definitions/systemvmtemplate/cleanup.sh        |    2 +
 .../definitions/systemvmtemplate/definition.rb     |    8 +-
 .../definitions/systemvmtemplate/postinstall.sh    |  130 +-
 .../definitions/systemvmtemplate/preseed.cfg       |    8 +-
 .../definitions/systemvmtemplate/zerodisk.sh       |   18 +-
 .../definitions/systemvmtemplate64/base.sh         |   25 +
 .../definitions/systemvmtemplate64/cleanup.sh      |   21 +
 .../definitions/systemvmtemplate64/definition.rb   |   45 +
 .../definitions/systemvmtemplate64/postinstall.sh  |  220 ++
 .../definitions/systemvmtemplate64/preseed.cfg     |  357 +++
 .../definitions/systemvmtemplate64/zerodisk.sh     |   15 +
 tools/cli/cloudmonkey/__init__.py                  |    4 +-
 tools/cli/cloudmonkey/cachemaker.py                |    9 +-
 tools/cli/cloudmonkey/cloudmonkey.py               |   57 +-
 tools/cli/cloudmonkey/config.py                    |   21 +-
 tools/cli/setup.py                                 |   34 +-
 tools/eclipse/set-eclipse-profile.sh               |   26 +
 tools/marvin/marvin/codegenerator.py               |   31 +-
 .../marvin/sandbox/demo/simulator/simulator.cfg    |    4 +-
 tools/marvin/pom.xml                               |  219 +-
 ui/css/cloudstack3.css                             |  505 +++-
 ui/dictionary.jsp                                  |    8 +
 ui/images/bg-what-is-cloudstack.png                |  Bin 32240 -> 36116 bytes
 ui/images/logo-login-oss.png                       |  Bin 2534 -> 4567 bytes
 ui/images/logo.png                                 |  Bin 3778 -> 3886 bytes
 ui/images/sprites.png                              |  Bin 182811 -> 188552 bytes
 ui/index.jsp                                       |    3 +
 ui/scripts/accounts.js                             |   32 +-
 ui/scripts/cloudStack.js                           |    5 +-
 ui/scripts/dashboard.js                            |   75 +-
 ui/scripts/docs.js                                 |   95 +
 ui/scripts/events.js                               |  314 ++
 ui/scripts/globalSettings.js                       |   12 +-
 ui/scripts/installWizard.js                        |    4 +-
 ui/scripts/instanceWizard.js                       |   14 +-
 ui/scripts/instances.js                            |    9 +
 ui/scripts/network.js                              |  658 ++---
 ui/scripts/regions.js                              |  178 ++
 ui/scripts/sharedFunctions.js                      |   36 +-
 ui/scripts/system.js                               |  434 +++-
 ui/scripts/ui-custom/dashboard.js                  |    8 +-
 ui/scripts/ui-custom/enableStaticNAT.js            |    3 +-
 ui/scripts/ui-custom/healthCheck.js                |  342 ++
 ui/scripts/ui-custom/installWizard.js              |    4 +-
 ui/scripts/ui-custom/instanceWizard.js             |   27 +-
 ui/scripts/ui-custom/regions.js                    |  123 +
 ui/scripts/ui/core.js                              |    4 +
 ui/scripts/ui/widgets/detailView.js                |   37 +-
 ui/scripts/ui/widgets/listView.js                  |   58 +-
 ui/scripts/ui/widgets/multiEdit.js                 |   20 +-
 ui/scripts/ui/widgets/toolTip.js                   |    2 +-
 ui/scripts/vpc.js                                  |    7 +
 ui/scripts/zoneWizard.js                           |  227 ++-
 usage/conf/db.properties.in                        |   29 +
 usage/pom.xml                                      |    6 +-
 .../src/com/cloud/usage/UsageAlertManagerImpl.java |   13 +-
 usage/src/com/cloud/usage/UsageManagerImpl.java    |    2 +-
 utils/src/com/cloud/utils/LogUtils.java            |    3 +-
 .../src/com/cloud/utils/component/AdapterBase.java |    6 +-
 .../cloud/utils/component/ComponentContext.java    |   66 +-
 .../utils/component/ComponentMethodProxyCache.java |   90 +
 .../utils/component/SpringComponentScanUtils.java  |    1 -
 utils/src/com/cloud/utils/db/GenericDao.java       |    2 +
 utils/src/com/cloud/utils/db/GenericDaoBase.java   |   46 +-
 utils/src/com/cloud/utils/db/QueryBuilder.java     |   20 +-
 utils/src/com/cloud/utils/db/Transaction.java      |    2 +-
 .../cloud/utils/db/TransactionContextBuilder.java  |   19 +-
 utils/src/com/cloud/utils/net/NetUtils.java        |    2 +-
 utils/src/com/cloud/utils/xmlobject/XmlObject.java |    5 +-
 .../utils/log/CglibThrowableRendererTest.java      |    6 +-
 vmware-base/pom.xml                                |   12 -
 .../src/com/cloud/hypervisor/vmware/mo/BaseMO.java |   74 +-
 .../com/cloud/hypervisor/vmware/mo/ClusterMO.java  |  318 +-
 .../vmware/mo/CustomFieldsManagerMO.java           |   32 +-
 .../cloud/hypervisor/vmware/mo/DatacenterMO.java   |  332 +-
 .../cloud/hypervisor/vmware/mo/DatastoreMO.java    |  186 +-
 .../vmware/mo/DistributedVirtualSwitchMO.java      |   49 +
 .../vmware/mo/HostDatastoreBrowserMO.java          |   58 +-
 .../vmware/mo/HostDatastoreSystemMO.java           |   92 +-
 .../hypervisor/vmware/mo/HostFirewallSystemMO.java |   14 +-
 .../src/com/cloud/hypervisor/vmware/mo/HostMO.java |  486 ++--
 .../cloud/hypervisor/vmware/mo/HttpNfcLeaseMO.java |  109 +-
 .../hypervisor/vmware/mo/HypervisorHostHelper.java |  483 ++-
 .../com/cloud/hypervisor/vmware/mo/NetworkMO.java  |   15 +-
 .../cloud/hypervisor/vmware/mo/PerfManagerMO.java  |   85 +-
 .../src/com/cloud/hypervisor/vmware/mo/TaskMO.java |   24 +-
 .../hypervisor/vmware/mo/VirtualDiskManagerMO.java |  126 +-
 .../hypervisor/vmware/mo/VirtualMachineMO.java     | 1276 ++++----
 .../hypervisor/vmware/mo/VirtualSwitchType.java    |   35 +-
 .../cloud/hypervisor/vmware/util/VmwareClient.java |  580 ++++
 .../hypervisor/vmware/util/VmwareContext.java      |  364 ++--
 .../vmware/util/VmwareGuestOsMapper.java           |  282 +-
 .../cloud/hypervisor/vmware/util/VmwareHelper.java |  273 +-
 .../vmware/mo/TestVmwareContextFactory.java        |   14 +-
 .../cloud/hypervisor/vmware/mo/TestVmwareMO.java   |    1 -
 vmware-base/test/com/cloud/vmware/TestVMWare.java  |  240 ++-
 679 files changed, 27489 insertions(+), 15116 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/api/src/com/cloud/network/Network.java
----------------------------------------------------------------------
diff --cc api/src/com/cloud/network/Network.java
index fa36d27,89dac68..de452ac
--- a/api/src/com/cloud/network/Network.java
+++ b/api/src/com/cloud/network/Network.java
@@@ -138,8 -138,6 +138,7 @@@ public interface Network extends Contro
          // NiciraNvp is not an "External" provider, otherwise we get in trouble with NetworkServiceImpl.providersConfiguredForExternalNetworking 
          public static final Provider NiciraNvp = new Provider("NiciraNvp", false);  
          public static final Provider MidokuraMidonet = new Provider("MidokuraMidonet", true);
-         public static final Provider VPCNetscaler = new Provider("VPCNetscaler", true);
 +        public static final Provider CiscoVnmc = new Provider("CiscoVnmc", true);
  
          private String name;
          private boolean isExternal;

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/api/src/org/apache/cloudstack/api/ApiConstants.java
----------------------------------------------------------------------
diff --cc api/src/org/apache/cloudstack/api/ApiConstants.java
index 4d6099b,f4c6c52..2901db1
--- a/api/src/org/apache/cloudstack/api/ApiConstants.java
+++ b/api/src/org/apache/cloudstack/api/ApiConstants.java
@@@ -452,8 -454,18 +454,20 @@@ public class ApiConstants 
      public static final String GUEST_VM_CIDR = "guestvmcidr";
      public static final String NETWORK_CIDR = "networkcidr";
      public static final String RESERVED_IP_RANGE = "reservediprange";
+     public static final String UCS_MANAGER_ID = "ucsmanagerid";
+     public static final String UCS_PROFILE_DN = "profiledn";
+     public static final String UCS_BLADE_DN = "bladedn";
+     public static final String UCS_BLADE_ID = "bladeid";
+     public static final String VM_GUEST_IP = "vmguestip";
+     public static final String OLDER_THAN = "olderthan";
+     public static final String HEALTHCHECK_RESPONSE_TIMEOUT = "responsetimeout";
+     public static final String HEALTHCHECK_INTERVAL_TIME = "intervaltime";
+     public static final String HEALTHCHECK_HEALTHY_THRESHOLD = "healthythreshold";
+     public static final String HEALTHCHECK_UNHEALTHY_THRESHOLD = "unhealthythreshold";
+     public static final String HEALTHCHECK_PINGPATH = "pingpath";
 +    public static final String ASA_INSIDE_PORT_PROFILE = "insideportprofile";
 +
+ 
      public enum HostDetails {
          all, capacity, events, stats, min;
      }

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/client/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/client/tomcatconf/commands.properties.in
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/client/tomcatconf/nonossComponentContext.xml.in
----------------------------------------------------------------------
diff --cc client/tomcatconf/nonossComponentContext.xml.in
index e638b2c,8f8dae5..5f543fb
--- a/client/tomcatconf/nonossComponentContext.xml.in
+++ b/client/tomcatconf/nonossComponentContext.xml.in
@@@ -37,9 -37,25 +37,26 @@@
    -->
    <bean id="premiumDatabaseUpgradeChecker" class="com.cloud.upgrade.PremiumDatabaseUpgradeChecker"/>
    
-   <bean id="managementServerImpl" class ="com.cloud.server.ManagementServerImpl" />
    <bean id="configurationServerImpl" class="com.cloud.server.ConfigurationServerImpl" />
-   
++
+   <bean id="managementServerImpl" class ="com.cloud.server.ManagementServerImpl" >
+     <property name="UserAuthenticators">
+         <list>
+             <ref bean="MD5UserAuthenticator"/>
+             <ref bean="LDAPUserAuthenticator"/>
+         </list>
+     </property>
+   </bean>
+  
+   <bean id ="AccountManagerImpl" class="com.cloud.user.AccountManagerImpl">
+     <property name="UserAuthenticators">
+         <list>
+             <ref bean="MD5UserAuthenticator"/>
+             <ref bean="LDAPUserAuthenticator"/>
+         </list>
+     </property>
+   </bean>
+    
    <bean id="clusterManagerImpl" class="com.cloud.cluster.ClusterManagerImpl" />
    <bean id="clusteredAgentManagerImpl" class="com.cloud.agent.manager.ClusteredAgentManagerImpl" />
    <bean id="clusteredVirtualMachineManagerImpl" class="com.cloud.vm.ClusteredVirtualMachineManagerImpl" />

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
----------------------------------------------------------------------
diff --cc plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
index 2646f13,9d29abf..dbd104e
--- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
+++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/manager/VmwareManagerImpl.java
@@@ -368,14 -317,10 +317,9 @@@ public class VmwareManagerImpl extends 
          }
  
          s_logger.info("Preparing network on host " + hostMo.getContext().toString() + " for " + privateTrafficLabel);
-         if(!_nexusVSwitchActive) {
--            HypervisorHostHelper.prepareNetwork(vSwitchName, "cloud.private", hostMo, vlanId, null, null, 180000, false);
-         }
-         else {
-             HypervisorHostHelper.prepareNetwork(vSwitchName, "cloud.private", hostMo, vlanId, false, null, null, 180000);
-         }
 -
++        HypervisorHostHelper.prepareNetwork(vSwitchName, "cloud.private", hostMo, vlanId, null, null, 180000, false);
      }
-     
+ 
      @Override
      public List<ManagedObjectReference> addHostToPodCluster(VmwareContext serviceContext, long dcId, Long podId, Long clusterId,
              String hostInventoryPath) throws Exception {

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java
----------------------------------------------------------------------
diff --cc plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java
index 22e59d3,634827b..d53fe64
--- a/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java
+++ b/plugins/hypervisors/vmware/src/com/cloud/hypervisor/vmware/resource/VmwareResource.java
@@@ -1319,8 -1328,8 +1328,8 @@@ public class VmwareResource implements 
  
              NicTO nicTo = cmd.getNic();
              VirtualDevice nic;
 -            Pair<ManagedObjectReference, String> networkInfo = prepareNetworkFromNicInfo(vmMo.getRunningHost(), nicTo);
 +            Pair<ManagedObjectReference, String> networkInfo = prepareNetworkFromNicInfo(vmMo.getRunningHost(), nicTo, false);
-             if (mgr.getNexusVSwitchGlobalParameter()) {
+             if (VmwareHelper.isDvPortGroup(networkInfo.first())) {
                  String dvSwitchUuid;
                  ManagedObjectReference dcMor = hyperHost.getHyperHostDatacenter();
                  DatacenterMO dataCenterMo = new DatacenterMO(context, dcMor);
@@@ -1551,13 -1561,16 +1561,16 @@@
      private void plugPublicNic(VirtualMachineMO vmMo, final String vlanId, final String vifMacAddress) throws Exception {
          // TODO : probably need to set traffic shaping
          Pair<ManagedObjectReference, String> networkInfo = null;
- 
-         if (!_nexusVSwitch) {
-             networkInfo = HypervisorHostHelper.prepareNetwork(this._publicNetworkVSwitchName, "cloud.public",
+         VirtualSwitchType vSwitchType = VirtualSwitchType.StandardVirtualSwitch;
+         if (_publicTrafficInfo != null) {
+             vSwitchType = _publicTrafficInfo.getVirtualSwitchType();
+         }
+         if (VirtualSwitchType.StandardVirtualSwitch == vSwitchType) {
+             networkInfo = HypervisorHostHelper.prepareNetwork(this._publicTrafficInfo.getVirtualSwitchName(), "cloud.public",
                      vmMo.getRunningHost(), vlanId, null, null, this._ops_timeout, true);
          } else {
-             networkInfo = HypervisorHostHelper.prepareNetwork(this._publicNetworkVSwitchName, "cloud.public",
-                     vmMo.getRunningHost(), vlanId, false, null, null, this._ops_timeout);
+             networkInfo = HypervisorHostHelper.prepareNetwork(this._publicTrafficInfo.getVirtualSwitchName(), "cloud.public",
 -                    vmMo.getRunningHost(), vlanId, null, null, this._ops_timeout, vSwitchType, _portsPerDvPortGroup);
++                    vmMo.getRunningHost(), vlanId, false, null, null, this._ops_timeout, vSwitchType, _portsPerDvPortGroup);
          }
  
          int nicIndex = allocPublicNicIndex(vmMo);
@@@ -2265,9 -2286,8 +2286,9 @@@
              for (NicTO nicTo : sortNicsByDeviceId(nics)) {
                  s_logger.info("Prepare NIC device based on NicTO: " + _gson.toJson(nicTo));
  
 -                Pair<ManagedObjectReference, String> networkInfo = prepareNetworkFromNicInfo(vmMo.getRunningHost(), nicTo);
 +                boolean configureVServiceInNexus = (nicTo.getType() == TrafficType.Guest) && (vmSpec.getDetails().containsKey("ConfigureVServiceInNexus"));
 +                Pair<ManagedObjectReference, String> networkInfo = prepareNetworkFromNicInfo(vmMo.getRunningHost(), nicTo, configureVServiceInNexus);
-                 if (mgr.getNexusVSwitchGlobalParameter()) {
+                 if (VmwareHelper.isDvPortGroup(networkInfo.first())) {
                      String dvSwitchUuid;
                      ManagedObjectReference dcMor = hyperHost.getHyperHostDatacenter();
                      DatacenterMO dataCenterMo = new DatacenterMO(context, dcMor);
@@@ -2465,9 -2486,24 +2487,24 @@@
          return defaultVlan;
      }
  
 -    private Pair<ManagedObjectReference, String> prepareNetworkFromNicInfo(HostMO hostMo, NicTO nicTo) throws Exception {
 +    private Pair<ManagedObjectReference, String> prepareNetworkFromNicInfo(HostMO hostMo, NicTO nicTo, boolean configureVServiceInNexus) throws Exception {
+         Pair<String, String> switchName;
+         TrafficType trafficType;
+         VirtualSwitchType switchType;
+ 
+         switchName = getTargetSwitch(nicTo);
+         trafficType = nicTo.getType();
+         // Get switch type from resource property which is dictated by cluster property
+         // If a virtual switch type is specified while adding cluster that will be used.
+         // Else If virtual switch type is specified in physical traffic label that will be used
+         // Else use standard vSwitch
+         switchType = VirtualSwitchType.StandardVirtualSwitch;
+         if (trafficType == TrafficType.Guest && _guestTrafficInfo != null) {
+             switchType = _guestTrafficInfo.getVirtualSwitchType();
+         } else if (trafficType == TrafficType.Public && _publicTrafficInfo != null) {
+             switchType = _publicTrafficInfo.getVirtualSwitchType();
+         }
  
-         Pair<String, String> switchName = getTargetSwitch(nicTo);
          String namePrefix = getNetworkNamePrefix(nicTo);
          Pair<ManagedObjectReference, String> networkInfo = null;
  
@@@ -2477,9 -2513,10 +2514,10 @@@
              networkInfo = HypervisorHostHelper.prepareNetwork(switchName.first(), namePrefix, hostMo, getVlanInfo(nicTo, switchName.second()),
                      nicTo.getNetworkRateMbps(), nicTo.getNetworkRateMulticastMbps(), _ops_timeout,
                      !namePrefix.startsWith("cloud.private"));
-         } else {
+         }
+         else {
              networkInfo = HypervisorHostHelper.prepareNetwork(switchName.first(), namePrefix, hostMo, getVlanInfo(nicTo, switchName.second()),
-                     configureVServiceInNexus, nicTo.getNetworkRateMbps(), nicTo.getNetworkRateMulticastMbps(), _ops_timeout);
 -                    nicTo.getNetworkRateMbps(), nicTo.getNetworkRateMulticastMbps(), _ops_timeout, switchType, _portsPerDvPortGroup);
++                    nicTo.getNetworkRateMbps(), nicTo.getNetworkRateMulticastMbps(), _ops_timeout, switchType, _portsPerDvPortGroup, configureVServiceInNexus);
          }
  
          return networkInfo;

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/plugins/pom.xml
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/server/src/com/cloud/api/ApiResponseHelper.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/server/src/com/cloud/configuration/ConfigurationManagerImpl.java
----------------------------------------------------------------------

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/setup/db/db/schema-410to420.sql
----------------------------------------------------------------------
diff --cc setup/db/db/schema-410to420.sql
index 4807a65,4e39a71..a556ed3
--- a/setup/db/db/schema-410to420.sql
+++ b/setup/db/db/schema-410to420.sql
@@@ -110,35 -133,71 +133,105 @@@ CREATE TABLE `cloud`.`user_vm_clone_set
  
  INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'UserVmManager', 'vmware.create.full.clone' , 'false', 'If set to true, creates VMs as full clones on ESX hypervisor');
  
+ -- Re-enable foreign key checking, at the end of the upgrade path
+ SET foreign_key_checks = 1;
+ 
+ 
+ CREATE TABLE nic_secondary_ips (
+   `id` bigint unsigned NOT NULL UNIQUE AUTO_INCREMENT,
+   `uuid` varchar(40),
+   `vmId` bigint unsigned COMMENT 'vm instance id',
+   `nicId` bigint unsigned NOT NULL,
+   `ip4_address` char(40) COMMENT 'ip4 address',
+   `ip6_address` char(40) COMMENT 'ip6 address',
+   `network_id` bigint unsigned NOT NULL COMMENT 'network configuration id',
+   `created` datetime NOT NULL COMMENT 'date created',
+   `account_id` bigint unsigned NOT NULL COMMENT 'owner.  foreign key to   account table',
+   `domain_id` bigint unsigned NOT NULL COMMENT 'the domain that the owner belongs to',
+    PRIMARY KEY (`id`),
+    CONSTRAINT `fk_nic_secondary_ip__vmId` FOREIGN KEY `fk_nic_secondary_ip__vmId`(`vmId`) REFERENCES `vm_instance`(`id`) ON DELETE CASCADE,
+    CONSTRAINT `fk_nic_secondary_ip__networks_id` FOREIGN KEY `fk_nic_secondary_ip__networks_id`(`network_id`) REFERENCES `networks`(`id`),
+    CONSTRAINT `uc_nic_secondary_ip__uuid` UNIQUE (`uuid`)
+ ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
+ 
+ ALTER TABLE `cloud`.`nics` ADD COLUMN secondary_ip SMALLINT DEFAULT '0' COMMENT 'secondary ips configured for the nic';
+ ALTER TABLE `cloud`.`user_ip_address` ADD COLUMN dnat_vmip VARCHAR(40);
+ 
+ ALTER TABLE `cloud`.`alert` ADD COLUMN `archived` tinyint(1) unsigned NOT NULL DEFAULT 0;
+ ALTER TABLE `cloud`.`event` ADD COLUMN `archived` tinyint(1) unsigned NOT NULL DEFAULT 0;
+ INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'alert.purge.interval', '86400', 'The interval (in seconds) to wait before running the alert purge thread');
+ INSERT IGNORE INTO `cloud`.`configuration` VALUES ('Advanced', 'DEFAULT', 'management-server', 'alert.purge.delay', '0', 'Alerts older than specified number days will be purged. Set this value to 0 to never delete alerts');
+ 
+ DROP VIEW IF EXISTS `cloud`.`event_view`;
+ CREATE VIEW `cloud`.`event_view` AS
+     select
+         event.id,
+         event.uuid,
+         event.type,
+         event.state,
+         event.description,
+         event.created,
+         event.level,
+         event.parameters,
+         event.start_id,
+         eve.uuid start_uuid,
+         event.user_id,
+         event.archived,
+         user.username user_name,
+         account.id account_id,
+         account.uuid account_uuid,
+         account.account_name account_name,
+         account.type account_type,
+         domain.id domain_id,
+         domain.uuid domain_uuid,
+         domain.name domain_name,
+         domain.path domain_path,
+         projects.id project_id,
+         projects.uuid project_uuid,
+         projects.name project_name
+     from
+         `cloud`.`event`
+             inner join
+         `cloud`.`account` ON event.account_id = account.id
+             inner join
+         `cloud`.`domain` ON event.domain_id = domain.id
+             inner join
+         `cloud`.`user` ON event.user_id = user.id
+             left join
+         `cloud`.`projects` ON projects.project_account_id = event.account_id
+             left join
+         `cloud`.`event` eve ON event.start_id = eve.id;
++
 +CREATE TABLE `cloud`.`external_cisco_vnmc_devices` (
 +  `id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
 +  `uuid` varchar(255) UNIQUE,
 +  `physical_network_id` bigint unsigned NOT NULL COMMENT 'id of the physical network in to which cisco vnmc device is added',
 +  `provider_name` varchar(255) NOT NULL COMMENT 'Service Provider name corresponding to this cisco vnmc device',
 +  `device_name` varchar(255) NOT NULL COMMENT 'name of the cisco vnmc device',
 +  `host_id` bigint unsigned NOT NULL COMMENT 'host id coresponding to the external cisco vnmc device',
 +  PRIMARY KEY (`id`),
 +  CONSTRAINT `fk_external_cisco_vnmc_devices__host_id` FOREIGN KEY (`host_id`) REFERENCES `host`(`id`) ON DELETE CASCADE,
 +  CONSTRAINT `fk_external_cisco_vnmc_devices__physical_network_id` FOREIGN KEY (`physical_network_id`) REFERENCES `physical_network`(`id`) ON DELETE CASCADE
 +) ENGINE=InnoDB DEFAULT CHARSET=utf8;
 +
 +CREATE TABLE `cloud`.`external_cisco_asa1000v_devices` (
 +  `id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
 +  `uuid` varchar(255) UNIQUE,
 +  `physical_network_id` bigint unsigned NOT NULL COMMENT 'id of the physical network in to which cisco asa1kv device is added',
 +  `management_ip` varchar(255) UNIQUE NOT NULL COMMENT 'mgmt. ip of cisco asa1kv device',
 +  `in_port_profile` varchar(255) NOT NULL COMMENT 'inside port profile name of cisco asa1kv device',
 +  `cluster_id` bigint unsigned NOT NULL COMMENT 'id of the Vmware cluster to which cisco asa1kv device is attached (cisco n1kv switch)',
 +  PRIMARY KEY (`id`),
 +  CONSTRAINT `fk_external_cisco_asa1000v_devices__physical_network_id` FOREIGN KEY (`physical_network_id`) REFERENCES `physical_network`(`id`) ON DELETE CASCADE,
 +  CONSTRAINT `fk_external_cisco_asa1000v_devices__cluster_id` FOREIGN KEY (`cluster_id`) REFERENCES `cluster`(`id`) ON DELETE CASCADE
 +) ENGINE=InnoDB DEFAULT CHARSET=utf8;
 +
 +CREATE TABLE `cloud`.`network_asa1000v_map` (
 +  `id` bigint unsigned NOT NULL AUTO_INCREMENT COMMENT 'id',
 +  `network_id` bigint unsigned NOT NULL UNIQUE COMMENT 'id of guest network',
 +  `asa1000v_id` bigint unsigned NOT NULL UNIQUE COMMENT 'id of asa1000v device',
 +  PRIMARY KEY (`id`),
 +  CONSTRAINT `fk_network_asa1000v_map__network_id` FOREIGN KEY (`network_id`) REFERENCES `networks`(`id`) ON DELETE CASCADE,
 +  CONSTRAINT `fk_network_asa1000v_map__asa1000v_id` FOREIGN KEY (`asa1000v_id`) REFERENCES `external_cisco_asa1000v_devices`(`id`) ON DELETE CASCADE
 +) ENGINE=InnoDB DEFAULT CHARSET=utf8;
++

http://git-wip-us.apache.org/repos/asf/incubator-cloudstack/blob/f0c1af2b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
----------------------------------------------------------------------
diff --cc vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
index 3867881,621c091..fa6938a
--- a/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
+++ b/vmware-base/src/com/cloud/hypervisor/vmware/mo/HypervisorHostHelper.java
@@@ -401,9 -400,9 +408,9 @@@ public class HypervisorHostHelper 
  	 * @throws Exception
  	 */
  
-     public static Pair<ManagedObjectReference, String> prepareNetwork(String ethPortProfileName, String namePrefix,
-             HostMO hostMo, String vlanId, boolean configureVServiceInNexus, Integer networkRateMbps, Integer networkRateMulticastMbps, long timeOutMs)
-             throws Exception {
+     public static Pair<ManagedObjectReference, String> prepareNetwork(String physicalNetwork, String namePrefix,
+             HostMO hostMo, String vlanId, Integer networkRateMbps, Integer networkRateMulticastMbps, long timeOutMs,
 -            VirtualSwitchType vSwitchType, int numPorts) throws Exception {
++            VirtualSwitchType vSwitchType, int numPorts, boolean configureVServiceInNexus) throws Exception {
          ManagedObjectReference morNetwork = null;
          VmwareContext context = hostMo.getContext();
          ManagedObjectReference dcMor = hostMo.getHyperHostDatacenter();
@@@ -428,54 -422,109 +430,109 @@@
              createGCTag = true;
              vid = Integer.parseInt(vlanId);
          }
+         networkName = composeCloudNetworkName(namePrefix, vlanId, networkRateMbps, physicalNetwork);
  
-         networkName = composeCloudNetworkName(namePrefix, vlanId, networkRateMbps, ethPortProfileName);
+         if (vSwitchType == VirtualSwitchType.VMwareDistributedVirtualSwitch) {
+             DVSTrafficShapingPolicy shapingPolicy;
+             VmwareDistributedVirtualSwitchVlanSpec vlanSpec;
+             DVSSecurityPolicy secPolicy;
+             VMwareDVSPortSetting dvsPortSetting;
+             DVPortgroupConfigSpec dvPortGroupSpec;
+             DVPortgroupConfigInfo dvPortgroupInfo;
  
-         // TODO(sateesh): Enable this for VMware DVS.
- //        DVSTrafficShapingPolicy shapingPolicy = null;
- //        if (networkRateMbps != null && networkRateMbps.intValue() > 0) {
- //            shapingPolicy = new DVSTrafficShapingPolicy();
- //            BoolPolicy isEnabled = new BoolPolicy();
- //            LongPolicy averageBandwidth = new LongPolicy();
- //            LongPolicy peakBandwidth = new LongPolicy();
- //            LongPolicy burstSize = new LongPolicy();
- //
- //            isEnabled.setValue(true);
- //            averageBandwidth.setValue((long) networkRateMbps.intValue() * 1024L * 1024L);
- //            // We chose 50% higher allocation than average bandwidth.
- //            // TODO(sateesh): Also let user specify the peak coefficient
- //            peakBandwidth.setValue((long) (averageBandwidth.getValue() * 1.5));
- //            // TODO(sateesh): Also let user specify the burst coefficient
- //            burstSize.setValue((long) (5 * averageBandwidth.getValue() / 8));
- //
- //            shapingPolicy.setEnabled(isEnabled);
- //            shapingPolicy.setAverageBandwidth(averageBandwidth);
- //            shapingPolicy.setPeakBandwidth(peakBandwidth);
- //            shapingPolicy.setBurstSize(burstSize);
- //        }
-         DVPortgroupConfigInfo spec = dataCenterMo.getDvPortGroupSpec(networkName);
-         long averageBandwidth = 0L;
-         if (networkRateMbps != null && networkRateMbps.intValue() > 0) {
-             averageBandwidth = (long) (networkRateMbps.intValue() * 1024L * 1024L);
-         }
-         // We chose 50% higher allocation than average bandwidth.
-         // TODO(sateesh): Also let user specify the peak coefficient
-         long peakBandwidth = (long) (averageBandwidth * 1.5);
-         // TODO(sateesh): Also let user specify the burst coefficient
-         long burstSize = 5 * averageBandwidth / 8;
+             dvSwitchName = physicalNetwork;
+             // TODO(sateesh): Remove this after ensuring proper default value for vSwitchName throughout traffic types
+             // and switch types.
+             if (dvSwitchName == null) {
+                 s_logger.warn("Detected null dvSwitch. Defaulting to dvSwitch0");
+                 dvSwitchName = "dvSwitch0";
+             }
+             morDvSwitch = dataCenterMo.getDvSwitchMor(dvSwitchName);
+             if (morDvSwitch == null) {
+                 String msg = "Unable to find distributed vSwitch " + morDvSwitch;
+                 s_logger.error(msg);
+                 throw new Exception(msg);
+             } else {
+                 s_logger.info("Found distributed vSwitch " + morDvSwitch);
+             }
  
-         boolean bWaitPortGroupReady = false;
-         if (!dataCenterMo.hasDvPortGroup(networkName)) {
-             s_logger.info("Port profile " + networkName + " not found.");
-             createPortProfile(context, ethPortProfileName, networkName, vid, networkRateMbps, peakBandwidth, burstSize, configureVServiceInNexus);
-             bWaitPortGroupReady = true;
-         } else {
-             s_logger.info("Port profile " + networkName + " found.");
-             bWaitPortGroupReady = true;
-             updatePortProfile(context, ethPortProfileName, networkName, vid, networkRateMbps, peakBandwidth, burstSize);
+             dvSwitchMo = new DistributedVirtualSwitchMO(context, morDvSwitch);
+ 
+             shapingPolicy = getDVSShapingPolicy(networkRateMbps);
+             if (vid != null) {
+                 vlanSpec = createDVPortVlanIdSpec(vid);
+             } else {
+                 vlanSpec = createDVPortVlanSpec();
+             }
+             secPolicy = createDVSSecurityPolicy();
+             dvsPortSetting = createVmwareDVPortSettingSpec(shapingPolicy, secPolicy, vlanSpec);
+             dvPortGroupSpec = createDvPortGroupSpec(networkName, dvsPortSetting, numPorts);
+ 
+             if (!dataCenterMo.hasDvPortGroup(networkName)) {
+                 s_logger.info("Distributed Virtual Port group " + networkName + " not found.");
+                 // TODO(sateesh): Handle Exceptions
+                 try {
+                     dvSwitchMo.createDVPortGroup(dvPortGroupSpec);
+                 } catch (Exception e) {
+                     String msg = "Failed to create distributed virtual port group " + networkName + " on dvSwitch " + physicalNetwork;
+                     throw new Exception(msg);
+                 }
+                 bWaitPortGroupReady = true;
+             } else {
+                 s_logger.info("Found Distributed Virtual Port group " + networkName);
+                 // TODO(sateesh): Handle Exceptions
+                 dvPortgroupInfo = dataCenterMo.getDvPortGroupSpec(networkName);
+                 if (!isSpecMatch(dvPortgroupInfo, vid, shapingPolicy)) {
+                     s_logger.info("Updating Distributed Virtual Port group " + networkName);
+                     dvPortGroupSpec.setDefaultPortConfig(dvsPortSetting);
+                     dvPortGroupSpec.setConfigVersion(dvPortgroupInfo.getConfigVersion());
+                     morDvPortGroup = dataCenterMo.getDvPortGroupMor(networkName);
+                     try {
+                         dvSwitchMo.updateDvPortGroup(morDvPortGroup, dvPortGroupSpec);
+                     } catch (Exception e) {
+                         String msg = "Failed to update distributed virtual port group " + networkName + " on dvSwitch " + physicalNetwork;
+                         throw new Exception(msg);
+                     }
+                     bWaitPortGroupReady = true;
+                 }
+             }
+         } else if (vSwitchType == VirtualSwitchType.NexusDistributedVirtualSwitch) {
+             ethPortProfileName = physicalNetwork;
+             // TODO(sateesh): Remove this after ensuring proper default value for vSwitchName throughout traffic types
+             // and switch types.
+             if (ethPortProfileName == null) {
+                 s_logger.warn("Detected null ethrenet port profile. Defaulting to epp0.");
+                 ethPortProfileName = "epp0";
+             }
+             morEthernetPortProfile = dataCenterMo.getDvPortGroupMor(ethPortProfileName);
+             if (morEthernetPortProfile == null) {
+                 String msg = "Unable to find Ethernet port profile " + ethPortProfileName;
+                 s_logger.error(msg);
+                 throw new Exception(msg);
+             } else {
+                 s_logger.info("Found Ethernet port profile " + ethPortProfileName);
+             }
 -        long averageBandwidth = 0L;
 -        if (networkRateMbps != null && networkRateMbps.intValue() > 0) {
 -            averageBandwidth = (long) (networkRateMbps.intValue() * 1024L * 1024L);
 -        }
 -        // We chose 50% higher allocation than average bandwidth.
++            long averageBandwidth = 0L;
++            if (networkRateMbps != null && networkRateMbps.intValue() > 0) {
++                averageBandwidth = (long) (networkRateMbps.intValue() * 1024L * 1024L);
++            }
++            // We chose 50% higher allocation than average bandwidth.
+             // TODO(sateesh): Optionally let user specify the peak coefficient
 -        long peakBandwidth = (long) (averageBandwidth * 1.5);
++            long peakBandwidth = (long) (averageBandwidth * 1.5);
+             // TODO(sateesh): Optionally let user specify the burst coefficient
 -        long burstSize = 5 * averageBandwidth / 8;
 -
 -        if (!dataCenterMo.hasDvPortGroup(networkName)) {
 -            s_logger.info("Port profile " + networkName + " not found.");
 -                createPortProfile(context, physicalNetwork, networkName, vid, networkRateMbps, peakBandwidth, burstSize);
 -            bWaitPortGroupReady = true;
 -        } else {
 -            s_logger.info("Port profile " + networkName + " found.");
++            long burstSize = 5 * averageBandwidth / 8;
++
++            if (!dataCenterMo.hasDvPortGroup(networkName)) {
++                s_logger.info("Port profile " + networkName + " not found.");
++                createPortProfile(context, physicalNetwork, networkName, vid, networkRateMbps, peakBandwidth, burstSize, configureVServiceInNexus);
++                bWaitPortGroupReady = true;
++            } else {
++                s_logger.info("Port profile " + networkName + " found.");
+                 updatePortProfile(context, physicalNetwork, networkName, vid, networkRateMbps, peakBandwidth, burstSize);
+             }
          }
-         // Wait for dvPortGroup on vCenter		
-         if(bWaitPortGroupReady) 
+         // Wait for dvPortGroup on vCenter
+         if (bWaitPortGroupReady)
              morNetwork = waitForDvPortGroupReady(dataCenterMo, networkName, timeOutMs);
          else
              morNetwork = dataCenterMo.getDvPortGroupMor(networkName);


Mime
View raw message