Commit Graph

5015 Commits

Author SHA1 Message Date
Kelven Yang cd13762e44 Console proxy refactoring incremental check-in - new VNC protocol implementation 2012-05-01 13:45:15 +01:00
Alena Prokharchyk 0077234576 Fixed unittest and some issues with 2.2.14-3.0 upgrade 2012-05-01 13:34:05 +01:00
Vijayendra Bhamidipati 1d749bb9d3 Bug 13127: API error text refer to database ids instead of uuids
Description:

	Modified the IdentityTypeAdapter's custom serializer to
	identify whether this is an exception response that is being
	serialized, by checking if the idFieldName is set. If so,
	serialize both uuid and the uuidProperty (for eg, zoneId and
	"zoneId" (string)) and pass back the json representation of that.

	Modified XML serializer also to build a list of uuids+fieldnames.

	Introduced a new field "cserrorcode" in ExceptionResponse. This
	refers to an error code that can be according to the specific
	Exception being thrown. This will be serialized as usual. There
	shouldn't be any need to do a db lookup for conversion for these
	error codes.
2012-05-01 13:28:22 +01:00
Vijayendra Bhamidipati bea85d47a7 Bug 13127: API error text refer to database ids instead of uuids
Description:

	Modify Exception handling to enable addition of multiple
	uuids in a single exception thrown by API functions. Both
	XML and JSON outputs will store all uuids and Fieldnames.
	This will make it easier to provide more information when
	an exception occurs - for example, a zone id, a cluster id,
	host id, and then a specific property id.
2012-05-01 13:28:21 +01:00
Vijayendra Bhamidipati 094f01be41 Bug 13127: API error text refer to database ids instead of uuids
Description:

	Added a field name for the db id in the IdentityProxy class, and
	modified setProxyObject() to take an additional id name parameter.
	This will let us know the name of the uuid that we are returning.
	E.g.- domainId, zoneId, etc. The client can view this field in
	the json/xml output. Modified the JSON/XML serialization routines
	to append this new parameter to the serialized output for Exception
	Responses.
2012-05-01 13:28:20 +01:00
Vijayendra Bhamidipati 7ea32a4471 Bug 13127: API error text refer to database ids instead of uuids
Description:

	1) Put in an IdentityProxy object in the ExceptionResponse class.
	   This allows us to copy over the IdentityProxy object contained
	   in the exception caught by handlerequest() when thrown by the
	   command's execute() method, into the Response object that is
	   prepared to return an exception response to the calling API
	   invocation.

	2) Modified the GSON serialization method to conver the entire
	   exception object into JSON format and not just the error text.

	3) Modify the updateDomain API to populate the exception it throws
	   upon detecting a duplicate domain to include the tablename and
	   domain db id in the exception's IdentityProxy object.

	NOTE:
	1) We can modify the base exception classes and the ExceptionResponse
	   class to contain a list of IdentityProxy objects rather than a
	   single one.
	2) We will need to modify all commands such that wherever applicable
	   (wherever a db id is involved), they populate the IdentityProxy
	   object(s) before throwing an exception.
2012-05-01 13:28:19 +01:00
Vijayendra Bhamidipati b4cefb4cc6 Bug 13127: API error text refer to database ids instead of uuids
Description:

	1) Added a setProxyObject() method to CloudException and RuntimeCloudException
	2) Modified a bunch of throw exceptions in NetworkManagerImpl.java to call setProxyObject() before throwing an exception.
	3) Changed scope of ProxyIdentity attribute to protected.
	4) Added routines to ServerApiException to get/set IdentityProxy object, and
	   routine in RuntimeCloudException to get the Idproxy object.
	5) Modified the exception handling around the dispatcher and handlerequest()
	   to copy over the IdentityProxy information before rethrowing an exception
	   eventually back to handle().
	6) Removed duplicate IdentityProxy object in ServerApiException.
	   It was extending RuntimeCloudException which already had an
	   IdentityProxy object.
2012-05-01 13:28:16 +01:00
Vijayendra Bhamidipati efdaa4d110 Bug 13127: API error text refer to database ids instead of uuids
Description:

1)	Moved RuntimeCloudException from api/ to utils/.

	Added simple constructor to RuntimeCloudException.

	Modified all classes that extended RuntimeException
	to extend RuntimeCloudException. These classes
	are listed below:

		ServerApiException
		CloudAuthenticationException
		CloudExecutionException
		AsyncCommandQueued
		HypervisorVersionChangedException
		RuntimeCloudException

2)	Added overloaded constructed to CloudException.
	Modified all classes that extend Exception to extend CloudException instead.
	These classes are listed below:

		ConcurrentOperationException
                ConflictingNetworkSettingsException
                ConnectionException
                DiscoveryException
                InsufficientCapacityException
                ManagementServerException
                ResourceUnavailableException
                VirtualMachineMigrationException
                AgentControlChannelException
                OperationTimedoutException.java
                UnsupportedVersionException.java
                UsageServerException.java
                UnableDeleteHostException.java
                AgentAuthnException.java
                HttpCallException.java
                ActiveFencingException.java
                ClusterInvalidSessionException.java
                GreTunnelException.java
                OvsVlanExhaustedException.java
2012-05-01 13:21:44 +01:00
U-CITRITE\vijayendra1 89db087981 Bug 13127: API error text refer to database ids instead of uuids
Description:

1)	Adding two new classes, CloudException and RunTimeCloudException.
	The former extends Exception and the latter RunTimeException.
	These will be used by classes that formerly directly extended
	Exception and RuntimeException. These two classes have an attribute
	of type IdentityProxy to enable exceptions fill in db ids in separate
	attribute fields rather than in a string. Doing so will allow the
	serialization module (GSON for JSON and other for XML) to kick in
	and convert this db id to a uuid in ApiServer.java just before the
	JSON/XML responses are sent out.

2)	Moving IdentityProxy.java from api/ to utils/ since
	both CloudException and RuntimeCloudException refer to it.

3)	Changing references to IdentityProxy class from api/ to utils/.

4)	While rebasing to master, a new file was added, merging
	api/src/com/cloud/api/response/IsoVmResponse.java to this diff.
