732 Commits

Author SHA1 Message Date
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
Wei Zhou
db890bc71e fix a bug in findAllChildren of domains 2013-10-21 14:02:53 +02: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
Nitin Mehta
fc6c1ec812 CLOUDSTACK-4882:
list Clusters/pods/zones API not accounting for reserved in the used capacity percentage.
Fix listCapacity cmd for reserved as well
Signed off by : nitin mehta<nitin.mehta@citrix.com>
2013-10-16 15:02:18 -07:00
Kishan Kavala
81f1a0b831 CLOUDSTACK-4095 : Remove region_id from Transaction. Read from db.properties whenever required
Conflicts:
	framework/db/src/com/cloud/utils/db/GenericDaoBase.java
2013-10-16 19:28:42 +05:30
Prasanna Santhanam
76dbb64cf9 License header was missed in StrategyPriority and Test
Signed-off-by: Prasanna Santhanam <tsp@apache.org>
2013-10-15 10:59:28 +05:30
Min Chen
f451a8113e CLOUDSTACK-4859:Add global config to disable storage migration during HA 2013-10-14 22:12:56 -07:00
Min Chen
ac02987db2 Add upgrade path from 4.2.1 to 4.3.0. 2013-10-14 21:56:34 -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
Marcus Sorensen
4e0e7410e9 Store agent hostname in attache, print it in logs wherever possible. This
was discussed on the mailing list as a useful debugging tool, currently
the log prints the DB id of the agent, which makes admins have to look
it up to know where the Command was run.
2013-10-14 11:46:01 -06:00
Nitin Mehta
fa0c685bcb CLOUDSTACK-4854:
Add support for adding network details
Signed off by : nitin mehta<nitin.mehta@citrix.com>
2013-10-10 19:18:39 -07:00
Alena Prokharchyk
c4084a7c34 Fixes for resource details code: 1) Fixed the NPE happening when the resource detail couldn't be located by the key passed through API 2) Added ResourceDetails interface, made all resource details VO objects to implement it. 2013-10-10 11:13:47 -07:00
Harikrishna Patnala
bb7493775c CLOUDSTACK-4707: "sourcetemplateid" field is not getting set for derived templates Template created from a volume or snapshot did not have the sourcetemplateid field set in vm_template table. 2013-10-10 12:20:40 +05:30
Nitin Mehta
6e80bb001c CLOUDSTACK-4824:
Add support for adding zone details
Signed off by : nitin mehta<nitin.mehta@citrix.com>
2013-10-07 15:48:43 -07:00
Alena Prokharchyk
66185076df Addded back Agent Load Balancing functionality (was temporarely disabled in master by vmSync merge) 2013-10-07 09:46:52 -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
Laszlo Hornyak
bd8536739c remove txn attribute from DB
txn attribute was never actually used

Signed-off-by: Laszlo Hornyak <laszlo.hornyak@gmail.com>
2013-10-04 10:15:39 -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
Nitin Mehta
8466fad6ca CLOUDSTACK-4785:
Adding list details for UserVm.
Signed off by : nitin mehta<nitin.mehta@citrix.com>
2013-10-02 14:53:07 -07:00
Nitin Mehta
85b5c6e353 CLOUDSTACK-4785:
Add support for adding user vm details and removing them.
Signed off by : nitin mehta<nitin.mehta@citrix.com>
2013-10-02 14:16:45 -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
Alena Prokharchyk
a2bf7f035e CLOUDSTACK-4784: 22x to 4.x upgrade - don't ignore redundant router network offering, when update ntwk_offering_serivce_map with PF/StaticNat/SourceNat services 2013-10-02 11:09:44 -07:00
Darren Shepherd
efbfae723e Switch to setter injection for extensibility
Various classes are using member injection to inject extensible objects.
Really those object should come from an AdapterList that is injected in.
This patch switches the code to use setter injection that will later allow
spring to inject an AdapterList or something similar to allow
extensibility.
2013-09-30 09:45:07 -07:00
Alena Prokharchyk
43770e0cb2 CLOUDSTACK-4744: enhanced root admin API updateVolume with state/storageId parameters as a part of "Better control over first party objects" feature.
Also fixed existing bugs for the API:

* corrected action event to be VOLUME.UPDATE (was VOLUME.ATTACH)
* all parameters to update, should be optional - fixed that. If nothing is specified, the db object will remain with its original fields
2013-09-28 21:44:47 -07:00
Alex Huang
b60eef3e82 Added comments and finished off the work 2013-09-28 07:53:28 -07:00
Alex Huang
e8cac2c5d8 Changed SearchCriteria2 to GenericQueryBuilder to reflect the same placement 2013-09-28 07:53:26 -07:00
Alex Huang
e2988902c9 Changed SearchCriteria2 to GenericQueryBuilder to reflect the same placement 2013-09-28 07:53:25 -07:00
Alex Huang
a964cf549e Continue to merge SearchCriteria2 and GenericSearchBuilder 2013-09-28 07:53:24 -07:00
Alex Huang
af8832f6bd Unified both the SearchBuilder and SearchCriteriaService 2013-09-28 07:53:24 -07:00
Edison Su
350e8938cf CLOUDSTACK-4754: it's a race condition: delete template, and deploy vm from the template happened at the same time, 2013-09-27 16:10:57 -07:00
ynojima
a45ee749ac CLOUDSTACK-2328: Linux native VXLAN support on KVM hypervisor
Initial patch for VXLAN support.
Fully functional, hopefully, for GuestNetwork - AdvancedZone.

