X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=osm_policy_module%2Fcommon%2Fmon_client.py;h=f9a51cd6fac69ac31312b1a0a8f3e6f612653134;hb=1087dcb824d02e6b1f83d6c34375f90701a724c6;hp=ff8339fe68da92f8f9eaa3fe735ebea5e13749a6;hpb=4584f8e86a492d67d120bfea1195eff1475c0a65;p=osm%2FPOL.git diff --git a/osm_policy_module/common/mon_client.py b/osm_policy_module/common/mon_client.py index ff8339f..f9a51cd 100644 --- a/osm_policy_module/common/mon_client.py +++ b/osm_policy_module/common/mon_client.py @@ -53,6 +53,7 @@ class MonClient: threshold: int, operation: str, statistic: str = "AVERAGE", + action: str = "", ): cor_id = random.randint(1, 10e7) msg = self._build_create_alarm_payload( @@ -64,6 +65,7 @@ class MonClient: threshold, statistic, operation, + action, ) log.debug("Sending create_alarm_request %s", msg) producer = AIOKafkaProducer( @@ -170,8 +172,8 @@ class MonClient: threshold: int, statistic: str, operation: str, + action: str, ): - alarm_create_request = { "correlation_id": cor_id, "alarm_name": "osm_alarm_{}_{}_{}_{}".format( @@ -182,6 +184,7 @@ class MonClient: "severity": "critical", "threshold_value": threshold, "statistic": statistic, + "action": action, "tags": { "ns_id": ns_id, "vdu_name": vdu_name,