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

Support for lock and unlock tables #7139

Merged
merged 7 commits into from
Dec 9, 2020

Conversation

harshit-gangal
Copy link
Member

@harshit-gangal harshit-gangal commented Dec 8, 2020

Signed-off-by: Harshit Gangal harshit@planetscale.com

Backport

NO

Status

READY

Description

Currently we allow lock tables and unlock tables to be passed down to vttablet. This does not work as expected because the lock is taken on any connection from the pool and next query is executed on second random connection from the pool.
This causes the mysql to be locked for all the connections.

Current PR will not allow these statements to be sent down the vttablet and will log a warning message.

Related Issue(s)

Fixes #7070

Impacted Areas in Vitess

List general components of the application that this PR will affect:

  • Query Serving

harshit-gangal and others added 5 commits December 8, 2020 21:51
Signed-off-by: Harshit Gangal <harshit@planetscale.com>
Signed-off-by: GuptaManan100 <manan@planetscale.com>
Signed-off-by: Harshit Gangal <harshit@planetscale.com>
Signed-off-by: Harshit Gangal <harshit@planetscale.com>
Signed-off-by: GuptaManan100 <manan@planetscale.com>
@harshit-gangal harshit-gangal marked this pull request as ready for review December 9, 2020 13:08
Signed-off-by: Harshit Gangal <harshit@planetscale.com>
Signed-off-by: Harshit Gangal <harshit@planetscale.com>
Copy link
Contributor

@shlomi-noach shlomi-noach left a comment

Choose a reason for hiding this comment

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

🚅

@harshit-gangal harshit-gangal merged commit 41ecdc0 into vitessio:master Dec 9, 2020
@harshit-gangal harshit-gangal deleted the lock_tables branch December 9, 2020 17:00
@askdba askdba added this to the v9.0 milestone Dec 10, 2020
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.

Trying to write to a locked table hangs
4 participants