ashb commented on code in PR #69809:
URL: https://github.com/apache/airflow/pull/69809#discussion_r4103313343


##########
airflow-core/src/airflow/settings.py:
##########
@@ -841,6 +841,13 @@ def initialize():
     import_local_settings()
     configure_logging()
     configure_otel(conf)
+    # configure_otel configures only the airflow-core copy of the symlinked 
shared traces
+    # module. Set the resolved flag in the task-sdk copy that providers import.
+    from airflow._shared.observability import traces as _core_traces
+    from airflow.sdk._shared.observability.traces import 
set_debug_traces_enabled
+
+    debug_traces_on = _core_traces._otel_debug_traces_on
+    set_debug_traces_enabled(debug_traces_on)

Review Comment:
   Reading a bool from the conf is currently uncached, so is suprisingly 
"expensive", especially for something that happens in the hot path of the 
scheduler, so "no, not without further changes today".
   
   That isn't to say it's not a better approach, just that if we do that we 
need a precursor PR to fix the perf issue of getbool.



-- 
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