Jesus Camacho Rodriguez created HIVE-21871:
----------------------------------------------
Summary: Multi-statement transactions in direct SQL
Key: HIVE-21871
URL: https://issues.apache.org/jira/browse/HIVE-21871
Project: Hive
Issue Type: Bug
Components: Metastore, Standalone Metastore
Reporter: Jesus Camacho Rodriguez
To access metastore, we may bypass the JDO layer and query the metastore RDBMS
directly (we refer to this as direct SQL path).
There are some methods in Hive metastore that may issue multiple queries
against RDBMS to build the return objects (e.g. {{get_partitions_by_names}}).
Currently going through direct SQL may issue each query to the RDBMS in a
different transaction (while afaik going through JDO will create a single
transaction to retrieve and compose such objects). This may lead to failures
while running some operations concurrently, e.g., in the example above, if a
partition is being dropped and partitions are being retrieved using direct SQL
path.
A solution would be to execute all statements needed to retrieve the results
for such a function within a single transaction when we use direct SQL path.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)