Skip to content

Commit

Permalink
uis subscription data sync info (UIS-597)
Browse files Browse the repository at this point in the history
  • Loading branch information
dwsutherland committed May 29, 2024
1 parent 450728a commit 3c40408
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions cylc/flow/network/resolvers.py
Original file line number Diff line number Diff line change
Expand Up @@ -569,6 +569,8 @@ async def subscribe_delta(
delta_queues = self.data_store_mgr.delta_queues
deltas_queue: DeltaQueue = queue.Queue()

self.data_store_mgr.graphql_sub_interrogate(sub_id, info)

Check warning on line 572 in cylc/flow/network/resolvers.py

View check run for this annotation

Codecov / codecov/patch

cylc/flow/network/resolvers.py#L572

Added line #L572 was not covered by tests

counters: Dict[str, int] = {}
delta_yield_queue: DeltaQueue = queue.Queue()
flow_delta_queues: Dict[str, queue.Queue[Tuple[str, dict]]] = {}
Expand All @@ -591,6 +593,9 @@ async def subscribe_delta(
if w_id in self.data_store_mgr.data:
if sub_id not in delta_queues[w_id]:
delta_queues[w_id][sub_id] = deltas_queue
await self.data_store_mgr.graphql_sub_data_match(

Check warning on line 596 in cylc/flow/network/resolvers.py

View check run for this annotation

Codecov / codecov/patch

cylc/flow/network/resolvers.py#L596

Added line #L596 was not covered by tests
w_id, sub_id
)
# On new yield workflow data-store as added delta
if args.get('initial_burst'):
delta_store = create_delta_store(
Expand Down Expand Up @@ -658,6 +663,7 @@ async def subscribe_delta(
import traceback
logger.warning(traceback.format_exc())
finally:
self.data_store_mgr.graphql_sub_discard(sub_id)

Check warning on line 666 in cylc/flow/network/resolvers.py

View check run for this annotation

Codecov / codecov/patch

cylc/flow/network/resolvers.py#L666

Added line #L666 was not covered by tests
for w_id in w_ids:
if delta_queues.get(w_id, {}).get(sub_id):
del delta_queues[w_id][sub_id]
Expand Down

0 comments on commit 3c40408

Please sign in to comment.