From d0813aeeee1f3b0638dc1b89f891add19e81f16f Mon Sep 17 00:00:00 2001 From: Julien Perrochet Date: Tue, 5 Nov 2024 11:56:42 +0100 Subject: [PATCH] [uss_qualifier] monitorlib: ISAChange exposes subscribers as returned by DSS --- monitoring/monitorlib/mutate/rid.py | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/monitoring/monitorlib/mutate/rid.py b/monitoring/monitorlib/mutate/rid.py index 851df074aa..8bf9ec979f 100644 --- a/monitoring/monitorlib/mutate/rid.py +++ b/monitoring/monitorlib/mutate/rid.py @@ -1,19 +1,15 @@ import datetime from typing import Dict, List, Optional, Union, Set -from implicitdict import ImplicitDict import s2sphere -from uas_standards import Operation - -from monitoring.monitorlib.fetch import QueryType -from monitoring.monitorlib.fetch.rid import RIDQuery, Subscription, ISA -from monitoring.monitorlib.rid import RIDVersion -from uas_standards.astm.f3411 import v19, v22a import uas_standards.astm.f3411.v19.api import uas_standards.astm.f3411.v19.constants import uas_standards.astm.f3411.v22a.api import uas_standards.astm.f3411.v22a.constants import yaml +from implicitdict import ImplicitDict +from uas_standards import Operation +from uas_standards.astm.f3411 import v19, v22a from yaml.representer import Representer from monitoring.monitorlib import ( @@ -22,6 +18,9 @@ rid_v1, rid_v2, ) +from monitoring.monitorlib.fetch import QueryType +from monitoring.monitorlib.fetch.rid import RIDQuery, Subscription, ISA +from monitoring.monitorlib.rid import RIDVersion class ChangedSubscription(RIDQuery): @@ -450,6 +449,11 @@ class ISAChange(ImplicitDict): notifications: Dict[str, ISAChangeNotification] """Mapping from USS base URL to change notification query""" + @property + def subscribers(self) -> Optional[List[SubscriberToNotify]]: + """List of subscribers that required a notification for the change.""" + return self.dss_query.subscribers + def build_isa_request_body( area_vertices: List[s2sphere.LatLng],