Skip to content

add more details to the log about the failure, specifying used values #991

@kalsky

Description

@kalsky

Issue details

https://github.com/QualiSystems/vCenterShell/blob/develop/package/cloudshell/cp/vcenter/common/vcenter/vmomi_service.py#L454

when the driver fails to find the datacenter/resource pool/host during the deploy, the user only sees an error about the problem (The specifed host, cluster or resource pool could not be found), but it's not mentioned anywhere what values were used.

Would be good to at least log the values to better understand why it fails.

Steps to reproduce

If you have an app that has a deployment path with values in the resource pool/cluster/storage that are different than the ones on the vcenter resource, the driver will try use those.
If the values are wrong, you'll get the above error.
Since these values are not "user input" by default, then you might have apps in your blueprints with some old default values in them and it's hard to see where problem is coming from, and you'll only try to compare the ones on the vcenter resource, without knowing that there are other places to check.

It would be good to both log the values that were used, just before throwing the error (I don't think the users should see it, but at least the log should have it).
It will help to add in the log, in addition to the values, something like "these values are coming from the deployment path attributes, make sure you have them set correctly on the app. If needed, set these attributes as "user input" to see what values are currently set on the app itself".

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions