github-actions[bot] opened a new pull request, #64720:
URL: https://github.com/apache/airflow/pull/64720

   Reset the OTel SDK's Once() guard on _METER_PROVIDER_SET_ONCE before
   calling set_meter_provider() in get_otel_logger(). When a forked child
   process re-initializes Stats (detected via PID mismatch in stats.py),
   the inherited Once._done = True flag prevents the new MeterProvider from
   being registered. The child falls back to the parent's stale provider
   whose PeriodicExportingMetricReader thread is dead after fork, causing
   task-level metrics like ti.finish to be silently dropped.
   
   The fix resets _done and _METER_PROVIDER before each set_meter_provider()
   call. On first initialization (no fork), _done is already False so this
   is a no-op. On re-initialization after fork, it allows the new provider
   to be set correctly.
   (cherry picked from commit ff77bd2f095ae3169d04024ecf8c444c3123a973)
   
   Co-authored-by: Michael Black 
<[email protected]>
   Closes: #64690


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