@ThreadSafe public final class RetryHandlingTableMasterClient extends AbstractMasterClient implements TableMasterClient
AbstractClient.RpcCallable<V>
TableMasterClient.Factory
mAddress, mChannel, mClosed, mConfAddress, mConnected, mContext, mServiceVersion, mVersionService
Constructor and Description |
---|
RetryHandlingTableMasterClient(MasterClientContext conf)
Creates a new block master client.
|
Modifier and Type | Method and Description |
---|---|
protected void |
afterConnect()
This method is called after the connection is made to the remote.
|
boolean |
attachDatabase(String udbType,
String udbConnectionUri,
String udbDbName,
String dbName,
Map<String,String> configuration)
Attaches an existing database.
|
boolean |
detachDatabase(String dbName)
Detaches an existing database in the catalog master.
|
List<String> |
getAllDatabases()
Get a list of all database names.
|
List<String> |
getAllTables(String databaseName)
Get a list of all table names.
|
List<TransformJobInfo> |
getAllTransformJobInfo() |
Database |
getDatabase(String databaseName)
Get database metadata.
|
Map<String,List<ColumnStatisticsInfo>> |
getPartitionColumnStatistics(String databaseName,
String tableName,
List<String> partitionNames,
List<String> columnNames)
Get column statistics for selected partition and column.
|
List<String> |
getPartitionNames(String databaseName,
String tableName)
Get partition names with given database name and table name.
|
protected ServiceType |
getRemoteServiceType() |
protected String |
getServiceName() |
protected long |
getServiceVersion() |
TableInfo |
getTable(String databaseName,
String tableName)
Get table metadata.
|
List<ColumnStatisticsInfo> |
getTableColumnStatistics(String databaseName,
String tableName,
List<String> columnNames)
Get table column statistics with given database name,
table name and list of column names.
|
TransformJobInfo |
getTransformJobInfo(long jobId) |
List<Partition> |
readTable(String databaseName,
String tableName,
Constraint constraint)
Returns metadata for reading a table given constraints.
|
boolean |
syncDatabase(String dbName)
Syncs an existing database in the catalog master.
|
long |
transformTable(String dbName,
String tableName,
String definition)
Transforms a table.
|
getAddress, getConfAddress
afterDisconnect, beforeConnect, beforeDisconnect, checkVersion, close, connect, disconnect, getRemoteServiceVersion, isClosed, isConnected, retryRPC, retryRPC
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
connect, disconnect, getAddress, getConfAddress, isClosed, isConnected
public RetryHandlingTableMasterClient(MasterClientContext conf)
conf
- master client configurationprotected ServiceType getRemoteServiceType()
getRemoteServiceType
in class AbstractClient
protected String getServiceName()
getServiceName
in class AbstractClient
protected long getServiceVersion()
getServiceVersion
in class AbstractClient
protected void afterConnect()
AbstractClient
afterConnect
in class AbstractClient
public List<String> getAllDatabases() throws AlluxioStatusException
TableMasterClient
getAllDatabases
in interface TableMasterClient
AlluxioStatusException
public Database getDatabase(String databaseName) throws AlluxioStatusException
TableMasterClient
getDatabase
in interface TableMasterClient
databaseName
- database nameAlluxioStatusException
public List<String> getAllTables(String databaseName) throws AlluxioStatusException
TableMasterClient
getAllTables
in interface TableMasterClient
databaseName
- database nameAlluxioStatusException
public TableInfo getTable(String databaseName, String tableName) throws AlluxioStatusException
TableMasterClient
getTable
in interface TableMasterClient
databaseName
- database nametableName
- table nameAlluxioStatusException
public boolean attachDatabase(String udbType, String udbConnectionUri, String udbDbName, String dbName, Map<String,String> configuration) throws AlluxioStatusException
TableMasterClient
attachDatabase
in interface TableMasterClient
udbType
- the database typeudbConnectionUri
- the udb connection uriudbDbName
- the database name in the udbdbName
- the database name in Alluxioconfiguration
- the configuration mapAlluxioStatusException
public boolean detachDatabase(String dbName) throws AlluxioStatusException
TableMasterClient
detachDatabase
in interface TableMasterClient
dbName
- database nameAlluxioStatusException
public boolean syncDatabase(String dbName) throws AlluxioStatusException
TableMasterClient
syncDatabase
in interface TableMasterClient
dbName
- database nameAlluxioStatusException
public List<Partition> readTable(String databaseName, String tableName, Constraint constraint) throws AlluxioStatusException
TableMasterClient
readTable
in interface TableMasterClient
databaseName
- database nametableName
- table nameconstraint
- constraint on the columnsAlluxioStatusException
public List<ColumnStatisticsInfo> getTableColumnStatistics(String databaseName, String tableName, List<String> columnNames) throws AlluxioStatusException
TableMasterClient
getTableColumnStatistics
in interface TableMasterClient
databaseName
- database nametableName
- table namecolumnNames
- column namesAlluxioStatusException
public List<String> getPartitionNames(String databaseName, String tableName) throws AlluxioStatusException
TableMasterClient
getPartitionNames
in interface TableMasterClient
databaseName
- database nametableName
- table nameAlluxioStatusException
public Map<String,List<ColumnStatisticsInfo>> getPartitionColumnStatistics(String databaseName, String tableName, List<String> partitionNames, List<String> columnNames) throws AlluxioStatusException
TableMasterClient
getPartitionColumnStatistics
in interface TableMasterClient
databaseName
- database nametableName
- table namepartitionNames
- partition namescolumnNames
- column namesAlluxioStatusException
public long transformTable(String dbName, String tableName, String definition) throws AlluxioStatusException
TableMasterClient
transformTable
in interface TableMasterClient
dbName
- the database nametableName
- the table namedefinition
- the transformation definitionAlluxioStatusException
public TransformJobInfo getTransformJobInfo(long jobId) throws AlluxioStatusException
getTransformJobInfo
in interface TableMasterClient
jobId
- the transformation job's IDAlluxioStatusException
public List<TransformJobInfo> getAllTransformJobInfo() throws AlluxioStatusException
getAllTransformJobInfo
in interface TableMasterClient
AlluxioStatusException
Copyright © 2023. All Rights Reserved.