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 data races #138

Merged
merged 4 commits into from
Sep 15, 2020
Merged

fix data races #138

merged 4 commits into from
Sep 15, 2020

Conversation

ianwilkes
Copy link
Contributor

Fixes shutdown data race in InMemCollector.Stop, and fixes test races found with go test -race

Copy link
Member

@martin308 martin308 left a comment

Choose a reason for hiding this comment

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

Seems to make sense, worth putting some before/after benchmarks in the PR body to show the impact of the new lock?

@ianwilkes
Copy link
Contributor Author

There's no impact from the new lock; it's only touched once per tick. (Compare with the various metrics, with take a lock each time they're updated.)

@ianwilkes ianwilkes merged commit 9d766b0 into main Sep 15, 2020
@ianwilkes ianwilkes deleted the ian.race branch September 15, 2020 22:57
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