2012-05-01 13:21:42 +01:00
anthony 45051d7a9f bug 13832: fixed NPE
status 13832: resolved fixed
2012-05-01 13:15:36 +01:00
Likitha Shetty daf2af7e45 Bug 4644 (Pranav) 2012-05-01 13:08:19 +01:00
abhi b5654a6fd1 bug 13673: stopping alien VMs during sync for Xenserver 2012-05-01 13:00:03 +01:00
Alena Prokharchyk a3fb4cf9c1 Update apikey/secretkey in transaction 2012-05-01 11:02:25 +01:00
Nitin Mehta baf6b6eb82 Bug 13591: Remove unwarranted log messages that we are printing with every answer recieved from the agent.
Reviewed-By: Kishan
2012-05-01 11:02:22 +01:00
kishan f2a08afd6f bug CS-14695: Encrypt VNC password during 3.0.0 upgrade
status CS-14695: resolved fixed
reviewed-by: Abhi
2012-05-01 11:16:24 +05:30
prachi 9a4f5f90a2 Fix error from merge 2012-04-30 17:08:36 -07:00
Likitha Shetty 6ab04076b5 Implementation of api 'markDefaultZoneForAccount'(to enable a user to mark a zone as default for an account).
reviewed-by: prachi
2012-04-30 17:08:32 -07:00
prachi 38fffccb58 - Changes to EC2MainServlet to turn down request in enable.ec2.api is 'false'
- runInstances now calls CS to get the matching serviceOffering for the EC2 instanceType
2012-04-30 17:08:19 -07:00
prachi 1fa596fcf5 DeployVMCmd: Do not place the instance in default security group if groupId is provided 2012-04-30 17:07:30 -07:00
prachi 46ccc1ec79 Fixes related to
- DescribeImages
- Fix Vm current state in runInstances
- Set hypervisor to UserVm response in CloudStack
2012-04-30 17:07:28 -07:00
Alena Prokharchyk e5ed22f55f bug 14694: when select valid clusters, exclude the removed ones
status 14694: resolved fixed
2012-04-30 13:10:49 -07:00
Abhi 007f291235 adding a plaintext authenticator 2012-04-30 16:41:35 +05:30
Nitin Mehta 8de5da1c91 bug CS-10789: Decrement and increment the resource count on volume correctly. 2012-04-30 11:15:12 +05:30
Nitin Mehta 6a056ad139 bug CS-10789: More changes for the imageformat, introdueced new column in db for the format, created scripts for doffernt hypervisors ...and the list goes on. 2012-04-30 11:14:43 +05:30
Nitin Mehta cf0b36319d bug CS-10789: Make the custome disk offering as system so that its not availble to the regular user.
Reviewed By: Kishan
2012-04-30 11:13:01 +05:30
Nitin Mehta c2d51d7038 bug CS-10789: Adding more code changes for usage, delete volume . 2012-04-30 11:11:54 +05:30
Nitin Mehta 10b32ce882 bug CS-10789: Adding volume sync and delete functionality. 2012-04-30 11:11:26 +05:30
Nitin Mehta 8196132f68 bug CS-10789: Preliminary upload and attach changes work . 2012-04-30 11:09:37 +05:30
Nitin Mehta 2d7471adb5 Bug 10808: More changes for uploadVolume. Create framework for upload volume progress communication between MS and SSVM. 2012-04-30 09:46:23 +05:30
Nitin Mehta 02407c48f3 Bug 10808: Add Upload Volume api and do validation. 2012-04-30 09:43:23 +05:30
Abhi 6726f3b0d0 bug CS-14663: accepting encoded password for MD5 2012-04-28 12:30:29 +05:30
Salvatore Orlando ce56ddf75a CS-14606: Restoring config parameter which was accidentally removed 2012-04-27 17:13:10 +01:00
Salvatore Orlando 6e024e945d CS-14606: Change name for config parameter 2012-04-27 16:38:33 +01:00
Alena Prokharchyk 7e4c5e1267 CS-14637: db upgrade - fixed inconsistencies in category/component fields for a bunch of global config variables 2012-04-26 10:09:53 -07:00
Salvatore Orlando 23b20e3b04 Merge branch '3.0.x' of ssh://git.cloud.com/var/lib/git/cloudstack-oss into 3.0.x 2012-04-25 20:06:26 +01:00
Alena Prokharchyk 1c9af77f59 Set ha host to false when no ha tag is enabled 2012-04-25 11:04:07 -07:00
Salvatore Orlando 88131e5db6 CS-14605: OVS cleanup
Fix syntax errors in ConfigurationManager and Resource Manager test

Conflicts:

	server/src/com/cloud/network/ovs/OvsTunnelManagerImpl.java
	server/test/com/cloud/agent/manager/ResourceManagerTest.java
2012-04-25 15:11:05 +01:00
Salvatore Orlando 33a2b17972 CS-14605: OVS Tunnel Manager Clean-up
1) Remove old VLAN-in-overlay manager
2) Remove unused DAO objects
3) Fix code using removed object (all stale lines)

Conflicts:

	server/src/com/cloud/network/ovs/GreTunnelException.java
	server/src/com/cloud/network/ovs/OvsVlanExhaustedException.java
	server/src/com/cloud/network/ovs/dao/OvsTunnelAccountDao.java
	server/src/com/cloud/network/ovs/dao/OvsTunnelAccountDaoImpl.java
	server/src/com/cloud/network/ovs/dao/OvsTunnelAccountVO.java
2012-04-25 15:03:47 +01:00
Salvatore Orlando f7836ba61c Merge branch '3.0.x' of ssh://git.cloud.com/var/lib/git/cloudstack-oss into 3.0.x 2012-04-25 09:50:48 +01:00
Alena Prokharchyk 4e3bdb62d2 Account specific vlan ranges - fixed deleteVlanRange
Conflicts:

	server/src/com/cloud/configuration/ConfigurationManagerImpl.java
2012-04-24 17:16:58 -07:00
Alena Prokharchyk 319d4c5cfd Catch all exceptions when change engine and row_format - can fail when table is full. Just skip as its not a critical fix 2012-04-24 15:49:14 -07:00
Salvatore Orlando 8779f0ed25 CS-14270: return VLAN id only if the broadcast URI starts with 'vlan' 2012-04-24 21:34:10 +01:00
Alena Prokharchyk ccd0472201 CS-14622: fixed adding vlan range per account - associate it with the Guest network, not public
Conflicts:

	server/src/com/cloud/configuration/ConfigurationManagerImpl.java
