Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

concurrent-api: defer logging during CapturedContextProviders initialization #3202

Conversation

bryce-anderson
Copy link
Contributor

Motivation:

The MDC utilities depend on the AsyncContext for storing properties. This can create a cyclical dependency since we try to log the loaded providers as part of the initialization.

Modifications:

Submit the logging to a different thread so that it will happen 'later' after the class initialization is complete.

…ization

Motivation:

The MDC utilities depend on the AsyncContext for storing properties.
This can create a cyclical dependency since we try to log the
loaded providers as part of the initialization.

Modifications:

Submit the logging to a different thread so that it will happen 'later'
after the class initialization is complete.
@bryce-anderson bryce-anderson force-pushed the bl_anderson/DontLogOnCaptureProviderInit branch from 58fe334 to 9e8660d Compare March 3, 2025 23:39
Copy link
Member

@idelpivnitskiy idelpivnitskiy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@bryce-anderson bryce-anderson merged commit fa48ce4 into apple:main Mar 4, 2025
11 checks passed
@bryce-anderson bryce-anderson deleted the bl_anderson/DontLogOnCaptureProviderInit branch March 4, 2025 02:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants