safaehar commented on code in PR #68068:
URL: https://github.com/apache/airflow/pull/68068#discussion_r3397340226


##########
airflow-core/src/airflow/jobs/scheduler_job_runner.py:
##########
@@ -1223,12 +1223,16 @@ def _is_tracing_enabled():
         return conf.getboolean("traces", "otel_on")
 
     def _process_executor_events(self, executor: BaseExecutor, session: 
Session) -> int:
-        return SchedulerJobRunner.process_executor_events(
-            executor=executor,
-            job_id=self.job.id,
-            scheduler_dag_bag=self.scheduler_dag_bag,
-            session=session,
-        )
+        try:
+            return SchedulerJobRunner.process_executor_events(
+                executor=executor,
+                job_id=self.job.id,
+                scheduler_dag_bag=self.scheduler_dag_bag,
+                session=session,
+            )
+        except Exception as exc:
+            stats.incr("scheduler.executor_events.failed", tags={"reason": 
type(exc).__name__})
+            raise

Review Comment:
   No good reason actually, aligned to exception_class



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to