8941 Commits

Author SHA1 Message Date
Abhinandan Prateek
d8def3dc0b CLOUDSTACK-8164: Look for all host to avoid NPE
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit a1a601be5a08a42739c3ef999f551db1b7bd7749)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-01-19 11:30:49 +05:30
cloudtrends
5028874e1c under windows the publicKeyPath and privateKeyPath should replace from \ to / when send them into injectkeys.py , and use isOnWindows function . thanks karuturi kindly tips.
Signed-off-by: Rajani Karuturi <rajanikaruturi@gmail.com>

This closes #66
2015-01-16 11:33:00 +05:30
cloudtrends
4c30636c22 under windows the publicKeyPath and privateKeyPath should replace from \ to / when send them into injectkeys.py
Signed-off-by: Rajani Karuturi <rajanikaruturi@gmail.com>

This closes #66
2015-01-16 11:33:00 +05:30
Rohit Yadav
71a0148565 CLOUDSTACK-7219: Fix NPE, log warning when config item is missing from scope
- Cherry picked from Daan's fix 63fbd16dd11388bd93cdbec4ea7fe6de37aa7fc5
- Added another check if configDepot returned null
- Removed developer prefill values

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit 188924751ed87a01541a094e03e958cd8d01653b)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-01-15 19:19:46 +05:30
Pierre-Yves Ritschard
b2393c31ed move ConstantTimeComparator to utils 2015-01-14 12:14:00 +01:00
Pierre-Yves Ritschard
9b4e39e837 Use constant-time comparison functions when checking signatures
This limits the likeliness of timing attacks against the API.
See http://codahale.com/a-lesson-in-timing-attacks/ for the
full rationale.

Conflicts:
	server/src/com/cloud/api/ApiServer.java
	server/src/com/cloud/user/AccountManagerImpl.java
2015-01-14 11:32:29 +01:00
Rohit Yadav
185f7e0152 CLOUDSTACK-8155: Remove unwanted whitespaces from json response
This removes extra whitespaces from the JSON serialized response.
After the fix, tested to work with:
- Present UI
- CloudMonkey
- Old buggy json parsers

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit 921ad057def3015cda9d9f5861c9be29a88b148e)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2015-01-14 02:43:54 +05:30
Kishan Kavala
f767adfe71 Bug-Id: CLOUDSTACK-3439: Include dynamically created nics in Prepare for migration command in KVM 2015-01-07 14:52:42 +05:30
Kishan Kavala
a520309190 Bug-Id: CLOUDSTACK-7395: reverted 0560254c04425705530a23a93002daede4b6dc3c partially. Allow multiple networks with LB service 2015-01-07 14:33:31 +05:30
Kishan Kavala
01a325b2bf Network Id for direct-network should not be included in usage record response. Direct network stats have network_id = 0. Ignore network with id = 0 in usage record 2015-01-07 14:17:30 +05:30
Kishan Kavala
9eb8d538dd For volumes created from template, do not log offering ID in VOLUME.CREATE in usage_event. Moved offering type to DiskOffering interface 2015-01-07 12:31:41 +05:30
Kishan Kavala
4ac96d637c Trigger user stats aggregation job at midnight in usage aggregation timezone 2015-01-07 11:17:24 +05:30
Daan Hoogland
3cba1c41fb CID-1114614 dead code removed 2015-01-06 16:47:32 +01:00
Daan Hoogland
e8a54f471c CID-1114606 use of MAX_VALUE and longValue() on Integer 2015-01-06 16:24:29 +01:00
Wei Zhou
84c44b6314 CLOUDSTACK-8140: CS fails to start after secstorage/consoleproxy.service.offering is set to uuid 2015-01-06 10:23:44 +01:00
Wei Zhou
93429443d5 CLOUDSTACK-8063: list secondary Ips information on non-default nics in VM response 2015-01-05 11:22:14 +01:00
Rajesh Battala
c7b23d0a10 CLOUDSTACK-6920 Support listing of LBHealthcheck policy with LBHealthcheck policy ID 2014-12-26 21:01:03 +05:30
Likitha Shetty
15b348632d CLOUDSTACK-8129. Cold migration of VM across VMware DCs leaves the VM behind in the source host.
If VM has been cold migrated across different VMware DCs, then unregister the VM from source host.
2014-12-26 11:07:30 +05:30
Likitha Shetty
ff7997a2b1 CLOUDSTACK-8127. VM name not displayed after attaching data disk to a VM.
If user hasn't supplied a display name for a VM, default it to VM name in listVolume response.
This behaviour is identical to listVirtualMachine response.
2014-12-24 15:21:34 +05:30
Likitha Shetty
a5a65c7b55 CLOUDSTACK-8122. Handle NPE thrown during migration failures.
When migration fails instead of returning NULL, throw the exception.
2014-12-24 13:33:11 +05:30
Likitha Shetty
4d7ede535d CLOUDSTACK-8119. Propagate error message to UI for attach/detach volume failure operations.
For AttachVolume/DetachVolume API command, improve user error message in case of RuntimeException by throwing the exception instead of 'Unexpected Exception'.
2014-12-24 11:29:03 +05:30
Likitha Shetty
5f9e4fddf3 CLOUDSTACK-8112. CS allows creation of VM's with the same Display name when vm.instancename.flag is set to true.
During VM creation, if vm.instancename.flag is set to true and hypervisor type is VMware, check if VM with the same hostname already exists in the zone.
2014-12-23 14:00:32 +05:30
Koushik Das
106ec718fc Revert "CLOUDSTACK-7872: network getting shutdown inspite of running VM's in the network"
This reverts commit 709bf074de9f8f22e6a71362551c4867be884e4b.

