vmware / go-vcloud-director

Golang SDK for VMware Cloud Director
Other
80 stars 79 forks source link

Missing parsing vmNameInVc xml attribute on QueryResultVMRecordType struct #634

Open mrfoxes opened 8 months ago

mrfoxes commented 8 months ago

Describe the bug

The struct QueryResultVMRecordType is missing the VmNameInVc attribute.

Example XML response that shows that vmNameInVc attributes is present.

<AdminVMRecord name="EPHEMERAL-TEMP-VM" containerName="container" description="Description for [container]"
               vappScopedLocalId="3dac7a18-7e74-48d8-bb11-3d27e1965152"
               container="https://vcd/api/vApp/vapp-853abbc1-f516-474b-8fdf-b63c07aa51bd"
               status="POWERED_ON" vdcName="sample-vdc"
               vdc="https://vcd/api/vdc/339058b9-d8b0-48c8-8561-7c28d18d64e9"
               hostName="vcd01esxi02.arubaeng.lab" isVAppTemplate="false" isDeleted="false"
               guestOs="Ubuntu Linux (64-bit)" numberOfCpus="2" memoryMB="4096" networkName="sample-net01"
               isDeployed="true" isPublished="false" isVdcEnabled="true" hardwareVersion="15" vmToolsVersion="11360"
               datastoreName="CELL01_DATASTORE01"
               vc="https://vcd/api/admin/extension/vimServer/1474957f-a7b4-4d4b-9c50-7fc7723cb412"
               moref="vm-30249" org="https://vcd/api/org/edca320e-46a3-44bc-9b58-1e3a19ec112b"
               storageProfileName="No_Encryption_Policy" gcStatus="GC_COMPLETE" isAutoNature="false"
               isComputePolicyCompliant="true" vmSizingPolicyId="e22860f0-9db8-4f23-8abf-21594dcc1059"
               ipAddress="192.168.1.2" encrypted="false" dateCreated="2023-11-27T13:57:27.352Z" isExpired="false"
               vmNameInVc="EPHEMERAL-TEMP-VM-Ev1s"
               href="https://vcd/api/vApp/vm-c19c7046-e180-4d2e-a5f1-2d660497b713"
               containerStatus="RESOLVED" pvdcHighestSupportedHardwareVersion="19"/>

Reproduction steps

  1. export GOVCD_SHOW_RESP=true
  2. Query AdminVMRecord

Expected behavior

type QueryResultVMRecordType struct map the attribute VmNameInVc on xml:"vmNameInVc,attr,omitempty"

Additional context

No response