You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cloudstack.apache.org by we...@apache.org on 2014/07/03 11:21:53 UTC

[1/5] git commit: updated refs/heads/4.3 to ec823db

Repository: cloudstack
Updated Branches:
  refs/heads/4.3 f6aff77b8 -> ec823db47


[UI] deploy vm to specified host in Infrastructure->Hosts page


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

Branch: refs/heads/4.3
Commit: c3cbb7972e16deca975723960e53cb78a0651b83
Parents: f6aff77
Author: Wei Zhou <w....@leaseweb.com>
Authored: Thu Jul 3 10:47:34 2014 +0200
Committer: Wei Zhou <w....@leaseweb.com>
Committed: Thu Jul 3 11:20:16 2014 +0200

----------------------------------------------------------------------
 ui/scripts/instanceWizard.js  | 3 +++
 ui/scripts/instances.js       | 3 +++
 ui/scripts/sharedFunctions.js | 1 +
 3 files changed, 7 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c3cbb797/ui/scripts/instanceWizard.js
----------------------------------------------------------------------
diff --git a/ui/scripts/instanceWizard.js b/ui/scripts/instanceWizard.js
index 4a740c6..4708866 100644
--- a/ui/scripts/instanceWizard.js
+++ b/ui/scripts/instanceWizard.js
@@ -813,6 +813,9 @@
             	});
             }
 
