X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=osm_lcm%2Fns.py;h=3e6bafc5e9c813ecd085dad9d8d006e596c96fad;hb=refs%2Fchanges%2F02%2F12802%2F1;hp=b7df0b6a585f3c4eeb781df10a29638b5c330310;hpb=c09b842d41437f1c2bb4a931182afbe7088d696f;p=osm%2FLCM.git diff --git a/osm_lcm/ns.py b/osm_lcm/ns.py index b7df0b6..3e6bafc 100644 --- a/osm_lcm/ns.py +++ b/osm_lcm/ns.py @@ -2044,16 +2044,13 @@ class NsLcm(LcmBase): ) # add relations for this VCA (wait for other peers related with this VCA) - is_relation_added = await self._add_vca_relations( + await self._add_vca_relations( logging_text=logging_text, nsr_id=nsr_id, vca_type=vca_type, vca_index=vca_index, ) - if not is_relation_added: - raise LcmException("Relations could not be added to VCA.") - # if SSH access is required, then get execution environment SSH public # if native charm we have waited already to VM be UP if vca_type in ("k8s_proxy_charm", "lxc_proxy_charm", "helm", "helm-v3"): @@ -2248,7 +2245,7 @@ class NsLcm(LcmBase): self._write_configuration_status( nsr_id=nsr_id, vca_index=vca_index, status="BROKEN" ) - raise LcmException("{}. {}".format(step, e)) from e + raise LcmException("{} {}".format(step, e)) from e def _write_ns_status( self, @@ -3216,14 +3213,11 @@ class NsLcm(LcmBase): requirer_vca_id, relation.requirer.endpoint, ) - try: - await self.vca_map[vca_type].add_relation( - provider=provider_relation_endpoint, - requirer=requirer_relation_endpoint, - ) - except N2VCException as exception: - self.logger.error(exception) - raise LcmException(exception) + await self.vca_map[vca_type].add_relation( + provider=provider_relation_endpoint, + requirer=requirer_relation_endpoint, + ) + # remove entry from relations list return True return False