You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@hive.apache.org by "Jesus Camacho Rodriguez (JIRA)" <ji...@apache.org> on 2018/02/23 00:08:00 UTC

[jira] [Work started] (HIVE-18776) MaterializationsInvalidationCache loading causes race condition in the metastore

     [ https://issues.apache.org/jira/browse/HIVE-18776?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Work on HIVE-18776 started by Jesus Camacho Rodriguez.
------------------------------------------------------
> MaterializationsInvalidationCache loading causes race condition in the metastore
> --------------------------------------------------------------------------------
>
>                 Key: HIVE-18776
>                 URL: https://issues.apache.org/jira/browse/HIVE-18776
>             Project: Hive
>          Issue Type: Bug
>          Components: Materialized views, Metastore
>    Affects Versions: 3.0.0
>            Reporter: Alan Gates
>            Assignee: Jesus Camacho Rodriguez
>            Priority: Major
>
> I am seeing occasional failures running metastore tests where operations are failing saying that there is no open transaction.  I have traced this to a race condition in loading the materialized view invalidation cache.  When it is initialized (either in HiveMetaStoreClient in embedded mode or in HiveMetaStore in remote mode) it grabs a copy of the current RawStore instance and then loads the cache in a separate thread.  But ObjectStore keeps state regarding JDO transactions with the underlying RDBMS.  So with the loader thread and the initial thread both doing operations against the RawStore they sometimes mess up each others transaction stack.  In a quick test I used HMSHandler.newRawStoreForConf() to fix this, which seemed to work.
> A reference to the TxnHandler is also called.  I suspect this will run into a similar issue.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)