public class TxnManagerFactory extends Object
HiveTxnManager
. This should
always be called rather than building a transaction manager via reflection.
This factory will read the configuration file to determine which
transaction manager to instantiate. It will stash the chosen transaction
manager into the Context object, and subsequently return it from there so
that if there are multiple Hive threads running,
each will get it's appropriate transaction manager.Modifier and Type | Method and Description |
---|---|
HiveTxnManager |
getTxnManager(HiveConf conf)
Create a new transaction manager.
|
static TxnManagerFactory |
getTxnManagerFactory()
Get the singleton instance of this factory.
|
public static TxnManagerFactory getTxnManagerFactory()
public HiveTxnManager getTxnManager(HiveConf conf) throws LockException
conf
- HiveConf object used to construct the transaction managerLockException
- if there is an error constructing the transaction
manager.Copyright © 2019 The Apache Software Foundation. All rights reserved.