The code that generates the XML appears to be of the opinion :-) that even though the NetworkPoolReference element is of type "vcloud:ReferenceType" it should be sent in the "http://www.vmware.com/vcloud/extension/v1.5" namespace, presumably because the element declaration is in that namespace. Hopefully that's correct, and all that needs to be resolved is the namespace of the inherited elements and attributes from the base.
Given one xsd, say common.xsd:
--------------------------------common.xsd--------------------------------
--------------------------------/common.xsd--------------------------------
And another, vmwextensions.xsd:
--------------------------------vmwextensions.xsd--------------------------------
--------------------------------/vmwextensions.xsd--------------------------------
where VMWNetworkPoolReferencesType extends ResourceType from common.xsd, which is in the vcloud namespace, we find, in xmlprotocol.scala:
--------------------------------xmlprotocol.scala--------------------------------
--------------------------------/xmlprotocol.scala--------------------------------
This fails to parse the following actual XML from vCloud Director:
--------------------------------XML from vCD--------------------------------
--------------------------------/XML from vCD--------------------------------
The issue seems to be that scalaxb expects the "Link" element to be in the "http://www.vmware.com/vcloud/extension/v1.5" namespace instead of the "http://www.vmware.com/vcloud/v1.5" namespace. Removing the Link element from the XML results in a successful parse of the remainder.
The code that generates the XML appears to be of the opinion :-) that even though the NetworkPoolReference element is of type "vcloud:ReferenceType" it should be sent in the "http://www.vmware.com/vcloud/extension/v1.5" namespace, presumably because the element declaration is in that namespace. Hopefully that's correct, and all that needs to be resolved is the namespace of the inherited elements and attributes from the base.