From: David Garcia Date: Thu, 21 May 2020 14:41:07 +0000 (+0200) Subject: Fix bug 1074: Get NS Configuration from database X-Git-Tag: v7.1.0rc2~2 X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=de592b6bae3bd3f9bc2269f22d79683a7c2f753f;p=osm%2FLCM.git Fix bug 1074: Get NS Configuration from database Change-Id: I10d77e47ebab0669d8d2b43699c5224654a902b9 Signed-off-by: David Garcia --- diff --git a/osm_lcm/ns.py b/osm_lcm/ns.py index 0a70367..dddf99f 100644 --- a/osm_lcm/ns.py +++ b/osm_lcm/ns.py @@ -1967,13 +1967,14 @@ class NsLcm(LcmBase): # read nsr record db_nsr = self.db.get_one("nsrs", {"_id": nsr_id}) + nsd = self.db.get_one("nsds", {"_id": db_nsr["nsd-id"]}) # this VCA data my_vca = deep_get(db_nsr, ('_admin', 'deployed', 'VCA'))[vca_index] # read all ns-configuration relations ns_relations = list() - db_ns_relations = deep_get(db_nsr, ('nsd', 'ns-configuration', 'relation')) + db_ns_relations = deep_get(nsd, ('ns-configuration', 'relation')) if db_ns_relations: for r in db_ns_relations: # check if this VCA is in the relation