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 B5912176C8 for ; Wed, 16 Sep 2015 07:21:40 +0000 (UTC) Received: (qmail 77373 invoked by uid 500); 16 Sep 2015 07:21:40 -0000 Delivered-To: apmail-cloudstack-commits-archive@cloudstack.apache.org Received: (qmail 77259 invoked by uid 500); 16 Sep 2015 07:21:40 -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 77234 invoked by uid 99); 16 Sep 2015 07:21:40 -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; Wed, 16 Sep 2015 07:21:40 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 4C5A5DFD45; Wed, 16 Sep 2015 07:21:40 +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 Date: Wed, 16 Sep 2015 07:21:41 -0000 Message-Id: <2dbf9a1906a146e3baddb619c84894da@git.apache.org> In-Reply-To: References: X-Mailer: ASF-Git Admin Mailer Subject: [2/3] git commit: updated refs/heads/master to 1ba362d CLOUDSTACK-8820: Updated the code for vCenter6 data center support. Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/1d73418c Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/1d73418c Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/1d73418c Branch: refs/heads/master Commit: 1d73418c2c2b3881952f9dab0ed235ebfb096a50 Parents: 4a6e2cd Author: Suresh Kumar Anaparti Authored: Mon Sep 14 15:27:52 2015 +0530 Committer: Suresh Kumar Anaparti Committed: Mon Sep 14 15:27:52 2015 +0530 ---------------------------------------------------------------------- .../com/cloud/hypervisor/vmware/util/VmwareClient.java | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/cloudstack/blob/1d73418c/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java ---------------------------------------------------------------------- diff --git a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java index b2de216..96558ea 100644 --- a/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java +++ b/vmware-base/src/com/cloud/hypervisor/vmware/util/VmwareClient.java @@ -156,6 +156,7 @@ public class VmwareClient { vimPort.login(serviceContent.getSessionManager(), userName, password, null); if (cookies == null) { + // Get the cookie from the response header. See vmware sample program com.vmware.httpfileaccess.GetVMFiles @SuppressWarnings("unchecked") Map> responseHeaders = (Map>)((BindingProvider)vimPort).getResponseContext().get(MessageContext.HTTP_RESPONSE_HEADERS); cookies = responseHeaders.get("Set-cookie"); @@ -627,9 +628,12 @@ public class VmwareClient { } } } - } catch (Exception e) { - s_logger.debug("Failed to get mor for name: " + name + " and type: " + type, e); - throw e; + } catch (InvalidPropertyFaultMsg invalidPropertyException) { + s_logger.debug("Failed to get Vmware ManagedObjectReference for name: " + name + " and type: " + type + " due to " + invalidPropertyException.getMessage()); + throw invalidPropertyException; + } catch (RuntimeFaultFaultMsg runtimeFaultException) { + s_logger.debug("Failed to get Vmware ManagedObjectReference for name: " + name + " and type: " + type + " due to " + runtimeFaultException.getMessage()); + throw runtimeFaultException; } return null;