Network GC is broken with out-of-band VM movements due to the original commit, so reverting.
2014-12-23 12:13:51 +05:30
Koushik Das
331e257ca0 CLOUDSTACK-8103: Vmsync marks VM as stopped even after failing to stop it in HV
During vmsync if StopCommand (issued as part of PowerOff/PowerMissing report) fails to stop VM (since VM is running on HV),
don't transition VM state to "Stopped" in CS db. Also added a check to throw ConcurrentOperationException if vm state is not
"Running" after start operation.
2014-12-22 10:52:13 +05:30
Min Chen
ea634550fc CLOUDSTACK-8101: volume sync not working as expected - MS restart during upload volume leaves volume in hung state. 2014-12-19 15:51:52 -08:00
Min Chen
d304409c98 CLOUDSTACK-8093:Not able to list shared templates by passing id. 2014-12-18 10:00:18 -08:00
Saksham Srivastava
4821bfffe2 CLOUDSTACK-8091: Stale entry exists for a VM NIC even after an exception while adding a new nic to vm 2014-12-18 17:45:34 +05:30
Saksham Srivastava
1df0453d27 CLOUDSTACK-8088: VM scale up is failing in vmware with Unable to execute ScaleVmCommand due to java.lang.NullPointerException 2014-12-18 14:27:55 +05:30
Edison Su
b036c32bfc if concurrent snapshot happening on the same vm, throw invalid parameter
exception to user.
Reviewed-by: Frank
2014-12-17 14:35:15 -08:00
Edison Su
b40d9c23fc if local storage is in maitenance mode or removed, won't change its
status in case of mgt server restart
Reviewed-by:Frank
2014-12-17 14:34:23 -08:00
Edison Su
5a10a4725d add event for volume migration
Reviewed-by: Frank
2014-12-17 14:33:06 -08:00
Prachi Damle
f5d4736c87 CLOUDSTACK-8079: If the cluster capacity threshold is reached, HA-enabled VM is not migrated on another host during HA
Changes:
-  When there is HA we try to redeploy the affected vm using regular planners and if that fails we retry using the special planner for HA (which skips checking disable threshold)
Now because of job framework the InsufficientCapacittyException gets masked and the special planners are not called. Job framework needs to be fixed to rethrow the correct exception.
- Also the VM Work Job framework is  not setting the DeploymentPlanner to the VmWorkJob.  So the HA Planner being passed by HAMgr was not getting used.
- Now the job framework sets the planner passed in by any caller of the VM Start operation, to the job
2014-12-17 11:43:07 -08:00
Prachi Damle
74720830cd CLOUDSTACK-8078: [Automation] Deletion of Affinity Groups - CloudRuntimeException: No Event Pubish can be wrapped within DB Transaction!
Changes:
-     The event of deleteing an affinity group is published on the MessageBus so that IAM Service can listen and process the event, However the publish operation should not be handled within a DB transaction, since it may take longer and hold the DB transaction for long unnecessarily
-    Publish any events to MessageBus outside of the transaction
2014-12-17 11:43:05 -08:00
Sanjay Tripathi
9153b8bede CLOUDSTACK-8066: There is not way to know the size of the snapshot created. 2014-12-17 16:00:19 +05:30
Min Chen
cf1eed4811 CLOUDSTACK-8077: Not able to deploy VM using a shared template. 2014-12-16 16:39:56 -08:00
Wei Zhou
ff2ed33645 Fixed few coverity issues 2014-12-16 09:21:28 +01:00
Jayapal
85bb685662 CLOUDSTACK-8072: Fixed NPE in deleting default ACL items in default ACL 2014-12-15 16:37:35 +05:30
Sebastien Goasguen
cdc66c9e70 Small typo correction, exisits -> exists
Signed-off-by: Rajani Karuturi <rajanikaruturi@gmail.com>