2012-04-24 11:42:53 -07:00
anthony f0a4044d29 add CentOS 6.0, CentOS 5.7, RHEL 5.7 support for XenServer 6.0.2 2012-04-24 10:50:34 -07:00
Salvatore Orlando ef13158c2b CS-14437: Fixing remaining merge issues affecting tunnel creation
Tunnel networks now work on this branch
(VLAN networks never stopped working)
2012-04-24 15:21:41 +01:00
Salvatore Orlando 48b6236c64 Fixing merge issues for OVS tunnel manager 2012-04-24 02:22:10 +01:00
Salvatore Orlando 6f3ab6de5d Removing basic connectivity provider and OVS network offering as not
needed for Bonita
2012-04-24 02:20:39 +01:00
Salvatore Orlando 421862216e Now finding the IP address also for the remote endpoint
Conflicts:

	server/src/com/cloud/network/ovs/OvsTunnelManagerImpl.java
2012-04-24 02:20:39 +01:00
Salvatore Orlando 1ddcdb25c1 Forgot to add new dao into component library! 2012-04-24 02:20:39 +01:00
Salvatore Orlando cc344ad038 Adding DB support for interfaces OVS tunnel manager will use as GRE endpoints
Conflicts:

	server/src/com/cloud/network/ovs/OvsTunnelManagerImpl.java
2012-04-24 02:20:38 +01:00
Salvatore Orlando 24a567ac43 Removing superfluous log statements 2012-04-24 02:20:38 +01:00
Salvatore Orlando 275840bcdb Now using vnets instead of network id for creating networks
Fixed issues with vif scripts on 5.6FP1
Fixed ipv6 issue on 5.6FP1
Plus other various fixes and improvements

Starting to remove debug code
NOTE: Network is configured correctly but instances do not start. Possibly indefinite wait occuring on some commands

Conflicts:

	server/src/com/cloud/api/ApiResponseHelper.java
2012-04-24 02:20:38 +01:00
Salvatore Orlando 2d12cfbc87 Fixing remaining issues with per-VIF flow script and removing version-specific scripts.
Now generating XSnetwork names using gre keys

Plus other minor corrections

Conflicts:

	server/src/com/cloud/network/ovs/OvsTunnelManagerImpl.java
	server/src/com/cloud/resource/ResourceManagerImpl.java
2012-04-24 02:20:38 +01:00
Salvatore Orlando 58165221ef Now using vnets instead of network id for creating networks
Fixed issues with vif scripts on 5.6FP1
Fixed ipv6 issue on 5.6FP1
Plus other various fixes and improvements

Starting to remove debug code
NOTE: Network is configured correctly but instances do not start. Possibly indefinite wait occuring on some commands

Conflicts:

	server/src/com/cloud/network/NetworkManagerImpl.java
	server/src/com/cloud/network/guru/OvsGuestNetworkGuru.java
	server/src/com/cloud/network/ovs/OvsTunnelManagerImpl.java
2012-04-24 02:20:37 +01:00
Salvatore Orlando f786505a1b Adding Missing file to source control 2012-04-24 02:20:37 +01:00
Salvatore Orlando 8c398654d3 Open vSwitch tunnel manager
Applying patch with new ovs-tunnel-manager on top of cloudstack oss-master

Conflicts:

	api/src/com/cloud/network/ovs/OvsCreateTunnelAnswer.java
2012-04-24 02:20:37 +01:00
Salvatore Orlando 6ca198e6f3 Bug 14370 - addSecondaryStorage always fails: "Can't find pod with specificied podId null"
status 14370: resolved fixed

Conflicts:

	server/src/com/cloud/resource/ResourceManagerImpl.java
