From: delacruzramo Date: Thu, 28 Nov 2019 10:24:09 +0000 (+0100) Subject: Added KDU inspect/readme actions to NsLcmOpTopic X-Git-Tag: v7.0.0rc1~10 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=refs%2Fchanges%2F52%2F8252%2F3;p=osm%2FNBI.git Added KDU inspect/readme actions to NsLcmOpTopic Change-Id: I9ee6b50639d9d8719238b25c76ff8fb881dd0326 Signed-off-by: delacruzramo --- diff --git a/osm_nbi/instance_topics.py b/osm_nbi/instance_topics.py index 0303d54..1b464ee 100644 --- a/osm_nbi/instance_topics.py +++ b/osm_nbi/instance_topics.py @@ -592,8 +592,11 @@ class NsLcmOpTopic(BaseTopic): descriptor_configuration = nsd.get("ns-configuration", {}).get("config-primitive") # For k8s allows default primitives without validating the parameters - if indata.get("kdu_name") and indata["primitive"] in ("upgrade", "rollback", "status"): + if indata.get("kdu_name") and indata["primitive"] in ("upgrade", "rollback", "status", "inspect", "readme"): # TODO should be checked that rollback only can contains revsision_numbe???? + if not indata.get("member_vnf_index"): + raise EngineException("Missing action parameter 'member_vnf_index' for default KDU primitive '{}'" + .format(indata["primitive"])) return # if not, check primitive for config_primitive in get_iterable(descriptor_configuration):