Details
-
Improvement
-
Status: Patch Available
-
Major
-
Resolution: Unresolved
-
None
-
None
-
None
Description
With concurrent queries, time taken for lock acquisition increases substantially. As part of lock acquisition in the query, TxnHandler::checkLock gets invoked. This involves getting a mutex and compare the locks being requested for, with that of existing locks in HIVE_LOCKS table.
With concurrent queries, time taken to do this check increase and this significantly increases the time taken for getting mutex for other threads (due to select for update). In a synthetic workload, it was in the order of 10+ seconds. This codepath can be optimized when all lock requests are SHARED_READ.