2012-04-24 02:20:36 +01:00
Alena Prokharchyk 0527cad0b7 CS-14256: throw executionException when finalizeStart fails (no point to retry). 2012-04-23 15:56:10 -07:00
Abhi bfc4fe8ca5 bug CS-14593, CS-14541: fixed encryption issue 2012-04-23 15:08:35 +05:30
kishan d122637761 bug CS-14587: Process 500 rows at a time to encrypt vnc_password in vm_instance table. Added addtional logging.
status CS-14587: resolved fixed
reviewed-by: Alena
2012-04-22 22:33:22 +05:30
Alena Prokharchyk 5603359794 Fixed db upgrade bug: do vnc password encryption only for non-removed vms 2012-04-21 22:30:16 -07:00
Alena Prokharchyk 8973955350 More logging to the db upgrade 2012-04-21 22:29:43 -07:00
anthony 2c25be48e8 bug 14582: fix one big in upgrade from 2.1.4 to 3.0.2
status 14582: resolved
2012-04-20 17:06:03 -07:00
Alena Prokharchyk 7d3eea8225 Fixed db upgrade for 2.1-3.0 2012-04-20 12:00:24 -07:00
Kelven Yang 549a320832 Don't use dynamic quiried key size as it varies on different JVM implementation and security providers 2012-04-20 11:42:15 -07:00
kishan e730f888d1 bug CS-14576: Fail 2.2.14 to 3.0.0 upgrade if encryption is not enabled
status CS-14576: resolved fixed
reviewed-by: Nitin

Conflicts:

	server/src/com/cloud/upgrade/dao/Upgrade2214to30.java
2012-04-20 16:05:11 +05:30
Nitin Mehta d493262354 bug CS-14530: Whwnever creating an agent of type Routing update the capacity state as there is a transition in the resource state of the host.
Reviewed By: Kishan
2012-04-20 11:04:11 +05:30
Nitin Mehta 9f63a3d2bb bug CS-14530: Whenver adding a new capacity check the state of the resource - if its disabled/enabled.
Reviewed By: Kishan
2012-04-20 10:56:27 +05:30
Sheng Yang ea26cefbe5 CS-14542: Fix wrong traffic label for KVM agent 2012-04-19 18:24:15 -07:00
prachi a5fddd604a Bug 14158 - 2.2.x - 3.0 db upgrade for multiple physical networks
-Create multiple physical networks if there are distinct tags found in network_tags table.
-One physical network per tag.
-Currently all tags flow to xenserver traffic type label.
2012-04-19 15:11:32 -07:00
Kelven Yang 4d28e40c00 Hardening console proxy AJAX protocol to address security concerns 2012-04-19 12:07:35 -07:00
kishan 133745b652 bug CS-14566: set up physical networks before encrypting config values
status CS-14566: resolved fixed
reviewed-by: Nitin
2012-04-19 21:59:30 +05:30
Rajesh Battala d4396da506 CS-14546: Fixed bug Unable to view console in System and Guest VMs and Added Upgrade script 2012-04-19 15:05:42 +05:30
Likitha Shetty bbe4928546 Revert "Revert "Revert "CS-14546: Fixed bug Unable to view console in System and Guest VMs"""
This reverts commit bcfbc81de1.

Unable to view console in System and Guest VMs
2012-04-19 14:31:05 +05:30
Likitha Shetty bcfbc81de1 Revert "Revert "CS-14546: Fixed bug Unable to view console in System and Guest VMs""
This reverts commit 0147d878a5.

reverting as commit went on wrong e-mail id.
2012-04-19 14:24:08 +05:30
Likitha Shetty 0147d878a5 Revert "CS-14546: Fixed bug Unable to view console in System and Guest VMs"
This reverts commit 5465edf02f.
2012-04-19 14:18:02 +05:30
Likitha Shetty 5465edf02f CS-14546: Fixed bug Unable to view console in System and Guest VMs 2012-04-19 14:03:12 +05:30
Alena Prokharchyk d51d018a1b CS-14553: db upgrade - for default network offerings:
1) Change display text to match fresh 3.0.2
2) Delete lb service for the offerings using VR as a provider and not having source nat service
2012-04-18 17:10:41 -07:00
kishan b88019ad8f bug CS-14532: during 2211-2212 upgrade, do not add resource count entries for resourceTypes that were added in later releases
status CS-14532: resolved fixed
reviewed-by: Nitin
2012-04-18 15:40:30 +05:30
Alena Prokharchyk 1e8856efa0 CS-14512: fixed deployVm with ipToNetworkList when uuid is used for networkIds
Conflicts:

	server/src/com/cloud/api/ApiResponseHelper.java

