Interface ThriftMetastore
-
- All Known Implementing Classes:
ThriftHiveMetastore
public interface ThriftMetastore
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default voidacquireSharedReadLock(HiveIdentity identity, String queryId, long transactionId, List<SchemaTableName> fullTables, List<HivePartition> partitions)default voidacquireTableWriteLock(HiveIdentity identity, String queryId, long transactionId, String dbName, String tableName, org.apache.hadoop.hive.metastore.api.DataOperationType operation, boolean isDynamicPartitionWrite)default voidaddDynamicPartitions(HiveIdentity identity, String dbName, String tableName, List<String> partitionNames, long transactionId, long writeId, AcidOperation operation)voidaddPartitions(HiveIdentity identity, String databaseName, String tableName, List<PartitionWithStatistics> partitions)default longallocateWriteId(HiveIdentity identity, String dbName, String tableName, long transactionId)voidalterDatabase(HiveIdentity identity, String databaseName, org.apache.hadoop.hive.metastore.api.Database database)voidalterPartition(HiveIdentity identity, String databaseName, String tableName, PartitionWithStatistics partition)default voidalterPartitions(HiveIdentity identity, String dbName, String tableName, List<org.apache.hadoop.hive.metastore.api.Partition> partitions, long writeId)voidalterTable(HiveIdentity identity, String databaseName, String tableName, org.apache.hadoop.hive.metastore.api.Table table)voidalterTransactionalTable(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table, long transactionId, long writeId)default voidcommitTransaction(HiveIdentity identity, long transactionId)voidcreateDatabase(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Database database)voidcreateRole(String role, String grantor)voidcreateTable(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table)voiddropDatabase(HiveIdentity identity, String databaseName)voiddropPartition(HiveIdentity identity, String databaseName, String tableName, List<String> parts, boolean deleteData)voiddropRole(String role)voiddropTable(HiveIdentity identity, String databaseName, String tableName, boolean deleteData)List<String>getAllDatabases()List<String>getAllTables(String databaseName)List<String>getAllViews(String databaseName)default Optional<String>getConfigValue(String name)Optional<org.apache.hadoop.hive.metastore.api.Database>getDatabase(String databaseName)default Optional<List<org.apache.hadoop.hive.metastore.api.FieldSchema>>getFields(HiveIdentity identity, String databaseName, String tableName)Optional<org.apache.hadoop.hive.metastore.api.Partition>getPartition(HiveIdentity identity, String databaseName, String tableName, List<String> partitionValues)Optional<List<String>>getPartitionNamesByFilter(HiveIdentity identity, String databaseName, String tableName, List<String> columnNames, TupleDomain<String> partitionKeysFilter)List<org.apache.hadoop.hive.metastore.api.Partition>getPartitionsByNames(HiveIdentity identity, String databaseName, String tableName, List<String> partitionNames)Map<String,PartitionStatistics>getPartitionStatistics(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table, List<org.apache.hadoop.hive.metastore.api.Partition> partitions)Set<ColumnStatisticType>getSupportedColumnStatistics(Type type)Optional<org.apache.hadoop.hive.metastore.api.Table>getTable(HiveIdentity identity, String databaseName, String tableName)PartitionStatisticsgetTableStatistics(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table)List<String>getTablesWithParameter(String databaseName, String parameterKey, String parameterValue)default StringgetValidWriteIds(HiveIdentity identity, List<SchemaTableName> tables, long currentTransactionId)voidgrantRoles(Set<String> roles, Set<HivePrincipal> grantees, boolean adminOption, HivePrincipal grantor)voidgrantTablePrivileges(String databaseName, String tableName, String tableOwner, HivePrincipal grantee, Set<HivePrivilegeInfo> privileges)booleanisImpersonationEnabled()Set<RoleGrant>listGrantedPrincipals(String role)Set<RoleGrant>listRoleGrants(HivePrincipal principal)Set<String>listRoles()Set<HivePrivilegeInfo>listTablePrivileges(String databaseName, String tableName, String tableOwner, Optional<HivePrincipal> principal)default longopenTransaction(HiveIdentity identity)voidrevokeRoles(Set<String> roles, Set<HivePrincipal> grantees, boolean adminOption, HivePrincipal grantor)voidrevokeTablePrivileges(String databaseName, String tableName, String tableOwner, HivePrincipal grantee, Set<HivePrivilegeInfo> privileges)default voidsendTransactionHeartbeat(HiveIdentity identity, long transactionId)voidupdatePartitionStatistics(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table, String partitionName, Function<PartitionStatistics,PartitionStatistics> update)voidupdateTableStatistics(HiveIdentity identity, String databaseName, String tableName, AcidTransaction transaction, Function<PartitionStatistics,PartitionStatistics> update)default voidupdateTableWriteId(HiveIdentity identity, String dbName, String tableName, long transactionId, long writeId, OptionalLong rowCountChange)
-
-
-
Method Detail
-
createDatabase
void createDatabase(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Database database)
-
dropDatabase
void dropDatabase(HiveIdentity identity, String databaseName)
-
alterDatabase
void alterDatabase(HiveIdentity identity, String databaseName, org.apache.hadoop.hive.metastore.api.Database database)
-
createTable
void createTable(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table)
-
dropTable
void dropTable(HiveIdentity identity, String databaseName, String tableName, boolean deleteData)
-
alterTable
void alterTable(HiveIdentity identity, String databaseName, String tableName, org.apache.hadoop.hive.metastore.api.Table table)
-
alterTransactionalTable
void alterTransactionalTable(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table, long transactionId, long writeId)
-
getTablesWithParameter
List<String> getTablesWithParameter(String databaseName, String parameterKey, String parameterValue)
-
getDatabase
Optional<org.apache.hadoop.hive.metastore.api.Database> getDatabase(String databaseName)
-
addPartitions
void addPartitions(HiveIdentity identity, String databaseName, String tableName, List<PartitionWithStatistics> partitions)
-
dropPartition
void dropPartition(HiveIdentity identity, String databaseName, String tableName, List<String> parts, boolean deleteData)
-
alterPartition
void alterPartition(HiveIdentity identity, String databaseName, String tableName, PartitionWithStatistics partition)
-
getPartitionNamesByFilter
Optional<List<String>> getPartitionNamesByFilter(HiveIdentity identity, String databaseName, String tableName, List<String> columnNames, TupleDomain<String> partitionKeysFilter)
-
getPartition
Optional<org.apache.hadoop.hive.metastore.api.Partition> getPartition(HiveIdentity identity, String databaseName, String tableName, List<String> partitionValues)
-
getPartitionsByNames
List<org.apache.hadoop.hive.metastore.api.Partition> getPartitionsByNames(HiveIdentity identity, String databaseName, String tableName, List<String> partitionNames)
-
getTable
Optional<org.apache.hadoop.hive.metastore.api.Table> getTable(HiveIdentity identity, String databaseName, String tableName)
-
getSupportedColumnStatistics
Set<ColumnStatisticType> getSupportedColumnStatistics(Type type)
-
getTableStatistics
PartitionStatistics getTableStatistics(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table)
-
getPartitionStatistics
Map<String,PartitionStatistics> getPartitionStatistics(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table, List<org.apache.hadoop.hive.metastore.api.Partition> partitions)
-
updateTableStatistics
void updateTableStatistics(HiveIdentity identity, String databaseName, String tableName, AcidTransaction transaction, Function<PartitionStatistics,PartitionStatistics> update)
-
updatePartitionStatistics
void updatePartitionStatistics(HiveIdentity identity, org.apache.hadoop.hive.metastore.api.Table table, String partitionName, Function<PartitionStatistics,PartitionStatistics> update)
-
dropRole
void dropRole(String role)
-
grantRoles
void grantRoles(Set<String> roles, Set<HivePrincipal> grantees, boolean adminOption, HivePrincipal grantor)
-
revokeRoles
void revokeRoles(Set<String> roles, Set<HivePrincipal> grantees, boolean adminOption, HivePrincipal grantor)
-
listRoleGrants
Set<RoleGrant> listRoleGrants(HivePrincipal principal)
-
grantTablePrivileges
void grantTablePrivileges(String databaseName, String tableName, String tableOwner, HivePrincipal grantee, Set<HivePrivilegeInfo> privileges)
-
revokeTablePrivileges
void revokeTablePrivileges(String databaseName, String tableName, String tableOwner, HivePrincipal grantee, Set<HivePrivilegeInfo> privileges)
-
listTablePrivileges
Set<HivePrivilegeInfo> listTablePrivileges(String databaseName, String tableName, String tableOwner, Optional<HivePrincipal> principal)
- Parameters:
principal- when empty, all table privileges are returned
-
isImpersonationEnabled
boolean isImpersonationEnabled()
-
getFields
default Optional<List<org.apache.hadoop.hive.metastore.api.FieldSchema>> getFields(HiveIdentity identity, String databaseName, String tableName)
-
openTransaction
default long openTransaction(HiveIdentity identity)
-
commitTransaction
default void commitTransaction(HiveIdentity identity, long transactionId)
-
sendTransactionHeartbeat
default void sendTransactionHeartbeat(HiveIdentity identity, long transactionId)
-
acquireSharedReadLock
default void acquireSharedReadLock(HiveIdentity identity, String queryId, long transactionId, List<SchemaTableName> fullTables, List<HivePartition> partitions)
-
getValidWriteIds
default String getValidWriteIds(HiveIdentity identity, List<SchemaTableName> tables, long currentTransactionId)
-
allocateWriteId
default long allocateWriteId(HiveIdentity identity, String dbName, String tableName, long transactionId)
-
acquireTableWriteLock
default void acquireTableWriteLock(HiveIdentity identity, String queryId, long transactionId, String dbName, String tableName, org.apache.hadoop.hive.metastore.api.DataOperationType operation, boolean isDynamicPartitionWrite)
-
updateTableWriteId
default void updateTableWriteId(HiveIdentity identity, String dbName, String tableName, long transactionId, long writeId, OptionalLong rowCountChange)
-
alterPartitions
default void alterPartitions(HiveIdentity identity, String dbName, String tableName, List<org.apache.hadoop.hive.metastore.api.Partition> partitions, long writeId)
-
addDynamicPartitions
default void addDynamicPartitions(HiveIdentity identity, String dbName, String tableName, List<String> partitionNames, long transactionId, long writeId, AcidOperation operation)
-
-