+            if (g_hostid != null)
+                array1.push("&hostid=" + g_hostid);
+
             $.ajax({
                 url: createURL('deployVirtualMachine'),
                 data: deployVmData,

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c3cbb797/ui/scripts/instances.js
----------------------------------------------------------------------
diff --git a/ui/scripts/instances.js b/ui/scripts/instances.js
index 896b535..dd33672 100644
--- a/ui/scripts/instances.js
+++ b/ui/scripts/instances.js
@@ -308,9 +308,12 @@
                 }
 
                 if ("hosts" in args.context) {
+                    g_hostid = args.context.hosts[0].id;
                     $.extend(data, {
                         hostid: args.context.hosts[0].id
                     });
+                } else {
+                    g_hostid = null;
                 }
 
                 if ("affinityGroups" in args.context) {

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/c3cbb797/ui/scripts/sharedFunctions.js
----------------------------------------------------------------------
diff --git a/ui/scripts/sharedFunctions.js b/ui/scripts/sharedFunctions.js
index 9fa70e3..86a4a92 100644
--- a/ui/scripts/sharedFunctions.js
+++ b/ui/scripts/sharedFunctions.js
@@ -20,6 +20,7 @@ var g_role = null; // roles - root, domain-admin, ro-admin, user
 var g_username = null;
 var g_account = null;
 var g_domainid = null;
+var g_hostid = null;
 var g_loginCmdText = null;
 var g_enableLogging = false;
 var g_timezoneoffset = null;


[2/5] git commit: updated refs/heads/4.3 to ec823db

Posted by we...@apache.org.
[UI] show all secondary ips in VM NIC page


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

Branch: refs/heads/4.3
Commit: 9b7ac9dfaca0b439f1ca31da6db04f068c5ca02b
Parents: c3cbb79
Author: Wei Zhou <w....@leaseweb.com>
Authored: Thu Jul 3 11:05:07 2014 +0200
Committer: Wei Zhou <w....@leaseweb.com>
Committed: Thu Jul 3 11:20:22 2014 +0200

----------------------------------------------------------------------
 .../cloud/api/query/dao/UserVmJoinDaoImpl.java  | 14 +++++++++++++-
 ui/scripts/instances.js                         | 20 ++++++++++++++++++--
 2 files changed, 31 insertions(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/9b7ac9df/server/src/com/cloud/api/query/dao/UserVmJoinDaoImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/dao/UserVmJoinDaoImpl.java b/server/src/com/cloud/api/query/dao/UserVmJoinDaoImpl.java
index 5fac449..80de6a5 100644
--- a/server/src/com/cloud/api/query/dao/UserVmJoinDaoImpl.java
+++ b/server/src/com/cloud/api/query/dao/UserVmJoinDaoImpl.java
@@ -31,6 +31,7 @@ import javax.inject.Inject;
 import org.apache.cloudstack.affinity.AffinityGroupResponse;
 import org.apache.cloudstack.api.ApiConstants.VMDetails;
 import org.apache.cloudstack.api.response.NicResponse;
+import org.apache.cloudstack.api.response.NicSecondaryIpResponse;
 import org.apache.cloudstack.api.response.SecurityGroupResponse;
 import org.apache.cloudstack.api.response.UserVmResponse;
 import org.apache.cloudstack.framework.config.dao.ConfigurationDao;
@@ -52,7 +53,7 @@ import com.cloud.vm.VirtualMachine.State;
 import com.cloud.vm.VmDetailConstants;
 import com.cloud.vm.VmStats;
 import com.cloud.vm.dao.UserVmDetailsDao;
-
+import com.cloud.vm.dao.NicSecondaryIpVO;
 
 @Component
 @Local(value={UserVmJoinDao.class})
@@ -241,6 +242,17 @@ public class UserVmJoinDaoImpl extends GenericDaoBase<UserVmJoinVO, Long> implem
                     nicResponse.setType(userVm.getGuestType().toString());
                 }
                 nicResponse.setIsDefault(userVm.isDefaultNic());
+                List<NicSecondaryIpVO> secondaryIps = ApiDBUtils.findNicSecondaryIps(userVm.getNicId());
+                if (secondaryIps != null) {
+                    List<NicSecondaryIpResponse> ipList = new ArrayList<NicSecondaryIpResponse>();
+                    for (NicSecondaryIpVO ip : secondaryIps) {
+                        NicSecondaryIpResponse ipRes = new NicSecondaryIpResponse();
+                        ipRes.setId(ip.getUuid());
+                        ipRes.setIpAddr(ip.getIp4Address());
+                        ipList.add(ipRes);
+                    }
+                    nicResponse.setSecondaryIps(ipList);
+                }
                 nicResponse.setObjectName("nic");
                 userVmResponse.addNic(nicResponse);
             }

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/9b7ac9df/ui/scripts/instances.js
----------------------------------------------------------------------
diff --git a/ui/scripts/instances.js b/ui/scripts/instances.js
index dd33672..8920473 100644
--- a/ui/scripts/instances.js
+++ b/ui/scripts/instances.js
@@ -2056,6 +2056,9 @@
                             ipaddress: {
                                 label: 'label.ip.address'
                             },
+                            secondaryips: {
+                                label: 'Secondary IPs'
+                            },
                             gateway: {
                                 label: 'label.gateway'
                             },
@@ -2082,8 +2085,8 @@
                         }],
                         viewAll: {
                             path: 'network.secondaryNicIps',
-                            attachTo: 'ipaddress',
-                            label: 'label.view.secondary.ips',
+                            attachTo: 'secondaryips',
+                            label: 'Edit secondary IPs',
                             title: function(args) {
                                 var title = _l('label.menu.ipaddresses') + ' - ' + args.context.nics[0].name;
 
@@ -2106,6 +2109,19 @@
                                             }
                                         },
                                         data: $.map(json.listvirtualmachinesresponse.virtualmachine[0].nic, function(nic, index) {
+                                            if (nic.secondaryip != null) {
+                                                var secondaryips = "";
+                                                for (var i = 0; i < nic.secondaryip.length; i++) {
+                                                    if (i == 0)
+                                                        secondaryips = nic.secondaryip[i].ipaddress;
+                                                    else
+                                                        secondaryips = secondaryips + " , " + nic.secondaryip[i].ipaddress;
+                                                }
+                                                $.extend(nic, {
+                                                    secondaryips: secondaryips
+                                                })
+                                            }
+                                                
                                             var name = 'NIC ' + (index + 1);
                                             if (nic.isdefault) {
                                                 name += ' (' + _l('label.default') + ')';


[3/5] git commit: updated refs/heads/4.3 to ec823db

Posted by we...@apache.org.
[UI] update vm nic information after add/remove NIC


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

Branch: refs/heads/4.3
Commit: fe1cdbd2356edda87b9e66323c9b294f853034b1
Parents: 9b7ac9d
Author: Wei Zhou <w....@leaseweb.com>
Authored: Thu Jul 3 11:09:11 2014 +0200
Committer: Wei Zhou <w....@leaseweb.com>
Committed: Thu Jul 3 11:20:30 2014 +0200

----------------------------------------------------------------------
 ui/scripts/instances.js | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/fe1cdbd2/ui/scripts/instances.js
----------------------------------------------------------------------
diff --git a/ui/scripts/instances.js b/ui/scripts/instances.js
index 8920473..7ff75a2 100644
--- a/ui/scripts/instances.js
+++ b/ui/scripts/instances.js
@@ -1962,7 +1962,10 @@
                                         success: function(json) {
                                             args.response.success({
                                                 _custom: {
-                                                    jobId: json.addnictovirtualmachineresponse.jobid
+                                                    jobId: json.addnictovirtualmachineresponse.jobid,
+                                                    getUpdatedItem: function(json) {
+                                                        return json.queryasyncjobresultresponse.jobresult.virtualmachine;
+                                                    }
                                                 }
                                             });
                                         }
@@ -2028,7 +2031,10 @@
                                         success: function(json) {
                                             args.response.success({
                                                 _custom: {
-                                                    jobId: json.removenicfromvirtualmachineresponse.jobid
+                                                    jobId: json.removenicfromvirtualmachineresponse.jobid,
+                                                    getUpdatedItem: function(json) {
+                                                        return json.queryasyncjobresultresponse.jobresult.virtualmachine;
+                                                    }
                                                 }
                                             })
                                         }


[4/5] git commit: updated refs/heads/4.3 to ec823db

Posted by we...@apache.org.
[UI] bug fix: vpn configuration does not show ipsec presharedkey


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

Branch: refs/heads/4.3
Commit: ec55f5ca961be1d36509548e1e318ae4208057bd
Parents: fe1cdbd
Author: Wei Zhou <w....@leaseweb.com>
Authored: Thu Jul 3 11:14:03 2014 +0200
Committer: Wei Zhou <w....@leaseweb.com>
Committed: Thu Jul 3 11:20:37 2014 +0200

----------------------------------------------------------------------
 ui/scripts/network.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ec55f5ca/ui/scripts/network.js
----------------------------------------------------------------------
diff --git a/ui/scripts/network.js b/ui/scripts/network.js
index 2cb3973..beab1a9 100755
--- a/ui/scripts/network.js
+++ b/ui/scripts/network.js
@@ -2259,7 +2259,7 @@
                                                 _custom: {
                                                     getUpdatedItem: function(json) {
                                                         return {
-                                                            vpn: json.queryasyncjobresultresponse.jobresult.remoteaccessvpn,
+                                                            remoteaccessvpn: json.queryasyncjobresultresponse.jobresult.remoteaccessvpn,
                                                             vpnenabled: true
                                                         };
                                                     },
@@ -2283,7 +2283,7 @@
                                         return 'label.enable.vpn';
                                     },
                                     complete: function(args) {
-                                        return _l('message.enabled.vpn') + ' ' + args.vpn.publicip + '.' + '<br/>' + _l('message.enabled.vpn.ip.sec') + '<br/>' + args.vpn.presharedkey;
+                                        return _l('message.enabled.vpn') + ' ' + args.remoteaccessvpn.publicip + '.' + '<br/>' + _l('message.enabled.vpn.ip.sec') + '<br/>' + args.remoteaccessvpn.presharedkey;
                                     }
                                 },
                                 notification: {


[5/5] git commit: updated refs/heads/4.3 to ec823db

Posted by we...@apache.org.
[UI] bug fix: error message was not shown if fail to delete snapshot


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

Branch: refs/heads/4.3
Commit: ec823db47afc3dce7678f462a9b927e4e2bd346e
Parents: ec55f5c
Author: Wei Zhou <w....@leaseweb.com>
Authored: Thu Jul 3 11:18:58 2014 +0200
Committer: Wei Zhou <w....@leaseweb.com>
Committed: Thu Jul 3 11:20:44 2014 +0200

----------------------------------------------------------------------
 ui/scripts/storage.js | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/ec823db4/ui/scripts/storage.js
----------------------------------------------------------------------
diff --git a/ui/scripts/storage.js b/ui/scripts/storage.js
index 1422904..a1af129 100644
--- a/ui/scripts/storage.js
+++ b/ui/scripts/storage.js
@@ -1871,9 +1871,7 @@
                                     });
                                 },
                                 notification: {
-                                    poll: function(args) {
-                                        args.complete();
-                                    }
+                                    poll: pollAsyncJobResult
                                 }
                             }
                         },