cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From sanjaytripa...@apache.org
Subject git commit: updated refs/heads/4.3-forward to cff312e
Date Thu, 30 Jan 2014 10:56:00 GMT
Updated Branches:
  refs/heads/4.3-forward 7255e50f2 -> cff312ef7


CLOUDSTACK-5660: Migrate vm live migration succeeds but throws error as "Failed to migrate
the system vm".


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/cff312ef
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/cff312ef
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/cff312ef

Branch: refs/heads/4.3-forward
Commit: cff312ef743763c69b0c3b0cfd9faf906f3cf22c
Parents: 7255e50
Author: Sanjay Tripathi <sanjay.tripathi@citrix.com>
Authored: Thu Jan 30 16:17:19 2014 +0530
Committer: Sanjay Tripathi <sanjay.tripathi@citrix.com>
Committed: Thu Jan 30 16:18:41 2014 +0530

----------------------------------------------------------------------
 server/src/com/cloud/vm/UserVmManagerImpl.java |  7 ++++++-
 ui/scripts/system.js                           | 12 ++++++------
 2 files changed, 12 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/cff312ef/server/src/com/cloud/vm/UserVmManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/vm/UserVmManagerImpl.java b/server/src/com/cloud/vm/UserVmManagerImpl.java
index 363c663..d9923d2 100755
--- a/server/src/com/cloud/vm/UserVmManagerImpl.java
+++ b/server/src/com/cloud/vm/UserVmManagerImpl.java
@@ -4216,7 +4216,12 @@ public class UserVmManagerImpl extends ManagerBase implements UserVmManager,
Vir
             collectVmDiskStatistics(uservm);
         }
         _itMgr.migrate(vm.getUuid(), srcHostId, dest);
-        return _vmDao.findById(vmId);
+        VMInstanceVO vmInstance = _vmInstanceDao.findById(vmId);
+        if (vmInstance.getType().equals(VirtualMachine.Type.User)) {
+            return _vmDao.findById(vmId);
+        } else {
+            return vmInstance;
+        }
     }
 
     private boolean checkIfHostIsDedicated(HostVO host) {

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/cff312ef/ui/scripts/system.js
----------------------------------------------------------------------
diff --git a/ui/scripts/system.js b/ui/scripts/system.js
index 960f1aa..72f9e33 100644
--- a/ui/scripts/system.js
+++ b/ui/scripts/system.js
@@ -2508,7 +2508,7 @@
                                                                     getUpdatedItem: function(json)
{
                                                                         //return json.queryasyncjobresultresponse.jobresult.systemvminstance;
   //not all properties returned in systemvminstance
                                                                         $.ajax({
-                                                                            url: createURL("listRouters&id="
+ json.queryasyncjobresultresponse.jobresult.systemvminstance.id),
+                                                                            url: createURL("listRouters&id="
+ json.queryasyncjobresultresponse.jobresult.systemvm.id),
                                                                             dataType: "json",
                                                                             async: false,
                                                                             success: function(json)
{
@@ -3030,7 +3030,7 @@
                                                                     getUpdatedItem: function(json)
{
                                                                         //return json.queryasyncjobresultresponse.jobresult.systemvminstance;
   //not all properties returned in systemvminstance
                                                                         $.ajax({
-                                                                            url: createURL("listInternalLoadBalancerVMs&id="
+ json.queryasyncjobresultresponse.jobresult.systemvminstance.id),
+                                                                            url: createURL("listInternalLoadBalancerVMs&id="
+ json.queryasyncjobresultresponse.jobresult.systemvm.id),
                                                                             dataType: "json",
                                                                             async: false,
                                                                             success: function(json)
{
@@ -3624,7 +3624,7 @@
                                                                     getUpdatedItem: function(json)
{
                                                                         //return json.queryasyncjobresultresponse.jobresult.systemvminstance;
   //not all properties returned in systemvminstance
                                                                         $.ajax({
-                                                                            url: createURL("listRouters&id="
+ json.queryasyncjobresultresponse.jobresult.systemvminstance.id),
+                                                                            url: createURL("listRouters&id="
+ json.queryasyncjobresultresponse.jobresult.systemvm.id),
                                                                             dataType: "json",
                                                                             async: false,
                                                                             success: function(json)
{
@@ -6788,7 +6788,7 @@
                                                                             getUpdatedItem:
function(json) {
                                                                                 //return
json.queryasyncjobresultresponse.jobresult.systemvminstance;    //not all properties returned
in systemvminstance
                                                                                 $.ajax({
-                                                                                    url:
createURL("listSystemVms&id=" + json.queryasyncjobresultresponse.jobresult.systemvminstance.id),
+                                                                                    url:
createURL("listSystemVms&id=" + json.queryasyncjobresultresponse.jobresult.systemvm.id),
                                                                                     dataType:
"json",
                                                                                     async:
false,
                                                                                     success:
function(json) {
@@ -7941,7 +7941,7 @@
                                                             getUpdatedItem: function(json)
{
                                                                 //return json.queryasyncjobresultresponse.jobresult.systemvminstance;
   //not all properties returned in systemvminstance
                                                                 $.ajax({
-                                                                    url: createURL("listRouters&id="
+ json.queryasyncjobresultresponse.jobresult.systemvminstance.id),
+                                                                    url: createURL("listRouters&id="
+ json.queryasyncjobresultresponse.jobresult.systemvm.id),
                                                                     dataType: "json",
                                                                     async: false,
                                                                     success: function(json)
{
@@ -9167,7 +9167,7 @@
                                                     getUpdatedItem: function(json) {
                                                         //return json.queryasyncjobresultresponse.jobresult.systemvminstance;
   //not all properties returned in systemvminstance
                                                         $.ajax({
-                                                            url: createURL("listSystemVms&id="
+ json.queryasyncjobresultresponse.jobresult.systemvminstance.id),
+                                                            url: createURL("listSystemVms&id="
+ json.queryasyncjobresultresponse.jobresult.systemvm.id),
                                                             dataType: "json",
                                                             async: false,
                                                             success: function(json) {


Mime
View raw message