67 Commits

Author SHA1 Message Date
Anshul Gangwar
ae199b6ce7 CLOUDSTACK-7703, CLOUDSTACK-7752: Fixed deployment planner stuck in infinite loop.
If we create VM with shared service offering and attach disk with local disk offering,
and one of storage pool is full(cannot be allocated) and other is not full then
we are not putting the cluster in avoid list which is causing this infinite loop.

Fixed by putting the cluster in avoid list even if one of the storage pool is full(cannot be allocated)
2014-11-18 14:12:45 +05:30
Rohit Yadav
4d8dfc9b7c CID-1192810: Remove useless control flow
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit f74446a195d2a0fa4f1380254416a8a8538a6893)
2014-10-12 23:58:06 -04:00
David Nalley
3cac7f01bb Revert "CLOUDSTACK-6278"
This reverts commit bc2ec23d09e28b30a9cc3cb4a7d6f52c8e718fcf.
2014-10-12 23:19:30 -04:00
Frank Zhang
bc2ec23d09 CLOUDSTACK-6278
Baremetal Advanced Networking support
2014-09-18 16:54:37 -07:00
Frank.Zhang
1ee7e0c77e CLOUDSTACK-6278
Baremetal Advanced Networking support
2014-08-04 15:00:44 -07:00
Hugo Trippaers
1440a1c6a0 Fix CID 1114609 Log the correct number 2014-07-24 12:21:37 +02:00
Prachi Damle
48574f2d60 CLOUDSTACK-7047: DeploymentPlanner should include disabled resources only when the VM owner is Admin account
Changes:
- removing unused imports
2014-07-02 17:49:53 -07:00
Prachi Damle
9f68870a77 CLOUDSTACK-7047: DeploymentPlanner should include disabled resources only when the VM owner is Admin account
Changes:
-DeploymentPlanner should include disabled resources only when the VM owner is Admin account.
The disabled resources should be ignored when VM is owned by any other user.
2014-07-02 17:49:51 -07:00
wrodrigues
b3f18e7d74 implementation of the featured requests in the issue CLOUDSTACK-6139.
Signed-off-by: Daan Hoogland <daan@onecht.net>
2014-04-17 20:51:46 +02:00
Daan Hoogland
a05718cb23 [DB-CHANGE] windows line endings 2014-04-17 20:51:04 +02:00
Sanjay Tripathi
2ae9da8d47 CLOUDSTACK-6357: Not able to select GPU card in case of GPU-passthrough. 2014-04-08 22:10:09 +05:30
Alena Prokharchyk
3a889aa217 CLOUDSTACK-3886: Volume attach/detach implementation for ROOT disk
Implemented for Xen hypervisor only by now
Unittests are included
2014-04-03 11:39:56 -07:00
Min Chen
84a528fad6 Merge branch 'master' into rbac 2014-03-13 14:52:37 -07:00
Prachi Damle
d9696b26e1 After merge, fix isRootAdmin() calls to use accountId instead of type 2014-03-13 13:28:40 -07:00
Min Chen
99bdc8d875 Merge branch 'master' into rbac. 2014-03-13 11:05:03 -07:00
Alena Prokharchyk
1b83698dac deployVm/startVm APIs: ability to define deploymentPlanner for VmToStart in the api call (available to ROOT admin only) 2014-03-13 10:23:34 -07:00
Sanjay Tripathi
c7d31fe288 CLOUDSTACK-4760 : Enabling GPU support for XenServer.
CLOUDSTACK-4762 : Enabling VGPU support for XenServer.

This feature is to enable the GPU-passthrough and vGPU functionality,
with the help of this feature, admins/users will be able to leverage
the GPU graphics unit power by deploying a virtul machine with GPU or
vGPU support or by changing the service offering of an existing VM
at any later point of time. There GPU/vGPU enabled VMs are able to run
graphical applications.
For now, this feature is only supported with XenServer hypervisor but
can be extended to add the support of other hypervisors.
2014-03-11 15:44:51 +05:30
Prachi Damle
f84375442e Merge branch 'master' into rbac
Conflicts:
	api/src/org/apache/cloudstack/api/command/user/autoscale/ListAutoScaleVmProfilesCmd.java
	api/src/org/apache/cloudstack/api/command/user/volume/ResizeVolumeCmd.java
	plugins/network-elements/juniper-contrail/test/org/apache/cloudstack/network/contrail/management/MockAccountManager.java
	server/src/com/cloud/api/ApiServer.java
	server/src/com/cloud/api/query/QueryManagerImpl.java
	server/src/com/cloud/template/TemplateAdapterBase.java
	setup/db/db/schema-430to440.sql
	tools/apidoc/gen_toc.py
