From 886c6362ce6bd4f9433098d6f128db33963b4777 Mon Sep 17 00:00:00 2001 From: vitor-aignosi Date: Thu, 18 Dec 2025 12:16:37 -0300 Subject: [PATCH] SIENTIAPDE-1445 Enhance MongoDB activity to handle missing topic configurations gracefully by using get() method and skipping empty collections, improving robustness in pipeline processing. --- orchestrator/activities/mongo_db.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/orchestrator/activities/mongo_db.py b/orchestrator/activities/mongo_db.py index 0339ab5..4ae3a96 100644 --- a/orchestrator/activities/mongo_db.py +++ b/orchestrator/activities/mongo_db.py @@ -393,7 +393,9 @@ class MongoDB(SientiaMonitoring): created_indexes = [] for _pipeline_name, pipeline_config in pipelines.items(): - collection = pipeline_config['topic'] + collection = pipeline_config.get('topic', None) + if not collection: + continue try: # Check if collection exists