Interface ThriftMetastoreClient
- All Superinterfaces:
AutoCloseable,Closeable
- All Known Implementing Classes:
FailureAwareThriftMetastoreClient,ThriftHiveMetastoreClient
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidabortTransaction(long transactionId) io.trino.hive.thrift.metastore.LockResponseacquireLock(io.trino.hive.thrift.metastore.LockRequest lockRequest) voidaddDynamicPartitions(String dbName, String tableName, List<String> partitionNames, long transactionId, long writeId, io.trino.hive.thrift.metastore.DataOperationType operation) intaddPartitions(List<io.trino.hive.thrift.metastore.Partition> newPartitions) default List<io.trino.hive.thrift.metastore.TxnToWriteId> allocateTableWriteIds(String database, String tableName, List<Long> transactionIds) voidalterDatabase(String databaseName, io.trino.hive.thrift.metastore.Database database) voidalterFunction(io.trino.hive.thrift.metastore.Function function) voidalterPartition(String databaseName, String tableName, io.trino.hive.thrift.metastore.Partition partition) voidalterPartitions(String dbName, String tableName, List<io.trino.hive.thrift.metastore.Partition> partitions, long writeId) voidalterTableWithEnvironmentContext(String databaseName, String tableName, io.trino.hive.thrift.metastore.Table newTable, io.trino.hive.thrift.metastore.EnvironmentContext context) voidalterTransactionalTable(io.trino.hive.thrift.metastore.Table table, long transactionId, long writeId, io.trino.hive.thrift.metastore.EnvironmentContext context) io.trino.hive.thrift.metastore.LockResponsecheckLock(long lockId) voidclose()voidcommitTransaction(long transactionId) voidcreateDatabase(io.trino.hive.thrift.metastore.Database database) voidcreateFunction(io.trino.hive.thrift.metastore.Function function) voidcreateRole(String role, String grantor) voidcreateTable(io.trino.hive.thrift.metastore.Table table) voiddeletePartitionColumnStatistics(String databaseName, String tableName, String partitionName, String columnName) voiddeleteTableColumnStatistics(String databaseName, String tableName, String columnName) voiddropDatabase(String databaseName, boolean deleteData, boolean cascade) voiddropFunction(String databaseName, String functionName) booleandropPartition(String databaseName, String tableName, List<String> partitionValues, boolean deleteData) voidvoidgetConfigValue(String name, String defaultValue) io.trino.hive.thrift.metastore.DatabasegetDatabase(String databaseName) getDelegationToken(String userName) List<io.trino.hive.thrift.metastore.FieldSchema> io.trino.hive.thrift.metastore.FunctiongetFunction(String databaseName, String functionName) getFunctions(String databaseName, String functionNamePattern) io.trino.hive.thrift.metastore.PartitiongetPartition(String databaseName, String tableName, List<String> partitionValues) getPartitionColumnStatistics(String databaseName, String tableName, List<String> partitionNames, List<String> columnNames) getPartitionNames(String databaseName, String tableName) getPartitionNamesFiltered(String databaseName, String tableName, List<String> partitionValues) List<io.trino.hive.thrift.metastore.Partition> getPartitionsByNames(String databaseName, String tableName, List<String> partitionNames) io.trino.hive.thrift.metastore.TableList<io.trino.hive.thrift.metastore.ColumnStatisticsObj> getTableColumnStatistics(String databaseName, String tableName, List<String> columnNames) List<io.trino.hive.thrift.metastore.TableMeta> getTableMeta(String databaseName) getValidWriteIds(List<String> tableList, long currentTransactionId) booleangrantPrivileges(io.trino.hive.thrift.metastore.PrivilegeBag privilegeBag) voidgrantRole(String role, String granteeName, io.trino.hive.thrift.metastore.PrincipalType granteeType, String grantorName, io.trino.hive.thrift.metastore.PrincipalType grantorType, boolean grantOption) List<io.trino.hive.thrift.metastore.HiveObjectPrivilege> listPrivileges(String principalName, io.trino.hive.thrift.metastore.PrincipalType principalType, io.trino.hive.thrift.metastore.HiveObjectRef hiveObjectRef) List<io.trino.hive.thrift.metastore.RolePrincipalGrant> listRoleGrants(String name, io.trino.hive.thrift.metastore.PrincipalType principalType) List<io.trino.hive.thrift.metastore.Role> longopenTransaction(String user) booleanrevokePrivileges(io.trino.hive.thrift.metastore.PrivilegeBag privilegeBag, boolean revokeGrantOption) voidrevokeRole(String role, String granteeName, io.trino.hive.thrift.metastore.PrincipalType granteeType, boolean grantOption) voidsendTransactionHeartbeat(long transactionId) voidsetPartitionColumnStatistics(String databaseName, String tableName, String partitionName, List<io.trino.hive.thrift.metastore.ColumnStatisticsObj> statistics) voidsetTableColumnStatistics(String databaseName, String tableName, List<io.trino.hive.thrift.metastore.ColumnStatisticsObj> statistics) voidvoidunlock(long lockId)
-
Method Details
-
close
void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
getAllDatabases
-
getDatabase
io.trino.hive.thrift.metastore.Database getDatabase(String databaseName) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
getTableMeta
-
createDatabase
void createDatabase(io.trino.hive.thrift.metastore.Database database) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
dropDatabase
void dropDatabase(String databaseName, boolean deleteData, boolean cascade) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
alterDatabase
void alterDatabase(String databaseName, io.trino.hive.thrift.metastore.Database database) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
createTable
void createTable(io.trino.hive.thrift.metastore.Table table) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
dropTable
-
alterTableWithEnvironmentContext
-
getTable
-
getFields
-
getTableColumnStatistics
-
setTableColumnStatistics
-
deleteTableColumnStatistics
-
getPartitionColumnStatistics
-
setPartitionColumnStatistics
-
deletePartitionColumnStatistics
-
getPartitionNames
-
getPartitionNamesFiltered
-
addPartitions
int addPartitions(List<io.trino.hive.thrift.metastore.Partition> newPartitions) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
dropPartition
-
alterPartition
-
getPartition
-
getPartitionsByNames
-
listRoles
-
listPrivileges
-
getRoleNames
-
createRole
-
dropRole
- Throws:
org.apache.thrift.TException
-
grantPrivileges
boolean grantPrivileges(io.trino.hive.thrift.metastore.PrivilegeBag privilegeBag) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
revokePrivileges
boolean revokePrivileges(io.trino.hive.thrift.metastore.PrivilegeBag privilegeBag, boolean revokeGrantOption) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
grantRole
-
revokeRole
-
listRoleGrants
-
setUGI
- Throws:
org.apache.thrift.TException
-
openTransaction
- Throws:
org.apache.thrift.TException
-
commitTransaction
void commitTransaction(long transactionId) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
abortTransaction
default void abortTransaction(long transactionId) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
sendTransactionHeartbeat
void sendTransactionHeartbeat(long transactionId) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
acquireLock
io.trino.hive.thrift.metastore.LockResponse acquireLock(io.trino.hive.thrift.metastore.LockRequest lockRequest) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
checkLock
io.trino.hive.thrift.metastore.LockResponse checkLock(long lockId) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
unlock
void unlock(long lockId) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
getValidWriteIds
-
getConfigValue
-
getDelegationToken
-
allocateTableWriteIds
-
alterPartitions
-
addDynamicPartitions
-
alterTransactionalTable
void alterTransactionalTable(io.trino.hive.thrift.metastore.Table table, long transactionId, long writeId, io.trino.hive.thrift.metastore.EnvironmentContext context) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
getFunction
-
getFunctions
Collection<String> getFunctions(String databaseName, String functionNamePattern) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
createFunction
void createFunction(io.trino.hive.thrift.metastore.Function function) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
alterFunction
void alterFunction(io.trino.hive.thrift.metastore.Function function) throws org.apache.thrift.TException - Throws:
org.apache.thrift.TException
-
dropFunction
-