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

fix: raise RuntimeError("threads can only be started once") #1425

Conversation

YasuoSasaki
Copy link
Contributor

@YasuoSasaki YasuoSasaki commented May 11, 2020

fix: raise RuntimeError("threads can only be started once").

This occurs due to a race condition on AgentWriter._started when multiple threads start simultaneously and a writer has not yet been created.

@YasuoSasaki YasuoSasaki requested a review from a team as a code owner May 11, 2020 08:53
@jd
Copy link
Contributor

jd commented May 11, 2020

IIUC this happens if you have multiple threads trying to start the writer at the same time because they both emit the first span concurrently. Sounds legit.

Copy link
Member

@Kyle-Verhoog Kyle-Verhoog left a comment

Choose a reason for hiding this comment

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

@YasuoSasaki thanks for the contribution! This is indeed an issue and the fix is sufficient.

@Kyle-Verhoog Kyle-Verhoog added this to the 0.38.0 milestone May 14, 2020
@Kyle-Verhoog Kyle-Verhoog merged commit a34aafa into DataDog:master May 14, 2020
@YasuoSasaki
Copy link
Contributor Author

Thank you very much!

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.

None yet

3 participants