478 Commits

Author SHA1 Message Date
Alex Huang
8d62744681 Reformat all source code. Added checkstyle to check the source code 2013-11-20 07:26:53 -08:00
Alex Huang
465626f6d1 Fixed issues with execute in sequence 2013-11-19 17:20:58 -08:00
Hugo Trippaers
bb8f8fb20b Expose getPrimaryDataStore(String uuid) through the DatastoreManager interface so it can be used clients. 2013-11-18 14:27:06 +01:00
Edison Su
1292b76c63 Add a new method on datastoredriver: getCapabilities, which will be called by liststoragepoolcmd. UI can make decision based on the capabilities of the storage.
And also add a new table: snapshotdetails
2013-11-14 15:55:39 -08:00
Harikrishna Patnala
53b0bf6733 Template/ISO download fails cause the object to disappear from UI in 4.2
Signed-off-by: Koushik Das <koushik@apache.org>
2013-11-11 10:58:43 +05:30
Edison Su
4815b024bf Add quiesce vm for vmware during vm snapshot 2013-11-08 15:47:11 -08:00
Edison Su
c233492bfc Add quiencevm option on createsnapshotcmd 2013-11-07 14:57:05 -08:00
Chris Suich
aef633f203 Updated VMSnapshotDetails* to match *Details* pattern (e.g. UserVMDetails*)
Signed-off-by: Edison Su <sudison@gmail.com>
2013-11-07 14:28:19 -08:00
Hugo Trippaers
f6f4a93145 Fix CID 1116743 Resource leak 2013-11-07 16:23:20 +01:00
Mike Tutkowski
10c513a259 CLOUDSTACK-4810: Enable hypervisor snapshots for CloudStack-managed storage (for XenServer and VMware) 2013-11-06 21:02:39 -07:00
Min Chen
eb9cfffd24 Fix NPE due to race condition during system vm launch. 2013-11-04 14:27:04 -08:00
Min Chen
9a62239a92 CLOUDSTACK-5017: Throw CloudRuntimeException in case of template/volume
download when ssvm is not ready so that caller can remove some leftover
entries in template_store_ref and volume_store_ref.
2013-11-04 12:32:05 -08:00
Hugo Trippaers
54a3d8048b Get rid of a few errors and warnings in the engine storage integration-test sources 2013-11-04 20:01:13 +01:00
Min Chen
24af28290e CLOUDSTACK-5017: use LocalHostEndPoint in copying from S3 to cache store
during ssvm launch.
2013-11-01 18:07:00 -07:00
Min Chen
6eecb0b3b5 CLOUDSTACK-5017: If SSVM is unavailable DownloadCommands will be routed
to mgmt server.
2013-11-01 18:07:00 -07:00
Edison Su
918bc74050 fix compile 2013-11-01 16:16:03 -07:00
Edison Su
143fbc37a6 fix build 2013-11-01 16:02:24 -07:00
Edison Su
7c99b88926 Don't use cast to PrimarydataStoreTO on the resource code 2013-11-01 15:13:16 -07:00
Edison Su
b704d5b8d3 add quiesceVm vm helper function 2013-10-31 16:24:48 -07:00
Alena Prokharchyk
591dcd1d1c ResourceDetails: added "display" field to a bunch of VOs - determines whether the detail should be returned to the regular user 2013-10-29 09:18:11 -07:00
Min Chen
6be228a438 CLOUDSTACK-4024:Provide a way to upgrade from existing NFS secondary
storage to S3.
2013-10-28 21:01:31 -07:00
Alena Prokharchyk
2cac1aaa0f Moved ResourceDao and ResourceDaoBase to cloud-engine-schema/org/apache/cloudstack (used to be mistakenly placed under com/cloud/cloud) 2013-10-28 15:03:57 -07:00
Alena Prokharchyk
5caeab782d ResourceDetails -
1) added createDetail to ResourceDetailDao interface to provide generic way of creating resourceDetail DB objects
2) added resource details support for firewall rules
2013-10-28 14:45:52 -07:00
Alena Prokharchyk
e86b612750 ResourceDetails - added createDetail to ResourceDetailDao interface to provide generic way of creating resourceDetail DB objects 2013-10-28 12:53:53 -07:00
Alena Prokharchyk
d0090a0c24 Resource details (metadata) - added support for Storage pool details 2013-10-28 12:53:53 -07:00
Edison Su
92f97248a8 fix inject hypervisorHelperImpl 2013-10-28 12:09:14 -07:00
Laszlo Hornyak
7902315287 build fix
Failing VMSnapshotStrategyTest was missing db.properties

Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>
2013-10-26 17:34:00 +02:00
Edison Su
70b2c0150d rebase to spring changes 2013-10-25 18:15:36 -07:00
Edison Su
51a8086cf6 Merge branch 'pluggable_vm_snapshot'
Conflicts:
	client/tomcatconf/applicationContext.xml.in
	engine/storage/integration-test/test/org/apache/cloudstack/storage/test/SnapshotTest.java
	engine/storage/integration-test/test/resources/storageContext.xml
	server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
	server/src/com/cloud/vm/snapshot/VMSnapshotManagerImpl.java
