sonata-nfv / tng-sdk-validation

The 5GTANGO SDK validation repository
Apache License 2.0
2 stars 6 forks source link

Validate only SONATA/5GTANGO descriptors #125

Closed anapolg closed 5 years ago

anapolg commented 5 years ago

Check in METADATA of the package if it contains descriptors from SONATA, OSM, etc. Only SONATA/5GTANGO descriptors must be validated. Ignore other types of packages for validation.

For this, you need to check the project.yml, in type field. If it is a 5GTANGO/SONATA descriptor then continue with validation. Otherwise (OSM, ONAP...) ignore the descriptor validation.

Here are the MIME types that might appear: https://github.com/sonata-nfv/tng-schema/wiki/PkgSpec_LATEST#5gtango-specific-mime-types 5GTANGO network service descriptor application/vnd.5gtango.nsd 5GTANGO virtual network function descriptor application/vnd.5gtango.vnfd 5GTANGO test descriptor application/vnd.5gtango.tstd OSM network service descriptor application/vnd.etsi.osm.nsd OSM virtual network function descriptor application/vnd.etsi.osm.vnfd ONAP network service descriptor application/vnd.lf.onap.nsd ONAP virtual network function descriptor application/vnd.lf.onap.vnfd

mpeuster commented 5 years ago

I propose to change the title validate only SONATA/5GTANGO descriptors. Because packages are always 5GTANGO packages which may or may not contain OSM or ONAP descriptors. We have to skip the validation of those OSM/ONAP descriptors.

They can be detected using the MIME types in the project.yml as you write.