You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hive.apache.org by "Rajesh Balamohan (Jira)" <ji...@apache.org> on 2020/02/07 08:03:00 UTC

[jira] [Created] (HIVE-22850) Optimise lock acquisition in TxnHandler

Rajesh Balamohan created HIVE-22850:
---------------------------------------

             Summary: Optimise lock acquisition in TxnHandler
                 Key: HIVE-22850
                 URL: https://issues.apache.org/jira/browse/HIVE-22850
             Project: Hive
          Issue Type: Improvement
          Components: Hive
            Reporter: Rajesh Balamohan


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. In a synthetic workload, it was in the order of 10+ seconds. This codepath can be optimized when all lock requests are SHARED_READ.



--
This message was sent by Atlassian Jira
(v8.3.4#803005)