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

Make StartupLogger more resilient #1972

Merged
merged 2 commits into from
Jan 12, 2023

Conversation

pjanotti
Copy link
Contributor

Why

The StartupLogger can hit errors when used.

Fixes #1885

What

The StartupLogger was made more resilient by adding the capability to handle the following cases:

  1. If the AppDomain friendly name is repeated - this is done by adding the AppDomain.Id to the log file name.
  2. If the AppDomain friendly name has invalid chars for a file name - these chars are replaced by an underscore.
  3. Protects against concurrent access to the file sink.

Tests

Added a dedicated tests to exercise the new capabilities.

Checklist

  • CHANGELOG.md is updated.
    - [ ] Documentation is updated.
  • New features are covered by tests.

@pjanotti pjanotti requested a review from a team January 11, 2023 15:09
@pjanotti pjanotti merged commit 7ae4916 into open-telemetry:main Jan 12, 2023
@pjanotti pjanotti deleted the fix-loader-log-conflict branch January 12, 2023 16:28
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.

IOException: Log cannot be accessed because it is used by another process
5 participants