public class ThriftHiveMetastoreClient extends Object implements ThriftMetastoreClient
| Constructor and Description |
|---|
ThriftHiveMetastoreClient(org.apache.thrift.transport.TTransport transport) |
| Modifier and Type | Method and Description |
|---|---|
int |
addPartitions(List<org.apache.hadoop.hive.metastore.api.Partition> newPartitions) |
void |
alterDatabase(String databaseName,
org.apache.hadoop.hive.metastore.api.Database database) |
void |
alterPartition(String databaseName,
String tableName,
org.apache.hadoop.hive.metastore.api.Partition partition) |
void |
alterTable(String databaseName,
String tableName,
org.apache.hadoop.hive.metastore.api.Table newTable) |
void |
close() |
void |
createDatabase(org.apache.hadoop.hive.metastore.api.Database database) |
void |
createRole(String roleName,
String grantor) |
void |
createTable(org.apache.hadoop.hive.metastore.api.Table table) |
void |
deletePartitionColumnStatistics(String databaseName,
String tableName,
String partitionName,
String columnName) |
void |
deleteTableColumnStatistics(String databaseName,
String tableName,
String columnName) |
void |
dropDatabase(String databaseName,
boolean deleteData,
boolean cascade) |
boolean |
dropPartition(String databaseName,
String tableName,
List<String> partitionValues,
boolean deleteData) |
void |
dropRole(String role) |
void |
dropTable(String databaseName,
String name,
boolean deleteData) |
List<String> |
getAllDatabases() |
List<String> |
getAllTables(String databaseName) |
org.apache.hadoop.hive.metastore.api.Database |
getDatabase(String dbName) |
List<org.apache.hadoop.hive.metastore.api.FieldSchema> |
getFields(String databaseName,
String tableName) |
org.apache.hadoop.hive.metastore.api.Partition |
getPartition(String databaseName,
String tableName,
List<String> partitionValues) |
Map<String,List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj>> |
getPartitionColumnStatistics(String databaseName,
String tableName,
List<String> partitionNames,
List<String> columnNames) |
List<String> |
getPartitionNames(String databaseName,
String tableName) |
List<String> |
getPartitionNamesFiltered(String databaseName,
String tableName,
List<String> partitionValues) |
List<org.apache.hadoop.hive.metastore.api.Partition> |
getPartitionsByNames(String databaseName,
String tableName,
List<String> partitionNames) |
List<String> |
getRoleNames() |
org.apache.hadoop.hive.metastore.api.Table |
getTable(String databaseName,
String tableName) |
List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj> |
getTableColumnStatistics(String databaseName,
String tableName,
List<String> columnNames) |
List<String> |
getTableNamesByFilter(String databaseName,
String filter) |
boolean |
grantPrivileges(org.apache.hadoop.hive.metastore.api.PrivilegeBag privilegeBag) |
void |
grantRole(String role,
String granteeName,
org.apache.hadoop.hive.metastore.api.PrincipalType granteeType,
String grantorName,
org.apache.hadoop.hive.metastore.api.PrincipalType grantorType,
boolean grantOption) |
List<org.apache.hadoop.hive.metastore.api.HiveObjectPrivilege> |
listPrivileges(String principalName,
org.apache.hadoop.hive.metastore.api.PrincipalType principalType,
org.apache.hadoop.hive.metastore.api.HiveObjectRef hiveObjectRef) |
List<org.apache.hadoop.hive.metastore.api.RolePrincipalGrant> |
listRoleGrants(String principalName,
org.apache.hadoop.hive.metastore.api.PrincipalType principalType) |
List<org.apache.hadoop.hive.metastore.api.Role> |
listRoles(String principalName,
org.apache.hadoop.hive.metastore.api.PrincipalType principalType) |
boolean |
revokePrivileges(org.apache.hadoop.hive.metastore.api.PrivilegeBag privilegeBag) |
void |
revokeRole(String role,
String granteeName,
org.apache.hadoop.hive.metastore.api.PrincipalType granteeType,
boolean grantOption) |
void |
setPartitionColumnStatistics(String databaseName,
String tableName,
String partitionName,
List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj> statistics) |
void |
setTableColumnStatistics(String databaseName,
String tableName,
List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj> statistics) |
void |
setUGI(String userName) |
public ThriftHiveMetastoreClient(org.apache.thrift.transport.TTransport transport)
public void close()
close in interface ThriftMetastoreClientclose in interface Closeableclose in interface AutoCloseablepublic List<String> getAllDatabases() throws org.apache.thrift.TException
getAllDatabases in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic org.apache.hadoop.hive.metastore.api.Database getDatabase(String dbName) throws org.apache.thrift.TException
getDatabase in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<String> getAllTables(String databaseName) throws org.apache.thrift.TException
getAllTables in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<String> getTableNamesByFilter(String databaseName, String filter) throws org.apache.thrift.TException
getTableNamesByFilter in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void createDatabase(org.apache.hadoop.hive.metastore.api.Database database)
throws org.apache.thrift.TException
createDatabase in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void dropDatabase(String databaseName, boolean deleteData, boolean cascade) throws org.apache.thrift.TException
dropDatabase in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void alterDatabase(String databaseName, org.apache.hadoop.hive.metastore.api.Database database) throws org.apache.thrift.TException
alterDatabase in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void createTable(org.apache.hadoop.hive.metastore.api.Table table)
throws org.apache.thrift.TException
createTable in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void dropTable(String databaseName, String name, boolean deleteData) throws org.apache.thrift.TException
dropTable in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void alterTable(String databaseName, String tableName, org.apache.hadoop.hive.metastore.api.Table newTable) throws org.apache.thrift.TException
alterTable in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic org.apache.hadoop.hive.metastore.api.Table getTable(String databaseName, String tableName) throws org.apache.thrift.TException
getTable in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<org.apache.hadoop.hive.metastore.api.FieldSchema> getFields(String databaseName, String tableName) throws org.apache.thrift.TException
getFields in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj> getTableColumnStatistics(String databaseName, String tableName, List<String> columnNames) throws org.apache.thrift.TException
getTableColumnStatistics in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void setTableColumnStatistics(String databaseName, String tableName, List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj> statistics) throws org.apache.thrift.TException
setTableColumnStatistics in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void deleteTableColumnStatistics(String databaseName, String tableName, String columnName) throws org.apache.thrift.TException
deleteTableColumnStatistics in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic Map<String,List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj>> getPartitionColumnStatistics(String databaseName, String tableName, List<String> partitionNames, List<String> columnNames) throws org.apache.thrift.TException
getPartitionColumnStatistics in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void setPartitionColumnStatistics(String databaseName, String tableName, String partitionName, List<org.apache.hadoop.hive.metastore.api.ColumnStatisticsObj> statistics) throws org.apache.thrift.TException
setPartitionColumnStatistics in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void deletePartitionColumnStatistics(String databaseName, String tableName, String partitionName, String columnName) throws org.apache.thrift.TException
deletePartitionColumnStatistics in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<String> getPartitionNames(String databaseName, String tableName) throws org.apache.thrift.TException
getPartitionNames in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<String> getPartitionNamesFiltered(String databaseName, String tableName, List<String> partitionValues) throws org.apache.thrift.TException
getPartitionNamesFiltered in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic int addPartitions(List<org.apache.hadoop.hive.metastore.api.Partition> newPartitions) throws org.apache.thrift.TException
addPartitions in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic boolean dropPartition(String databaseName, String tableName, List<String> partitionValues, boolean deleteData) throws org.apache.thrift.TException
dropPartition in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void alterPartition(String databaseName, String tableName, org.apache.hadoop.hive.metastore.api.Partition partition) throws org.apache.thrift.TException
alterPartition in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic org.apache.hadoop.hive.metastore.api.Partition getPartition(String databaseName, String tableName, List<String> partitionValues) throws org.apache.thrift.TException
getPartition in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<org.apache.hadoop.hive.metastore.api.Partition> getPartitionsByNames(String databaseName, String tableName, List<String> partitionNames) throws org.apache.thrift.TException
getPartitionsByNames in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<org.apache.hadoop.hive.metastore.api.Role> listRoles(String principalName, org.apache.hadoop.hive.metastore.api.PrincipalType principalType) throws org.apache.thrift.TException
listRoles in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<org.apache.hadoop.hive.metastore.api.HiveObjectPrivilege> listPrivileges(String principalName, org.apache.hadoop.hive.metastore.api.PrincipalType principalType, org.apache.hadoop.hive.metastore.api.HiveObjectRef hiveObjectRef) throws org.apache.thrift.TException
listPrivileges in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<String> getRoleNames() throws org.apache.thrift.TException
getRoleNames in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void createRole(String roleName, String grantor) throws org.apache.thrift.TException
createRole in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void dropRole(String role) throws org.apache.thrift.TException
dropRole in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic boolean grantPrivileges(org.apache.hadoop.hive.metastore.api.PrivilegeBag privilegeBag)
throws org.apache.thrift.TException
grantPrivileges in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic boolean revokePrivileges(org.apache.hadoop.hive.metastore.api.PrivilegeBag privilegeBag)
throws org.apache.thrift.TException
revokePrivileges in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void grantRole(String role, String granteeName, org.apache.hadoop.hive.metastore.api.PrincipalType granteeType, String grantorName, org.apache.hadoop.hive.metastore.api.PrincipalType grantorType, boolean grantOption) throws org.apache.thrift.TException
grantRole in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void revokeRole(String role, String granteeName, org.apache.hadoop.hive.metastore.api.PrincipalType granteeType, boolean grantOption) throws org.apache.thrift.TException
revokeRole in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic List<org.apache.hadoop.hive.metastore.api.RolePrincipalGrant> listRoleGrants(String principalName, org.apache.hadoop.hive.metastore.api.PrincipalType principalType) throws org.apache.thrift.TException
listRoleGrants in interface ThriftMetastoreClientorg.apache.thrift.TExceptionpublic void setUGI(String userName) throws org.apache.thrift.TException
setUGI in interface ThriftMetastoreClientorg.apache.thrift.TExceptionCopyright © 2012–2019. All rights reserved.