-
Notifications
You must be signed in to change notification settings - Fork 8
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
Feature Request: "Support 'set' command to enable failpoint" in vtgate #247
Comments
I love the idea. I think it doesn't have to be a 'set command', it can also be an internal function, even a HTTP or gPRC API (HTTP/gRPC may not be as convienent as internal function, BTW). |
I am looking to incorporate some 'set' commands in vtgate, set @add_failpoint = 'key=value';
set @remove_failpoint = 'key';
select @show_failpoint; |
I think |
How about the vttablet? |
yeah, I also agree with you. |
Consider adding the @put_failpoint(key, val, vttablet type[primary or follower or what target special vttablet parameters]) command? |
The scope of failpoint should be global. One possible approach is: when set @put_failpoint = 'key1=value1’; is called, VTGate will notify all VTTablets. |
I think the former is better. I can do this by reusing reloadExec or creating new grpc interface? |
sure
|
If we need to inject a failPoint specifically into the primary MySQL instance and not into other MySQL instances, then broadcasting might not be the best approach? |
I think the default behavior can be "broadcasting." If we need to inject to a specific vttablet, we can add some hints. |
How about replacing |
I think |
|
What results do you expect from the "show failpoints" command? All defined failpoints or all enabled failpoints? @gerayking |
I think "All defined failpoints" maybe better. This allows us to use the |
Hmm, Interesting idea. But how would you collect all defined failpoints? |
I don't have a elegant solution yet, but I'm considering two approaches:
|
Sure you can have a "static map[string]string to track the failpoints". |
Let me try to understand what you mean, and please correct me if I'm wrong @gerayking :
|
|
Feature Description
Currently, injecting failpoints is only supported via environment variables or direct code injection. However, in most cases, we need to dynamically set failpoints to enable or disable them. Therefore, the best solution is to add a 'set' command that allows enabling or disabling fail injection on the fly.
Use Case(s)
No response
The text was updated successfully, but these errors were encountered: