From 1d11b660fd0b97f7abd89af0cc67508093c23ea5 Mon Sep 17 00:00:00 2001 From: Atul Agarwal Date: Mon, 18 Oct 2021 17:22:58 +0000 Subject: [PATCH] Resolved bug 1685 - POL hangs waiting for webhook response Change-Id: Id0c3154491545c177ec3fb74aa82ad71acabdaf6 Signed-off-by: Atul Agarwal --- osm_policy_module/alarming/service.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/osm_policy_module/alarming/service.py b/osm_policy_module/alarming/service.py index 55fe864..1cc1a8d 100644 --- a/osm_policy_module/alarming/service.py +++ b/osm_policy_module/alarming/service.py @@ -27,7 +27,7 @@ import json import logging import requests -from requests.exceptions import ConnectionError +from requests.exceptions import ConnectionError, RequestException from osm_policy_module.common.common_db_client import CommonDbClient from osm_policy_module.common.lcm_client import LcmClient @@ -193,6 +193,9 @@ class AlarmingService: alarm.alarm_id, status) try: requests.post(url=action.url, json=json.dumps(payload)) + except RequestException as e: + log.info("Error connecting to url %s", action.url) + log.debug("RequestException %s", e) except ConnectionError: log.exception("Error connecting to url %s", action.url) -- 2.25.1