Conflicts:

	server/src/com/cloud/api/ApiResponseHelper.java
2012-04-16 15:45:19 -07:00
Alena Prokharchyk 8bb5a96cbe CS-14297: added "forced" option to deleteStoragePool command. If forced=true, all destroyed volumes are marked as Expunged even when we can't reach primary storage at the moment of deletion. 2012-04-16 13:16:59 -07:00
Alena Prokharchyk c242a776a7 AdvanceStart: do cleanup() call with force=true when the start command wasn't sent to the backend yet 2012-04-13 17:18:48 -07:00
Sheng Yang 95d3be2d3a bug 14470: Return true for applyRules unless specified
Only DHCP entry need to know if no one apply the entries(when VM is starting
up), other rules should be safe when return true anyway.

status 14470: resolved fixed
2012-04-13 14:51:13 -07:00
Alena Prokharchyk f74e6128e9 Bug CS-14447: set crossZones attribute for the template before persisting it to the db 2012-04-13 14:16:06 -07:00
Abhi 341ad9444a bug CS-14466: removing blank statement 2012-04-13 13:42:25 +05:30
frank e26505f82d CS-14341 Order of Compute offerings does not stick
resolved fixed
2012-04-12 17:26:27 -07:00
Alena Prokharchyk 572abbf9d5 Added one more parameter - haHost(boolean) - to listHosts api command. The parameter identifies if the host is dedicated for ha only 2012-04-12 11:51:44 -07:00
Abhi 5709cc5832 bug CS-13303: updating resource state on upgrade 2012-04-12 17:47:34 +05:30
Abhi 7eb1330800 bug CS-13303: updating resource state on upgrade 2012-04-12 17:14:50 +05:30
frank 2530ea17dd CS-14429 Cloud db schema differences between fresh installed 3.0.2 & upgraded 3.0.2
do check befor droping index i_host__allocation_state`(`allocation_state`)
2012-04-11 17:25:15 -07:00
prachi 239a2193a9 Bug 14646 - Enabling Host into maintenance mode is stopping the VMs instead of live migrating them to other hosts in the cluster.
Changes:
-  While listing UP hosts in the cluster of the host, the query has changed and now also considers the Host 'resourceState' field and picks only those hosts that have value 'enabled'.
   This query result does not include the host being put in maintainance; unlike the earlier query that used to include it.
-  But the logic to find out if this is the last host in the Cluster is not updated and has a bug when it compares the list size.
- Fixed this.
2012-04-11 16:20:24 -07:00
Alena Prokharchyk be04f2bd63 Remove obsolete network_tags table as a part of db upgrade cleanup 2012-04-11 16:23:39 -07:00
Kelven Yang f38ba2efbe Complete XenServer Secure Console proxy implementation 2012-04-10 16:01:08 -07:00
Rajesh Battala f34c84c68f Xenserver Secure Console Proxy Phase I 2012-04-10 16:00:46 -07:00
Alena Prokharchyk 03a2140911 bug 14449: added logging to createVlanIpRange
status 14449: resolved fixed
2012-04-10 11:23:58 -07:00
Alena Prokharchyk cd774c9fab Db upgrade path for 3.0.2 to 3.0.3 2012-04-09 15:50:23 -07:00
Alena Prokharchyk b7f5bc099d bug 14622: introduced ha tagging for host
status 14622: resolved fixed
2012-04-09 15:17:13 -07:00
Abhi 8f08898fb7 bug CS-14396: the VMs with current host id should be listed here, probably this fix did not make to this branch, is there is 2.2.14 branch 2012-04-09 12:24:49 +05:30
Alena Prokharchyk 52ebc73b65 Return password as a result of startVm command if the vm was originally deployed with startVm=false parameter 2012-04-06 13:45:48 -07:00
Alena Prokharchyk d3bca8df8f bug 14615: deployVm can work 2 diff ways now: 1) Default way - create and start the vm. 2) Create the vm without starting it. Note that vm's volumes stay in Allocated state -not created on the backend till the point where vm starts
status 14615: resolved fixed
2012-04-06 11:30:26 -07:00