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 SharedMetricRegistries thread-safe #1094

Merged
merged 1 commit into from
Feb 27, 2017

Conversation

arteam
Copy link
Member

@arteam arteam commented Feb 27, 2017

Change defaultRegistryName from volatile to AtomicReference. This allows to us to perform an atomic set of the default registry bane and not end up with a lost update.

This also adds a package-private setter for defaultRegistryName for testing purposes, so we don't perform any reflection hacks in the unit tests.

Change `defaultRegistryName` from volatile to `AtomicReference`. This allows to us
to perform an atomic set of the default registry bane and not end  up with a lost update.

This also adds a package-private setter for `defaultRegistryName` for testing purposes,
so we don't perform any reflection hacks in the unit tests.
@arteam arteam requested a review from jplock February 27, 2017 08:39
@arteam arteam added the bug label Feb 27, 2017
@arteam arteam added this to the 3.2.1 milestone Feb 27, 2017
@arteam
Copy link
Member Author

arteam commented Feb 27, 2017

Based on the work of @mattnelson in #849

@jplock jplock merged commit b4fa7c0 into 3.2-development Feb 27, 2017
@jplock jplock deleted the fix_shared_metric_registry branch February 27, 2017 11:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants