Return-Path: X-Original-To: apmail-cloudstack-commits-archive@www.apache.org Delivered-To: apmail-cloudstack-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 5B67910B2B for ; Thu, 26 Mar 2015 12:54:33 +0000 (UTC) Received: (qmail 8862 invoked by uid 500); 26 Mar 2015 12:54:30 -0000 Delivered-To: apmail-cloudstack-commits-archive@cloudstack.apache.org Received: (qmail 8829 invoked by uid 500); 26 Mar 2015 12:54:30 -0000 Mailing-List: contact commits-help@cloudstack.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@cloudstack.apache.org Delivered-To: mailing list commits@cloudstack.apache.org Received: (qmail 8820 invoked by uid 99); 26 Mar 2015 12:54:30 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 26 Mar 2015 12:54:30 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id F0653E2C0A; Thu, 26 Mar 2015 12:54:29 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: bhaisaab@apache.org To: commits@cloudstack.apache.org Message-Id: <8ab858e2f45c4e99a07b67078ec790f4@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: git commit: updated refs/heads/master to 0eec4ff Date: Thu, 26 Mar 2015 12:54:29 +0000 (UTC) Repository: cloudstack Updated Branches: refs/heads/master 9763c9b84 -> 0eec4ff97 CLOUDSTACK-6353: Fix list to have correct LB IP for each rule (cherry picked from commit 0fe4acf525824650ea290f09edd5a71ed9e7b053) Signed-off-by: Rohit Yadav Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/0eec4ff9 Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/0eec4ff9 Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/0eec4ff9 Branch: refs/heads/master Commit: 0eec4ff9770846a9caf779f12c54ae59263be0e9 Parents: 9763c9b Author: Rohit Yadav Authored: Thu Mar 26 18:20:59 2015 +0530 Committer: Rohit Yadav Committed: Thu Mar 26 18:24:19 2015 +0530 ---------------------------------------------------------------------- .../user/loadbalancer/ListLoadBalancerRuleInstancesCmd.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/0eec4ff9/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListLoadBalancerRuleInstancesCmd.java ---------------------------------------------------------------------- diff --git a/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListLoadBalancerRuleInstancesCmd.java b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListLoadBalancerRuleInstancesCmd.java index cc4203c..8827557 100644 --- a/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListLoadBalancerRuleInstancesCmd.java +++ b/api/src/org/apache/cloudstack/api/command/user/loadbalancer/ListLoadBalancerRuleInstancesCmd.java @@ -19,6 +19,7 @@ package org.apache.cloudstack.api.command.user.loadbalancer; import java.util.ArrayList; import java.util.List; +import com.cloud.vm.VirtualMachine; import org.apache.cloudstack.api.response.LoadBalancerRuleVmMapResponse; import org.apache.log4j.Logger; @@ -129,7 +130,9 @@ public class ListLoadBalancerRuleInstancesCmd extends BaseListCmd { LoadBalancerRuleVmMapResponse lbRuleVmIpResponse = new LoadBalancerRuleVmMapResponse(); vmResponses.get(i).setServiceState(serviceStates.get(i)); lbRuleVmIpResponse.setUserVmResponse(vmResponses.get(i)); - lbRuleVmIpResponse.setIpAddr(_lbService.listLbVmIpAddress(getId(), result.get(i).getId())); + //get vm id from the uuid + VirtualMachine lbvm = _entityMgr.findByUuid(VirtualMachine.class, vmResponses.get(i).getId()); + lbRuleVmIpResponse.setIpAddr(_lbService.listLbVmIpAddress(getId(), lbvm.getId())); lbRuleVmIpResponse.setObjectName("lbrulevmidip"); listlbVmRes.add(lbRuleVmIpResponse); }