2013-10-25 16:47:17 -07:00
Edison Su
a6ce66e55a move a lot of code into vmsnapshot strategy
fix compile

fix compile

add vm_snapshot_details table in db

add vmsnapshot test cases
2013-10-25 15:09:04 -07:00
Alena Prokharchyk
24725f8e21 ResourceDetails:
1) Added support for Zone resource details
2) Renamed DcDetailsDao to DataCenterDetailsDao to follow the CS name convention for DataCenter related classes
2013-10-24 15:54:49 -07:00
Darren Shepherd
f3e968b983 Update StorageStrategyFactory to not sort, but just iterate and find the first 2013-10-23 16:36:31 -07:00
Darren Shepherd
891b85d516 Add missing licenses 2013-10-23 15:20:08 -07:00
Darren Shepherd
b134692697 Fix compilation errors in engine/storage/integration-test 2013-10-23 14:44:16 -07:00
Darren Shepherd
c9101966e0 Added StorageStrategyFactory to centralize and deduplicate some logic 2013-10-23 12:40:41 -07:00
Darren Shepherd
81d01369d7 Merge commit 'df728fcf41ba0dfddabfaadea8cbcb77d18bfa96'
Conflicts:
	engine/orchestration/src/com/cloud/vm/VirtualMachineManagerImpl.java
2013-10-23 12:31:53 -07:00
Chris Suich
0ed7ebd7e7 Squashed & merged commit of the following:
commit c9ee0d12e191e803fb341f3f96e95ca434a36f6c
Author: Wei Zhou <w.zhou@leaseweb.com>
Date:   Wed Oct 23 16:55:10 2013 +0200

    CLOUDSTACK-4931, CLOUDSTACK-4937: setDetails to user VMs only
    (cherry picked from commit a94acc5a43aeaf5f18f1912e2653a92f6041a6e5)

commit fe1586c71377bc6d219db2dcf088c40b65dd1fc4
Author: Anthony Xu <anthony.xu@citrix.com>
Date:   Tue Oct 22 11:20:27 2013 -0700

    CLOUDSTACK-4649:
            vm sync tracks the pv driver version for xenserver

     Anthony

commit 56a218f66eda540b4b4b04030ee71fc6863f8532
Author: Anthony Xu <anthony.xu@citrix.com>
Date:   Mon Oct 21 16:10:07 2013 -0700

    CLOUDSTACK-4649:
        xs 6.1/6.2 introduce the new virtual platform, so there are two virtual platforms, windows PV driver version must match virtual platforms,
    this patch tracks PV driver versions in vm details and template details.

    Anthony

commit 4e85d28c678a6f96b5b70d8d33fc60f9d1ea3df6
Author: Laszlo Hornyak <laszlo.hornyak@gmail.com>
Date:   Mon Oct 21 21:17:33 2013 +0200

    removed unused static field

    - s_httpClientManager was not used

    Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>

