Comment 5 for bug 1197041

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (stable/havana)

Reviewed: https://review.openstack.org/55505
Committed: http://github.com/openstack/nova/commit/cf1fb26def9d1e7c0cde79927333bbda36619bf8
Submitter: Jenkins
Branch: stable/havana

commit cf1fb26def9d1e7c0cde79927333bbda36619bf8
Author: Gary Kotton <email address hidden>
Date: Sun Aug 25 04:55:40 2013 -0700

    VMware: Handle cases when there are no hosts in cluster

    When there are no hosts defined in a cluster the host value will be an empty
    string. For example:

        obj_context: (RetrieveResult){
           objects[] =
              (ObjectContent){
                 obj =
                    (obj){
                       value = "domain-c185"
                       _type = "ClusterComputeResource"
                    }
                 propSet[] =
                    (DynamicProperty){
                       name = "host"
                       val = ""
                    },
              },
         }

    This causes an data access exception.

    The code will now raise an NoValidHost exception.

    Fixes bug: 1197041

    Change-Id: I75b1f069e0b27eebd63c280e36533354c04e246a
    (cherry picked from commit 89e18d8c64b11630d2f21563c95b01452057a897)