From: garciadeblas Date: Tue, 22 Oct 2024 10:39:32 +0000 (+0200) Subject: Reduce logging level during cluster delete in k8s.py X-Git-Url: https://osm.etsi.org/gitweb/?a=commitdiff_plain;h=refs%2Fchanges%2F65%2F14665%2F1;p=osm%2FLCM.git Reduce logging level during cluster delete in k8s.py Change-Id: Iddac985f3357a1d694775deaf158bf2c8287a0f0 Signed-off-by: garciadeblas --- diff --git a/osm_lcm/k8s.py b/osm_lcm/k8s.py index 1009ea6..6074155 100644 --- a/osm_lcm/k8s.py +++ b/osm_lcm/k8s.py @@ -201,36 +201,38 @@ class ClusterLcm(LcmBase): } for profile_type in profiles_to_detach: if db_cluster.get(profile_type): - self.logger.info("the profile_type is :{}".format(profile_type)) + self.logger.debug("the profile_type is :{}".format(profile_type)) profile_ids = db_cluster[profile_type] - self.logger.info("the profile_ids is :{}".format(profile_ids)) + self.logger.debug("the profile_ids is :{}".format(profile_ids)) profile_ids_copy = deepcopy(profile_ids) - self.logger.info("the profile_ids_copy is :{}".format(profile_ids_copy)) + self.logger.debug( + "the profile_ids_copy is :{}".format(profile_ids_copy) + ) for profile_id in profile_ids_copy: - self.logger.info("the profile_id is :{}".format(profile_id)) + self.logger.debug("the profile_id is :{}".format(profile_id)) db_collection = profiles_collection[profile_type] - self.logger.info("the db_collection is :{}".format(db_collection)) + self.logger.debug("the db_collection is :{}".format(db_collection)) db_profile = self.db.get_one(db_collection, {"_id": profile_id}) - self.logger.info("the db_profile is :{}".format(db_profile)) - self.logger.info( + self.logger.debug("the db_profile is :{}".format(db_profile)) + self.logger.debug( "the item_content name is :{}".format(db_cluster["name"]) ) - self.logger.info( + self.logger.debug( "the db_profile name is :{}".format(db_profile["name"]) ) if db_cluster["name"] == db_profile["name"]: - self.logger.info("it is getting into if default") + self.logger.debug("it is getting into if default") self.db.del_one(db_collection, {"_id": profile_id}) else: - self.logger.info("it is getting into else non default") + self.logger.debug("it is getting into else non default") profile_ids.remove(profile_id) update_dict = {profile_type: profile_ids} - self.logger.info(f"the update dict is :{update_dict}") + self.logger.debug(f"the update dict is :{update_dict}") self.db.set_one( "clusters", {"_id": db_cluster["_id"]}, update_dict ) self.db.del_one("clusters", {"_id": db_cluster["_id"]}) - self.logger.info("the id is :{}".format(db_cluster["_id"])) + self.logger.debug("the id is :{}".format(db_cluster["_id"])) async def attach_profile(self, op_id, op_params, content): self.logger.info("profile attach Enter")