commit d4121fa26023db236f7396cea455ef090672ae9a
Author: Chris Suich <chris.suich@netapp.com>
Date:   Tue Oct 22 10:45:22 2013 -0400

    Updated DataMotionServiceImpl and ApiResponseHelper based on review feedback.

commit aaf026e1e4204d405bcda2ae4f1a01b1d0f7e7cb
Author: Chris Suich <chris.suich@netapp.com>
Date:   Thu Oct 17 14:27:12 2013 -0400

    Added context to strategy sorting error responses
    Added TODOs for DRYing out pickStrategy() overloading

commit a221f4aa3fb2ddc255bc35cf753f98f88f5bf44e
Author: Chris Suich <chris.suich@netapp.com>
Date:   Wed Oct 16 09:57:28 2013 -0400

    Updated inefficient strategy sorting/selection
    Removed unnecessary canRevertSnapshot from PrimaryDataStoreDriver
    Other general cleaup and fixes from reviews

commit 7d58949c6a1b7e853e891b59387a9620e8cd7a91
Author: Chris Suich <chris.suich@netapp.com>
Date:   Mon Oct 14 14:01:22 2013 -0400

    Added volume snapshot revert capability to SnapshotResponse
    Updated UI to hide/show snapshot revert action per snapshot

Signed-off-by: Edison Su <sudison@gmail.com>
2013-10-23 12:21:43 -07:00
Darren Shepherd
e3280bdba2 Merge remote-tracking branch 'origin/spring-modularization'
Conflicts:
	client/tomcatconf/applicationContext.xml.in
	client/tomcatconf/nonossComponentContext.xml.in
	client/tomcatconf/simulatorComponentContext.xml.in
	framework/db/src/com/cloud/utils/db/Transaction.java
	plugins/hypervisors/simulator/src/com/cloud/agent/manager/MockAgentManagerImpl.java
	server/src/com/cloud/api/ApiServer.java
	server/src/com/cloud/storage/snapshot/SnapshotManagerImpl.java
2013-10-23 11:14:42 -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
Nitin Mehta
17dd9a832b CLOUDSTACK-3737:
Delete the uploaded volume once its copied successfully to the primary storage.
Signed off by : nitin mehta<nitin.mehta@citrix.com>
2013-10-21 14:54:42 -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
Min Chen
ec3302afd6 CLOUDSTACK-3472: [Object_Store_Refactor] System VMs are not coming up in
initial attempt, but they are coming up after multiple attempts.
2013-10-17 15:59:10 -07:00
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
Chris Suich
aad1cda7e0 Added categorized sorting to SnapshotStrategy and DataMotionStrategy 2013-10-14 15:20:42 -07:00
Chris Suich
350c94474b Updates to revertSnapshot API Added revertSnapshot API action to UI 2013-10-14 15:19:51 -07:00
Darren Shepherd
7c72aa96da ConcurrentHashMap will through NPE on null key 2013-10-04 16:56:48 -07:00
Edison Su
a129fe4e66 add missing files 2013-10-04 14:17:49 -07:00
Chris Suich
180cfa19e8 Refactor Storage Related Resource Code
These changes are a joint effort between Edison and I to refactor some
of the code around snapshotting VM volumes and creating
templates/volumes from VM volume snapshots. In general, we were working
towards allowing PrimaryDataStoreDrivers to create snapshots on primary
storage and not requiring the snapshots to be transferred to secondary
storage.

High level changes:
-Added uuid to NfsTO, SwiftTO & S3TO to cut down on the requirement of
PrimaryDataStoreTO and ImageStoreTO which don't really serve much of a
purpose
-Initial work towards enable reverting VM volume from snapshots
-Added hypervisor commands for introducing and forgetting new hypervisor
objects (snapshots, templates & volumes)

Signed-off-by: Edison Su <sudison@gmail.com>
2013-10-04 13:06:42 -07:00
Darren Shepherd
c9a9a3b7b3 Make SnapshotStrategy and DataMotionStrategy discovered and registered 2013-10-03 17:03:28 -07:00
Hugo Trippaers
3f583684c6 Temporary fix for the chicken and egg problem when making changes to the configuration database. 2013-10-03 12:36:34 +02:00