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

[Enhancement Request] Enable to distinguish rdonly and replica type when using mysql probe #562

Open
newborn22 opened this issue Oct 28, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@newborn22
Copy link
Collaborator

Background

The MySQL probe component cannot distinguish between the rdonly and replica roles. In the current WeScale-MySQL cluster, there will be no rdonly type vttablets.

The reason is that in MySQL, both the replica and rdonly roles set the read_only system variable to 1.

Proposal

The rdonly role can be set either through flag parameters when the vttablet starts, or through external API calls after the vttablet has started. In the role detection module, if the current case is identified as a Wescale-MySQL cluster and the vttablet role type is rdonly, the type of the vttablet will no longer be obtained from the MySQL probe.

This approach means that once a vttablet is assigned the rdonly role, its type can only be changed through external API calls. Considering the purpose of the rdonly role, this approach seems reasonable.

@newborn22 newborn22 added the enhancement New feature or request label Oct 28, 2024
@newborn22 newborn22 changed the title [Enhancement Request] [Enhancement Request] Enable to distinguish rdonly and replica type when using mysql probe Oct 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant