SODALITE-EU / semantic-reasoner

Apache License 2.0
1 stars 3 forks source link

Property Input Validation #174

Open zoevas opened 2 years ago

zoevas commented 2 years ago

When you assign an input to a property and the input name is not present in the aadm an error is thrown.

The format of the errors are like the following. For example a ssh-ky-name was assigned to the _key_name/getinput property.

{
    "errors": [
        {
            "type": "PropertyInput",
            "info": {
                "context": "node_templates/snow-vm/properties/key_name/get_input",
                "name": "key_name",
                "description": "The ssh-ky-name is not present in the model"
            }
        },
        {
            "type": "PropertyInput",
            "info": {
                "context": "node_templates/snow-vm/properties/image/get_input",
                "name": "image",
                "description": "The imae-name is not present in the model"
            }
        },
        {
            "type": "PropertyInput",
            "info": {
                "context": "node_templates/snow-vm/properties/network/get_input",
                "name": "network",
                "description": "The opensack-network-name is not present in the model"
            }
        },
        {
            "type": "PropertyInput",
            "info": {
                "context": "node_templates/snow-daily-median-aggregator/properties/env/get_input",
                "name": "env",
                "description": "The medin-env is not present in the model"
            }
        }
    ]
}
zoevas commented 2 years ago

Ready to be tested on CERTH server