'Captures all relevant information from the spawn parameters.'

def _get_vm_config_info(self, instance, image_info, extra_specs):

    if ((instance.flavor.root_gb != 0) and (image_info.file_size > (instance.flavor.root_gb * units.Gi))):
        reason = _('Image    disk    size    greater    than    requested    disk    size')
        raise exception.InstanceUnacceptable(instance_id=instance.uuid, reason=reason)
    allowed_ds_types = ds_util.get_allowed_datastore_types(image_info.disk_type)
    datastore = ds_util.get_datastore(self._session, self._cluster, self._datastore_regex, extra_specs.storage_policy, allowed_ds_types)
    dc_info = self.get_datacenter_ref_and_name(datastore.ref)
    return VirtualMachineInstanceConfigInfo(instance, image_info, datastore, dc_info, self._imagecache, extra_specs)
