From c261bfe52a04c88ef44e8642d4c2c12fb2e9a7ab Mon Sep 17 00:00:00 2001 From: "aurelien.legrand01@gmail.com" Date: Thu, 3 Nov 2022 11:21:58 +0100 Subject: [PATCH] Improving comment for Redis. --- .../network-dashboard/cloud-function/metrics/subnets.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/blueprints/cloud-operations/network-dashboard/cloud-function/metrics/subnets.py b/blueprints/cloud-operations/network-dashboard/cloud-function/metrics/subnets.py index c8ba37fc..cb16c9c8 100644 --- a/blueprints/cloud-operations/network-dashboard/cloud-function/metrics/subnets.py +++ b/blueprints/cloud-operations/network-dashboard/cloud-function/metrics/subnets.py @@ -291,11 +291,11 @@ def compute_subnet_utilization_redis(config, read_mask, all_subnets_dict): # Only handling PSA for Redis for now if connect_mode == "PRIVATE_SERVICE_ACCESS": - # Reddis instance asset doesn't contain the subnet information in Asset Inventory - # We need to find the correct subnet with IP address matching redis_ip_range = ipaddress.ip_network(ip_range) for subnet_key, subnet_dict in all_subnets_dict[project_id].items(): if subnet_dict["network_name"] == network_name: + # Reddis instance asset doesn't contain the subnet information in Asset Inventory + # We need to find the correct subnet range with IP address matching to compute the utilization if redis_ip_range.overlaps( ipaddress.ip_network(subnet_dict['ip_cidr_range'])): all_subnets_dict[project_id][subnet_key][