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 CONFIG SET command thread safe #310

Merged
merged 1 commit into from
Jun 16, 2021
Merged

Make CONFIG SET command thread safe #310

merged 1 commit into from
Jun 16, 2021

Conversation

ShooterIT
Copy link
Member

There may be more than one thread to change config, especially, complex config (such as std::set profiling_sample_commands), it is not thread safe, and other threads also may read wrong config,
to make it easy, just use ExclusivityGuard for CONFIG SET command to avoid changing config concurrently.

@ShooterIT ShooterIT merged commit 8041f03 into apache:unstable Jun 16, 2021
@ShooterIT ShooterIT deleted the config-set branch June 16, 2021 14:46
ShooterIT added a commit that referenced this pull request Jun 16, 2021
There may be more than one thread to change config, especially, complex config
(such as std::set profiling_sample_commands), it is not thread safe, and other
threads also may read wrong config, to make it easy, just use ExclusivityGuard
for CONFIG SET command to avoid changing config concurrently.
@ShooterIT ShooterIT changed the title Use ExclusivityGuard for CONFIG SET command Make CONFIG SET command thread safe Jul 15, 2021
ShooterIT added a commit to ShooterIT/kvrocks that referenced this pull request Jul 15, 2021
There may be more than one thread to change config, especially, complex config
(such as std::set profiling_sample_commands), it is not thread safe, and other
threads also may read wrong config, to make it easy, just use ExclusivityGuard
for CONFIG SET command to avoid changing config concurrently.
@ShooterIT ShooterIT mentioned this pull request Jul 15, 2021
ShooterIT added a commit that referenced this pull request Jul 19, 2021
There may be more than one thread to change config, especially, complex config
(such as std::set profiling_sample_commands), it is not thread safe, and other
threads also may read wrong config, to make it easy, just use ExclusivityGuard
for CONFIG SET command to avoid changing config concurrently.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants