Release table metadata lock for SELECT when ready to fetch the rows
Bug #1440054 reported by
Valerii Kravchuk
This bug affects 1 person
Affects | Status | Importance | Assigned to | Milestone | ||
---|---|---|---|---|---|---|
MySQL Server |
Unknown
|
Unknown
|
||||
Percona Server moved to https://jira.percona.com/projects/PS | Status tracked in 5.7 | |||||
5.5 |
Won't Fix
|
Undecided
|
Unassigned | |||
5.6 |
Triaged
|
Wishlist
|
Unassigned | |||
5.7 |
Triaged
|
Wishlist
|
Unassigned |
Bug Description
See this upstream bug report for the details:
http://
This is essentially a feature request to implement a relaxed metadata locking model for SELECTs (the same as we have for PREPARE maybe?).
Is this possible any time soon?
It seems lock released after we execute PREPARE is then taken again after we executed EXECUTE. So, real question remain:
Is there any way to release metadata lock:
mysql> select * from performance_ schema. metadata_ locks\G ******* ******* ****** 1. row ******* ******* ******* ******
OBJECT_ TYPE: TABLE
OBJECT_ SCHEMA: test
OBJECT_ NAME: t INSTANCE_ BEGIN: 140044187351136
LOCK_ TYPE: SHARED_READ
LOCK_DURATION: TRANSACTION
LOCK_ STATUS: GRANTED
SOURCE: sql_parse.cc:5585 THREAD_ ID: 24
OWNER_EVENT_ ID: 16
*******
OBJECT_
OWNER_
(the above is the output from 5.7) as soon as we've determined list of columns (prepared the statement) and then do not set it again, even when autocommit=0?