cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From weiz...@apache.org
Subject git commit: updated refs/heads/master to da7f924
Date Tue, 13 Aug 2013 19:39:41 GMT
Updated Branches:
  refs/heads/master 5c35bd1b3 -> da7f924cc


CLOUDSTACK-4296: fix parameter setting error in listVirtualMachines command
(cherry picked from commit 72f013f7809db70755f0ff59f8c888d95d5179b5)


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

Branch: refs/heads/master
Commit: da7f924cc53fea3567764eecc5ebc9260aea0f5d
Parents: 5c35bd1
Author: Wei Zhou <w.zhou@leaseweb.com>
Authored: Tue Aug 13 21:38:27 2013 +0200
Committer: Wei Zhou <w.zhou@leaseweb.com>
Committed: Tue Aug 13 21:39:24 2013 +0200

----------------------------------------------------------------------
 .../org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java  | 6 +++---
 server/src/com/cloud/api/query/QueryManagerImpl.java           | 6 +++---
 server/src/com/cloud/api/query/vo/UserVmJoinVO.java            | 2 +-
 3 files changed, 7 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/da7f924c/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
----------------------------------------------------------------------
diff --git a/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java b/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
index 6bd9290..cb31393 100644
--- a/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
+++ b/api/src/org/apache/cloudstack/api/command/user/vm/ListVMsCmd.java
@@ -66,7 +66,7 @@ public class ListVMsCmd extends BaseListTaggedResourcesCmd {
     private Long id;
 
     @Parameter(name=ApiConstants.NAME, type=CommandType.STRING, description="name of the
virtual machine")
-    private String instanceName;
+    private String name;
 
     @Parameter(name=ApiConstants.POD_ID, type=CommandType.UUID, entityType=PodResponse.class,
             description="the pod ID")
@@ -130,8 +130,8 @@ public class ListVMsCmd extends BaseListTaggedResourcesCmd {
         return id;
     }
 
-    public String getInstanceName() {
-        return instanceName;
+    public String getName() {
+        return name;
     }
 
     public Long getPodId() {

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/da7f924c/server/src/com/cloud/api/query/QueryManagerImpl.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/QueryManagerImpl.java b/server/src/com/cloud/api/query/QueryManagerImpl.java
index 2367fc5..ff96c7e 100644
--- a/server/src/com/cloud/api/query/QueryManagerImpl.java
+++ b/server/src/com/cloud/api/query/QueryManagerImpl.java
@@ -710,7 +710,7 @@ public class QueryManagerImpl extends ManagerBase implements QueryService
{
         // cmd.getPageSizeVal()); //version without default sorting
         c.addCriteria(Criteria.KEYWORD, cmd.getKeyword());
         c.addCriteria(Criteria.ID, cmd.getId());
-        c.addCriteria(Criteria.NAME, cmd.getInstanceName());
+        c.addCriteria(Criteria.NAME, cmd.getName());
         c.addCriteria(Criteria.STATE, cmd.getState());
         c.addCriteria(Criteria.DATACENTERID, cmd.getZoneId());
         c.addCriteria(Criteria.GROUPID, cmd.getGroupId());
@@ -782,7 +782,7 @@ public class QueryManagerImpl extends ManagerBase implements QueryService
{
 
         sb.and("displayName", sb.entity().getDisplayName(), SearchCriteria.Op.LIKE);
         sb.and("id", sb.entity().getId(), SearchCriteria.Op.EQ);
-        sb.and("name", sb.entity().getHostName(), SearchCriteria.Op.LIKE);
+        sb.and("name", sb.entity().getName(), SearchCriteria.Op.LIKE);
         sb.and("stateEQ", sb.entity().getState(), SearchCriteria.Op.EQ);
         sb.and("stateNEQ", sb.entity().getState(), SearchCriteria.Op.NEQ);
         sb.and("stateNIN", sb.entity().getState(), SearchCriteria.Op.NIN);
@@ -840,7 +840,7 @@ public class QueryManagerImpl extends ManagerBase implements QueryService
{
         if (keyword != null) {
             SearchCriteria<UserVmJoinVO> ssc = _userVmJoinDao.createSearchCriteria();
             ssc.addOr("displayName", SearchCriteria.Op.LIKE, "%" + keyword + "%");
-            ssc.addOr("hostName", SearchCriteria.Op.LIKE, "%" + keyword + "%");
+            ssc.addOr("name", SearchCriteria.Op.LIKE, "%" + keyword + "%");
             ssc.addOr("instanceName", SearchCriteria.Op.LIKE, "%" + keyword + "%");
             ssc.addOr("state", SearchCriteria.Op.EQ, keyword);
 

http://git-wip-us.apache.org/repos/asf/cloudstack/blob/da7f924c/server/src/com/cloud/api/query/vo/UserVmJoinVO.java
----------------------------------------------------------------------
diff --git a/server/src/com/cloud/api/query/vo/UserVmJoinVO.java b/server/src/com/cloud/api/query/vo/UserVmJoinVO.java
index c784104..745db56 100644
--- a/server/src/com/cloud/api/query/vo/UserVmJoinVO.java
+++ b/server/src/com/cloud/api/query/vo/UserVmJoinVO.java
@@ -1653,7 +1653,7 @@ public class UserVmJoinVO extends BaseViewVO implements ControlledViewEntity
{
     @Override
     public String toString() {
         if (toString == null) {
-            toString = new StringBuilder("VM[").append(id).append("|").append(hostName).append("]").toString();
+            toString = new StringBuilder("VM[").append(id).append("|").append(name).append("]").toString();
         }
         return toString;
     }


Mime
View raw message