X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=osm_lcm%2Fvim_sdn.py;fp=osm_lcm%2Fvim_sdn.py;h=348f29263f23346dbd8413da61a21a9b86897774;hb=0fedb035ea33249eb061bf5f0f41c627dab64965;hp=6b1a338a43d7cc0a2c82b3a32e3439d1ddf5446d;hpb=0e8c3f0ad1b1db0bc07dc6d802983d9792af5cbd;p=osm%2FLCM.git diff --git a/osm_lcm/vim_sdn.py b/osm_lcm/vim_sdn.py index 6b1a338..348f292 100644 --- a/osm_lcm/vim_sdn.py +++ b/osm_lcm/vim_sdn.py @@ -1042,7 +1042,7 @@ class K8sClusterLcm(LcmBase): detailed_status=detailed_status_HA) except DbException as e: self.logger.error(logging_text + "Cannot update database: {}".format(e)) - self.lcm_tasks.remove("k8sclusters", k8scluster_id, order_id) + self.lcm_tasks.remove("k8scluster", k8scluster_id, order_id) async def delete(self, k8scluster_content, order_id): @@ -1100,7 +1100,10 @@ class K8sClusterLcm(LcmBase): # raise Exception("K8scluster was not properly removed") except Exception as e: - self.logger.critical(logging_text + "Exit Exception {}".format(e), exc_info=True) + if isinstance(e, LcmException, DbException): + self.logger.error(logging_text + "Exit Exception {}".format(e)) + else: + self.logger.critical(logging_text + "Exit Exception {}".format(e), exc_info=True) exc = e finally: if exc and db_k8scluster: @@ -1119,7 +1122,7 @@ class K8sClusterLcm(LcmBase): detailed_status=detailed_status_HA) except DbException as e: self.logger.error(logging_text + "Cannot update database: {}".format(e)) - self.lcm_tasks.remove("k8sclusters", k8scluster_id, order_id) + self.lcm_tasks.remove("k8scluster", k8scluster_id, order_id) class K8sRepoLcm(LcmBase):