Patch Note:
 in cloudstack-server
- Add isolation method VXLAN
- Add VxlanGuestNetworkGuru as plugin for VXLAN isolation
- Modify NetworkServiceImpl to handle extended vNet range for VXLAN isolation
- Add VXLAN isolation option in zoneWizard UI

 in cloudstack-agent (kvm)
- Add modifyvxlan.sh script that handle bridge/vxlan interface manipulation script
-- Usage is exactly same to modifyvlan.sh
- BridgeVifDriver will call modifyvxlan.sh instead of modifyvlan.sh when VXLAN is used for isolation

Database changes:
- No change in database structure.
- VXLAN isolation uses same tables that VLAN uses to store vNet allocation status.

Known Issue and/or TODO:
- Some resource still says 'VLAN' in log even if VXLAN is used
- in UI, "Network - GuestNetworks" dosen't display VNI
-- VLAN ID field displays "N/A"
- Documentation!

Signed-off-by : Toshiaki Hatano <haeena@haeena.net>
2013-09-26 23:37:18 +09:00
Edison Su
81ff4795df fix compile errors 2013-09-25 17:59:54 -07:00
Edison Su
9baa45308c CLOUDSTACK-4650: change volume state during snapshot only 2013-09-25 16:33:10 -07:00
Edison Su
7d8a7f855d CLOUDSTACK-4627: fix NPE in vm migration 2013-09-25 16:32:40 -07:00
Edison Su
2227eb191a CLOUDSTACK-3535: fix regression introduced in 5d9fa5d42e13a8c8ee10df14c466f66de678e954 2013-09-25 16:16:34 -07:00
Edison Su
aa59b6f34d CLOUDSTACK-4507: fix NPE when taking snapshot 2013-09-25 16:09:00 -07:00
Edison Su
f4dbf8786f CLOUDSTACK-4477: in order to select hypervisor host which can access storage pool, need to check storage_pool_host_ref
Conflicts:

	engine/storage/integration-test/test/org/apache/cloudstack/storage/test/DirectAgentManagerSimpleImpl.java
	engine/storage/integration-test/test/org/apache/cloudstack/storage/test/EndpointSelectorTest.java
	engine/storage/integration-test/test/org/apache/cloudstack/storage/test/FakeDriverTestConfiguration.java
2013-09-25 16:08:41 -07:00
Edison Su
a82b179878 add table lock on snapshot, during taking snapshot
Conflicts:

	engine/storage/src/org/apache/cloudstack/storage/image/db/SnapshotDataStoreDaoImpl.java
2013-09-25 16:03:59 -07:00
Edison Su
b5f7e307a1 CLOUDSTACK-4456:
CLOUDSTACK-4457:
CLOUDSTACK-4459:
harden kvm getvolume. It's possible that one volume created on other kvm host, won't show up on another host, try more times to refresh storage pool if volume won't shown up

Conflicts:

	engine/storage/integration-test/test/org/apache/cloudstack/storage/test/FakeDriverTestConfiguration.java
	plugins/hypervisors/kvm/src/com/cloud/hypervisor/kvm/storage/KVMStorageProcessor.java
2013-09-25 16:01:45 -07:00
Edison Su
7b6aebc102 add test
Conflicts:

	engine/storage/integration-test/test/org/apache/cloudstack/storage/test/FakeDriverTestConfiguration.java
2013-09-25 15:58:46 -07:00
Edison Su
b3ac12e171 delete snapshot_store_ref if the snapshot is in error state 2013-09-25 15:51:55 -07:00
Darren Shepherd
9fb0a1a619 Don't check implementation version of Object for DatabaseUpgradeChecker 2013-09-25 14:34:14 +02:00
Alena Prokharchyk
29b4cde04a CS-18283: 2.2.x to 4.2 upgrade - corrected the Service Provider name for the Network offeirng that can be used in VPC (from VirtualRouter to VpcVirtualRouter) 2013-09-24 11:44:46 -07:00
Wei Zhou
62d49b3524 CLOUDSTACK-4716: upgrade resource count (cpu,memory,primary_storage,secondary_storage) in the upgrade to 4.2
(cherry picked from commit 38bbfdc89a50bbb9464700d202d1cfa7b7955953)

Signed-off-by: Wei Zhou <w.zhou@leaseweb.com>
2013-09-23 14:19:03 +02:00
Alena Prokharchyk
2fa5a5ae97 CLOUDSTACK-4704: 41-42 db upgrade - populate vpc_service_map table with the services/providers supported by VPC
(cherry picked from commit 798f34a49cbfbb3a475f3dadf62d1ac1b8dfa510)

Signed-off-by: Wei Zhou <w.zhou@leaseweb.com>
2013-09-23 14:18:41 +02:00
Hugo Trippaers
15a97ec412 Cleanup pom.xml in various projects to properly use managed versions and other defaults 2013-09-21 17:21:06 +08:00
Hugo Trippaers
d37b87d97a Fix a few xml wellformedness issues 2013-09-21 14:58:56 +08:00