You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by Sanjay Tripathi <sa...@citrix.com> on 2013/07/03 13:21:23 UTC
Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives java
NPE.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/
-----------------------------------------------------------
Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
Bugs: CLOUDSTACK-3184
Repository: cloudstack-git
Description
-------
CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
2. Stop this VM.
3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
So added null check for displayName in if condition.
Diffs
-----
server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
Diff: https://reviews.apache.org/r/12243/diff/
Testing
-------
Same as Steps mentioned in the description.
Thanks,
Sanjay Tripathi
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by ASF Subversion and Git Services <as...@urd.zones.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22717
-----------------------------------------------------------
Commit 31df729008c748e6eafe49ff86e1da618013c551 in branch refs/heads/master from Sanjay Tripathi
[ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=31df729 ]
CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
Signed-off-by: Prasanna Santhanam <ts...@apache.org>
- ASF Subversion and Git Services
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by ASF Subversion and Git Services <as...@urd.zones.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22716
-----------------------------------------------------------
Commit 9f0c9ee20c1a65d427702a330798512e7297e322 in branch refs/heads/master from Prasanna Santhanam
[ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=9f0c9ee ]
CLOUDSTACK-3184: integration test for the updateVirtualMachine
updateVirutalMachine fails if no args are passed. this test also further
verifies that the displayname is changed when vm is started up
successfully.
Signed-off-by: Prasanna Santhanam <ts...@apache.org>
- ASF Subversion and Git Services
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by ASF Subversion and Git Services <as...@urd.zones.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22724
-----------------------------------------------------------
Commit b99355698823bf7fecfa4fddcc63e5b0e76c4931 in branch refs/heads/4.2 from Sanjay Tripathi
[ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=b993556 ]
CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
Signed-off-by: Prasanna Santhanam <ts...@apache.org>
(cherry picked from commit 31df729008c748e6eafe49ff86e1da618013c551)
- ASF Subversion and Git Services
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by ASF Subversion and Git Services <as...@urd.zones.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22726
-----------------------------------------------------------
Commit 6b3257781173f11113596114c5b19366e72ffb46 in branch refs/heads/master-6-17-stable from Sanjay Tripathi
[ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=6b32577 ]
CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
Signed-off-by: Prasanna Santhanam <ts...@apache.org>
(cherry picked from commit 31df729008c748e6eafe49ff86e1da618013c551)
- ASF Subversion and Git Services
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by ASF Subversion and Git Services <as...@urd.zones.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22725
-----------------------------------------------------------
Commit 8526a6f8f9130a757a2e54e968965052dcc054e4 in branch refs/heads/master-6-17-stable from Prasanna Santhanam
[ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=8526a6f ]
CLOUDSTACK-3184: integration test for the updateVirtualMachine
updateVirutalMachine fails if no args are passed. this test also further
verifies that the displayname is changed when vm is started up
successfully.
Signed-off-by: Prasanna Santhanam <ts...@apache.org>
(cherry picked from commit 9f0c9ee20c1a65d427702a330798512e7297e322)
- ASF Subversion and Git Services
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by ASF Subversion and Git Services <as...@urd.zones.apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22723
-----------------------------------------------------------
Commit 614d42dda26f4b1f688f65f597116b2bb5b3d5a7 in branch refs/heads/4.2 from Prasanna Santhanam
[ https://git-wip-us.apache.org/repos/asf?p=cloudstack.git;h=614d42d ]
CLOUDSTACK-3184: integration test for the updateVirtualMachine
updateVirutalMachine fails if no args are passed. this test also further
verifies that the displayname is changed when vm is started up
successfully.
Signed-off-by: Prasanna Santhanam <ts...@apache.org>
(cherry picked from commit 9f0c9ee20c1a65d427702a330798512e7297e322)
- ASF Subversion and Git Services
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by Prasanna Santhanam <ts...@apache.org>.
> On July 3, 2013, 2:09 p.m., Prasanna Santhanam wrote:
> > 31df729008c748e6eafe49ff86e1da618013c551 for the fix.
> >
> > Added an integration test to back up the API issue:9f0c9ee20c1a65d427702a330798512e7297e322
Test passes after the fix. Please close the review as submitted.
$ nosetests --with-marvin --marvin-config=setup/dev/advanced.cfg test/integration/component/test_update_vm.py --load
Test Update VirtualMachine Name ... ok
----------------------------------------------------------------------
Ran 1 test in 21.552s
OK
- Prasanna
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22718
-----------------------------------------------------------
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>
Re: Review Request 12243: CLOUDSTACK-3184: updateVirtualMachine api gives
java NPE.
Posted by Prasanna Santhanam <ts...@apache.org>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/12243/#review22718
-----------------------------------------------------------
Ship it!
31df729008c748e6eafe49ff86e1da618013c551 for the fix.
Added an integration test to back up the API issue:9f0c9ee20c1a65d427702a330798512e7297e322
- Prasanna Santhanam
On July 3, 2013, 11:21 a.m., Sanjay Tripathi wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/12243/
> -----------------------------------------------------------
>
> (Updated July 3, 2013, 11:21 a.m.)
>
>
> Review request for cloudstack, Devdeep Singh and Prasanna Santhanam.
>
>
> Bugs: CLOUDSTACK-3184
>
>
> Repository: cloudstack-git
>
>
> Description
> -------
>
> CLOUDSTACK-3184: updateVirtualMachine api gives java NPE.
>
> This bug is not reproducible from CloudStack UI. Steps to reproduce this bug:
>
> 1. Deploy a VM without passing any parameters in Name and Description (last step in deploy VM wizard).
> 2. Stop this VM.
> 3. Fire updateVIrtualMachine API without passing "displayName" parameter, you'll see NPE in MS logs. Do not try with UI because UI will pass displayName paramter with blank value.
>
> There isn't any null check for displayName parameter and it is null because initially it was not set during the VM deployment and afterwards we are not passing displayName paramter in the API.
>
> So added null check for displayName in if condition.
>
>
> Diffs
> -----
>
> server/src/com/cloud/vm/UserVmManagerImpl.java a59fa5b
>
> Diff: https://reviews.apache.org/r/12243/diff/
>
>
> Testing
> -------
>
> Same as Steps mentioned in the description.
>
>
> Thanks,
>
> Sanjay Tripathi
>
>