@InterfaceAudience.Private public class ConnectionCache extends Object
Constructor and Description |
---|
ConnectionCache(org.apache.hadoop.conf.Configuration conf,
UserProvider userProvider,
int cleanInterval,
int maxIdleTime) |
Modifier and Type | Method and Description |
---|---|
Admin |
getAdmin()
Caller doesn't close the admin afterwards.
|
String |
getEffectiveUser()
Get the current thread local effective user
|
RegionLocator |
getRegionLocator(byte[] tableName)
Retrieve a regionLocator for the table.
|
Table |
getTable(String tableName)
Caller closes the table afterwards.
|
void |
setEffectiveUser(String user)
Set the current thread local effective user
|
void |
shutdown()
Called when cache is no longer needed so that it can perform cleanup operations
|
boolean |
updateConnectionAccessTime()
Updates the access time for the current connection.
|
public ConnectionCache(org.apache.hadoop.conf.Configuration conf, UserProvider userProvider, int cleanInterval, int maxIdleTime) throws IOException
IOException
public void setEffectiveUser(String user)
public String getEffectiveUser()
public void shutdown()
public Admin getAdmin() throws IOException
IOException
public Table getTable(String tableName) throws IOException
IOException
public RegionLocator getRegionLocator(byte[] tableName) throws IOException
IOException
public boolean updateConnectionAccessTime()
Copyright © 2007–2019 Cloudera. All rights reserved.