This closes #57
2014-12-15 11:26:19 +05:30
Rohit Yadav
aa92f5d483 Merge remote-tracking branch 'anshulg/CLOUDSTACK-8067'
This closes #56

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-12-12 21:40:21 +05:30
Wei Zhou
19e99848c8 CLOUDSTACK-7882: SSH Keypair Creation/Selection in UI
Thanks Ilia Shakitko for the porting and testing.
2014-12-12 14:30:34 +01:00
Wei Zhou
c9d492d714 CLOUDSTACK-255: fix NPE in createPortForwardingRule due to no PortForwarding provider 2014-12-12 11:13:18 +01:00
Wei Zhou
fec31d53c3 CLOUDSTACK-8064: UpdatePortForwardingRuleCmd implementation 2014-12-12 10:19:06 +01:00
Wei Zhou
dcb7fcc6df CLOUDSTACK-8063: list secondary Ips information in VM response 2014-12-12 09:47:27 +01:00
Anshul Gangwar
1115bc9cc6 CLOUDSTACK-8067: Fixed NPEs in MS log related to console proxy VM 2014-12-12 11:24:28 +05:30
Min Chen
528bc80b4c CLOUDSTACK-8061: Extracting volume when it is in migrating state causes
both the operations to fail.
2014-12-11 09:53:33 -08:00
Wei Zhou
f5619f428b CLOUDSTACK-8051: fix NPE in updateNetwork due to static nat rules exist but no StaticNat provider 2014-12-11 15:13:36 +01:00
Rohit Yadav
fdb782ffcb CLOUDSTACK-8014: Fix NPE searching including removed templates
Steps to reproduce if you have this issue:
- Create a VM's volume snapshot
- Remove VM's template and mark the template as removed with timestamp in DB
- Restart mgmt server and create a volume out of snapshot you should get NPE

Fix: In `storagePoolHasEnoughSpace`, we're only searching for a VM's volume's
snapshot's template by Id and not including removed templates. This is a corner
case and NPE hits when template has been marked removed for a VM's volume's
template so we should search including removed templates.

Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
(cherry picked from commit f189c105d8dde5491697b171b969e757f8f15858)
Signed-off-by: Rohit Yadav <rohit.yadav@shapeblue.com>
2014-12-10 19:31:27 +05:30
Koushik Das
f6854bc984 CLOUDSTACK-8054: No event generated on host maintenance mode is completed
Added events for host maintenance start and completion
2014-12-10 10:18:34 +05:30
Koushik Das
ef9830d6a4 Merge branch '4.5'
Conflicts:
	server/src/com/cloud/network/router/VirtualNetworkApplianceManagerImpl.java
	tools/appliance/build.sh
2014-12-09 14:59:36 +05:30
Wei Zhou
13205e6be1 CLOUDSTACK-8050: VM Guest OS type does not update if template guestostype changes 2014-12-09 08:21:35 +01:00