CLOUDSTACK-4168 Root Admin should be able to create 'ExplicitDedication' affinity group at domain level and make it available for all accounts in the domain

Changes:
- 'ExcplicitDedication' type of group can be created/deleted by Root admin only
- Users can no longer create this type of affinity group
- RootAdmin can create this type of affinitygroup at domain level. Such a domain level group is available for all accounts in that domain for listing and for use during deployVM.
- The domain level affinitygroup should be visible to the users in that domain, domain admins and Root admin.

Conflicts:

	server/src/com/cloud/api/query/QueryManagerImpl.java
	server/src/org/apache/cloudstack/affinity/AffinityGroupServiceImpl.java
	server/test/org/apache/cloudstack/affinity/AffinityApiUnitTest.java
CLOUDSTACK-4221: Dedicated Resources: changes to associate the dedicated resource with the 'ExplicitDedication' affinity group

Changes:
- Implict creation of the 'ExplicitDedication' Affinity group during resource dedication
- Only one group per account or per domain will be present
- ListDedicatedResources by affinityGroup
- Deployment should consider dedicated resources associated to the group only
- Deleting affinity group should release the dedicated resouces
- Releasing the dedicated resources should remove the group associated if there are no more resources.

Conflicts:

	plugins/dedicated-resources/src/org/apache/cloudstack/dedicated/DedicatedResourceManagerImpl.java
	plugins/dedicated-resources/test/org/apache/cloudstack/dedicated/manager/DedicatedApiUnitTest.java
	server/src/com/cloud/configuration/ConfigurationManagerImpl.java
CLOUDSTACK-4168: Root Admin should be able to create 'ExplicitDedication' affinity group at domain level and make it available for all accounts in the domain

Changes:
- Include the new AffinityGroupAccessChecker in all *ComponentContext.xml.in
CLOUDSTACK-4221: Dedicated Resources: changes to associate the dedicated resource with the 'ExplicitDedication' affinity group

Changes:
- Adding mocks in unit tests for new injected components

Conflicts:

	server/test/org/apache/cloudstack/networkoffering/ChildTestConfiguration.java
CLOUDSTACK-4234 Dedicated Resources: When multiple dedication groups are chosen for VM deployment, dedicated resources belonging to both groups should be considered

- Override the equals method
CLOUDSTACK-4234:Dedicated Resources: When multiple dedication groups are chosen for VM deployment, dedicated resources belonging to both groups should be considered

Changes:
- Do not add the dedicated resource to avoid list if it is present in the list of resources to consider for the deployment.
CLOUDSTACK-4259 Dedicated Resources: createAffinityGroup API should not allow admin to create the group of this type through API

Changes:
- Block API from creating this type of group
CLOUDSTACK-4276 Dedicated Resources: Private Zone functionality issues

Changes:
createZone API:
- This API takes in domainid, set it to the zone record in the data_center table

updateZone API:
- This API uses 'isPublic' flag to set a private zone to public - if this flag is set and the zone is dedicated, release the dedication and remove the domainid from the data_center table

listZone API:
- This API already has 'domainid' parameter. We should allow list zones by domain for Root admin.

DedicateZone API:
- set domainid in the data_center table

ReleaseDedicatedZone API:
- remove zoneid from the data_center table
CLOUDSTACK-4337 Dedicated Resources: Zone dedicated to an account should only be visible and accessible to that account

Changes:
- When listing a zone, add clause in the search to check the account_id for a dedicated zone
- When listsing a zone with a domainid, add a similar clause.
- DomainCheck:: checkAccess() for a zone should consider that zone can now be dediacted to a specific account and check access accordingly.

Conflicts:

	server/src/com/cloud/api/query/vo/DataCenterJoinVO.java
	setup/db/db/schema-410to420.sql
CLOUDSTACK-4561: DeployVm failed after upgrading from earlier version having a private zone to 4.2

Changes:
- In the upgrade path, for a private zone, entry needs to be added in the affinity_group_domain_map to provide access to the private zone for the domains it belongs too.
CLOUDSTACK-4222: [VMWare] NPE: VM Failed to start after Volume Migration

- ExplicitDedicationProcessor should process only if group of this type is used!
CLOUDSTACK-4369 [UPGRADE]Upgrade failed from 307 to 4.2

Changes:
- Do not consider removed zones
- Create affinity group per domain
Changes required to merge to master:

- Replace UserContext by CallContext