2014-02-04 12:07:32 -08:00
Prachi Damle
7d0472bdaa CLOUDSTACK-5995 ; change service offering is not honouring host tags
- Check host tag when the lastHostId is set.
2014-01-31 12:02:44 -08:00
Daan Hoogland
fe262caa75 findbugs: retrieve the objects to remove from the collection(s) 2014-01-28 15:36:40 +01:00
Sanjay Tripathi
b25ee92c34 CS-5950: Wrong storage tags are used for ISO deployed VMs. 2014-01-27 16:58:55 +05:30
Min Chen
929fbabaa2 Merge branch 'master' into rbac. 2014-01-17 14:37:08 -08:00
Nitin Mehta
1c0b8db01b CLOUDSTACK-4941:
Adding the missing file
During HA and maintenance call different planners (if the original planners are not able to find capacity) which skip some heurestics
2013-12-18 16:27:20 -08:00
Min Chen
afcf967d24 Revert "CLOUDSTACK-4941:"
This reverts commit 231e7c01f2415c1f25d6a2715b7469fe7fcfe771.
2013-12-18 16:01:37 -08:00
Nitin Mehta
231e7c01f2 CLOUDSTACK-4941:
During HA and maintenance call different planners (if the original planners are not able to find capacity) which skip some heurestics
2013-12-18 14:58:37 -08:00
Prachi Damle
78e4dd8566 CLOUDSTACK-4852: Since upgrade to 4.2 only users at the zone-attached domain level can manipulate VMs
Changes:
- The vmprofile owner passed in to the planner should be the VM's account and not the caller
- Do not do the access check for Root Admin

Conflicts:

	server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
2013-12-17 14:55:56 -08:00
Alex Huang
be5e5cc641 All Checkstyle problems corrected 2013-12-12 12:26:07 -08:00
Prachi Damle
4a9da03760 CLOUDSTACK-5426 Cannot deploy instance having multiple volumes that use different storage tags for storage pools in same cluster
Fixing the Imports missing
2013-12-09 15:37:15 -08:00
Prachi Damle
5618a44ed0 CLOUDSTACK-5426: Cannot deploy instance having multiple volumes that use different storage tags for storage pools in same cluster
Changes:
- We need to reset the avoid set to its original state while calling the storage pool allocators for each volume.
- This will prevent affecting allocation of the disks due to the avoid set output of the prior disk allocations.

Conflicts:

	server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
2013-12-09 15:37:13 -08:00
Prachi Damle
60cca0f65e CLOUDSTACK-5140: A stopped vm cant start after disable threshold has been reached on the storage pool
Changes:
- Do not do the stoarge capacity check for a VM having READY Volumes that are already present on the storagepool.

Conflicts:

	server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
2013-12-06 11:18:23 -08:00
Nitin Mehta
ed1f3d9ed6 CLOUDSTACK-5391:
check for host cpu capability while stop starting a vm on the same host. Also changed the FirstFitAllocator to use the same method.
2013-12-05 15:37:01 -08:00
Alex Huang
d620df2bdd Reformatted all of the code. 2013-11-21 06:15:26 -08:00
Alex Huang
224f479974 Removed trailing spaces 2013-11-21 04:08:01 -08:00
Alex Huang
62e9273581 Removed trailing spaces 2013-11-21 03:12:05 -08:00
Alex Huang
8d62744681 Reformat all source code. Added checkstyle to check the source code 2013-11-20 07:26:53 -08:00
Prachi Damle
863a84a15d CLOUDSTACK-4948: DeploymentPlanner: Logic to check if cluster can be avoided, needs to consider if VM is using local storage and/or shared storage
Changes:
	- Changes due to VirtualMachineProfile changes done in master
2013-11-04 16:45:06 -08:00
Prachi Damle
4be7947281 CLOUDSTACK-4948: DeploymentPlanner: Logic to check if cluster can be avoided, needs to consider if VM is using local storage and/or shared storage
Changes:
- Consider if VM requires the local storage or shared storage or both for its disks.
- Accordingly all pools in the cluster should consider local or shared or both pools

Conflicts:

	server/src/com/cloud/agent/manager/allocator/HostAllocator.java
2013-11-04 16:45:02 -08:00
Min Chen
2ef4d5200c Merge branch 'master' into rbac. 2013-10-31 17:16:33 -07:00
Darren Shepherd
205a77a5bb Merge remote-tracking branch 'origin/txn-refactor'
Conflicts:
	engine/orchestration/src/org/apache/cloudstack/engine/orchestration/NetworkOrchestrator.java
	server/src/com/cloud/configuration/ConfigurationManagerImpl.java
	server/src/com/cloud/metadata/ResourceMetaDataManagerImpl.java
	server/src/com/cloud/vm/UserVmManagerImpl.java
2013-10-23 10:40:44 -07:00
Koushik Das
0c1800f70f CLOUDSTACK-4681: data disk with local disk offering are geting created on shared storage
The cluster and zone wide storage pool allocators returned shared pools even for volumes meant to be on local storage pool.
If the VM uses local disk then cluster and zone storage allocators should not handle it and return null or empty list.

Also fixed the deployment planner to avoid a cluster if
a. avoid set returned by storage pool allocators is empty OR
b. all local or shared pools in a cluster are in avoid state

Conflicts:
	engine/storage/src/org/apache/cloudstack/storage/allocator/ClusterScopeStoragePoolAllocator.java
	engine/storage/src/org/apache/cloudstack/storage/allocator/ZoneWideStoragePoolAllocator.java
2013-10-18 17:10:17 +05:30
Darren Shepherd
f62e28c1ec New Transaction API
Introduction of a new Transaction API that is more consistent with the style
of Spring's transaction managment.  The existing Transaction class was renamed
to TransactionLegacy.  All of the non-DAO code in the management server has been
updated to use the new Transaction API.
2013-10-16 09:21:00 -07:00
Darren Shepherd
aed5e9dc2a Add Manage Context framework
The managed context framework provides a simple way to add logic
to ACS at the various entry points of the system.  As threads are
launched and ran listeners can be registered for onEntry or onLeave
of the managed context.  This framework will be used specifically
to handle DB transaction checking and setting up the CallContext.
This framework is need to transition away from ACS custom AOP to
Spring AOP.
2013-10-02 13:09:52 -07:00
Prachi Damle
aba54356d5 Account_Type Refactoring for Root Admin Role
- change the AccountService::isRootAdmin(short) to  isRootAdmin(long accountId);
- Change all callers
- Change all places that check the account.getType() directly to call the AccountManagerImpl.
2013-09-24 15:31:09 -07:00
Prachi Damle
62d60c2b77 CLOUDSTACK-4664: [ZWPS] High delay to start a stopped VM which has ROOT/DATA volumes migrated to Second Zone wide primary Storage(More than 10 mins)
Changes:
- DeploymentPlanningManager needs to reuse the zone wide primary storage pool when VM's volume is READY
2013-09-18 16:52:07 -07:00
Prachi Damle
7416383fcd CLOUDSTACK-4651: Restarting management server when volume Snapshot is still in progress for root volume of a VM , then there is no way to restart VM since the startVM job is stuck forever since the volume is in "Snapshoting" state.
Change:
-If no volume of the VM is usable, VM cannot be deployed or started. Atleast ROOT volume should always be in usable state to start up the VM
2013-09-18 16:52:04 -07:00
Prachi Damle
ef22b42b38 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
2013-09-03 20:02:38 -07:00
Koushik Das
8cf48ed2ce CLOUDSTACK-4179: [Performance Testing] Time taken for Deploy VM async job to complete is considerably higher
The time increased due to the newly added dedicated resources feature. During regular VM deployment, all dedicated resources are put in avoid list so that they are not considered for deployment.
Now the way to compute the list of dedicated resources is not optimal and performance deteriorates in an environment having lot of pods, clusters and hosts as the logic is to query db. for each suc resource.

The fix is to optimize the logic not to loop through all resources but get the list of each resource type in a single query.

Conflicts:
	server/src/com/cloud/deploy/DeploymentPlanningManagerImpl.java
2013-08-09 16:57:21 +05:30
Alex Huang
5495f10bce Revert "Reverting the range of commits that broke the build"
This reverts commit b59e3aaefced03d40d5b4b63c421c69743bcd387.
2013-08-08 15:02:40 -07:00
Prasanna Santhanam
b59e3aaefc Reverting the range of commits that broke the build
This reverts commits 30c33415..f6a2c817bc

Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-08-08 14:46:56 +05:30
Alex Huang
942f282a6e Moved config into it's own package 2013-08-07 16:41:02 -07:00