public interface Admin
extends java.lang.AutoCloseable
| Modifier and Type | Method and Description |
|---|---|
void |
alterFamily(org.apache.hadoop.fs.Path tablePath,
java.lang.String familyName,
FamilyDescriptor familyDesc) |
void |
alterFamily(java.lang.String tablePath,
java.lang.String familyName,
FamilyDescriptor familyDesc) |
void |
alterTable(TableDescriptor tableDesc)
Modify the attributes of an existing table.
|
void |
close()
Override
AutoCloseable.close() to avoid declaring a checked exception. |
Table |
createTable(org.apache.hadoop.fs.Path tablePath)
Creates a Json table at the specified path with 'default' column family and default options.
|
Table |
createTable(java.lang.String tablePath)
Creates a Json table at the specified path with 'default' column family and default options.
|
Table |
createTable(TableDescriptor tableDesc)
Creates a Json table using the specified TableDescriptor.
|
Table |
createTable(TableDescriptor tableDesc,
java.nio.ByteBuffer[] splitPoints)
Creates a pre-split JSON table using the specified TableDescriptor and the split points
as the tablet boundaries.
|
Table |
createTable(TableDescriptor tableDesc,
java.lang.String[] splitPoints)
Creates a pre-split Json table using the specified TableDescriptor and the split points
as the tablet boundaries.
|
boolean |
deleteFamily(org.apache.hadoop.fs.Path tablePath,
java.lang.String familyName)
Deletes a family from a Json table.
|
boolean |
deleteFamily(java.lang.String tablePath,
java.lang.String familyName)
Deletes a family from a Json table.
|
boolean |
deleteTable(org.apache.hadoop.fs.Path tablePath)
Deletes a Table.
|
boolean |
deleteTable(java.lang.String tablePath)
Deletes a Table.
|
TableDescriptor |
getTableDescriptor(org.apache.hadoop.fs.Path tablePath) |
TableDescriptor |
getTableDescriptor(java.lang.String tablePath) |
java.util.Collection<IndexDesc> |
getTableIndexes(org.apache.hadoop.fs.Path tablePath)
Returns a collection of descriptors for secondary indexes for the
specified table that are ready to server queries.
|
java.util.Collection<IndexDesc> |
getTableIndexes(java.lang.String tablePath)
Returns a collection of descriptors for secondary indexes for the
specified table that are ready to server queries.
|
java.util.List<org.apache.hadoop.fs.Path> |
listTables()
List all tables in user's home directory.
|
java.util.List<org.apache.hadoop.fs.Path> |
listTables(org.apache.hadoop.fs.Path folderOrPattern)
List all tables in the specified folder and/or with the matching pattern.
|
java.util.List<org.apache.hadoop.fs.Path> |
listTables(java.lang.String folderOrPattern)
List all tables in the specified folder and/or with the matching pattern.
|
boolean |
tableExists(org.apache.hadoop.fs.Path tablePath) |
boolean |
tableExists(java.lang.String tablePath) |
java.util.List<org.apache.hadoop.fs.Path> listTables()
throws DBException
DBExceptionjava.util.List<org.apache.hadoop.fs.Path> listTables(java.lang.String folderOrPattern)
throws DBException
folderOrPattern - the parent folder or patternDBExceptionjava.util.List<org.apache.hadoop.fs.Path> listTables(org.apache.hadoop.fs.Path folderOrPattern)
throws DBException
folderOrPattern - the parent folder or patternDBExceptionTable createTable(java.lang.String tablePath) throws TableExistsException, DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clusterTableExistsException - if a table with the specified path already exitsDBException - if some DBException occursTable createTable(org.apache.hadoop.fs.Path tablePath) throws TableExistsException, DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clusterTableExistsException - if a table with the specified path already exitsDBException - if some DBException occursTable createTable(TableDescriptor tableDesc) throws TableExistsException, DBException
tableDesc - the TableDescriptor containing various attributes of this tableTableExistsException - if the table already exist at the specified pathDBException - if an DBException occursTable createTable(TableDescriptor tableDesc, java.lang.String[] splitPoints) throws TableExistsException, DBException
tableDesc - the TableDescriptor containing various attributes of this tablesplitPoints - the split points for this tableTableExistsExceptionDBExceptionTable createTable(TableDescriptor tableDesc, java.nio.ByteBuffer[] splitPoints) throws TableExistsException, DBException
tableDesc - the TableDescriptor containing various attributes of this tablesplitPoints - the split points for this tableTableExistsExceptionDBExceptionvoid alterTable(TableDescriptor tableDesc) throws TableNotFoundException, OpNotPermittedException, DBException
tableDesc - the TableDescriptor containing various attributes of this tableTableNotFoundExceptionOpNotPermittedException - if an attribute is requested to be modified but is not allowedDBExceptionboolean deleteFamily(java.lang.String tablePath,
java.lang.String familyName)
throws TableNotFoundException,
FamilyNotFoundException,
DBException
tablePath - familyName - true if and only if the family is successfully deleted;
false otherwiseDBExceptionTableNotFoundExceptionFamilyNotFoundExceptionboolean deleteFamily(org.apache.hadoop.fs.Path tablePath,
java.lang.String familyName)
throws TableNotFoundException,
FamilyNotFoundException,
DBException
tablePath - familyName - true if and only if the family is successfully deleted;
false otherwiseDBExceptionTableNotFoundExceptionFamilyNotFoundExceptionvoid alterFamily(java.lang.String tablePath,
java.lang.String familyName,
FamilyDescriptor familyDesc)
throws TableNotFoundException,
FamilyNotFoundException,
OpNotPermittedException,
DBException
tablePath - familyName - familyDesc - TableNotFoundExceptionFamilyNotFoundExceptionOpNotPermittedException - if an attribute is requested to be modified but is not allowedDBExceptionvoid alterFamily(org.apache.hadoop.fs.Path tablePath,
java.lang.String familyName,
FamilyDescriptor familyDesc)
throws TableNotFoundException,
FamilyNotFoundException,
OpNotPermittedException,
DBException
tablePath - familyName - familyDesc - TableNotFoundExceptionFamilyNotFoundExceptionOpNotPermittedException - if an attribute is requested to be modified but is not allowedDBExceptionboolean tableExists(java.lang.String tablePath)
throws DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clustertrue if the specified path exists and is a tableDBExceptionboolean tableExists(org.apache.hadoop.fs.Path tablePath)
throws DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clustertrue if the specified path exists and is a tableDBExceptionTableDescriptor getTableDescriptor(java.lang.String tablePath) throws DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clusterDBExceptionTableDescriptor getTableDescriptor(org.apache.hadoop.fs.Path tablePath) throws DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clusterDBExceptionjava.util.Collection<IndexDesc> getTableIndexes(java.lang.String tablePath) throws DBException
DBExceptionjava.util.Collection<IndexDesc> getTableIndexes(org.apache.hadoop.fs.Path tablePath) throws DBException
DBExceptionboolean deleteTable(java.lang.String tablePath)
throws DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clustertrue if and only if the table is successfully deleted;
otherwise, falseAccessDeniedException - if the user does not have permission to delete
the table.DBExceptionboolean deleteTable(org.apache.hadoop.fs.Path tablePath)
throws DBException
tablePath - The table path.
The table path can be either absolute or relative to user's home directory.
The absolute path can be specified as "/<tablepath>" for tables in default
cluster or as "/mapr/<clustername>/<tablepath>" for tables
in the specified clustertrue if and only if the table is successfully deleted;
otherwise, falseAccessDeniedException - If the user does not have permission to delete
the table.DBExceptionvoid close()
throws DBException
AutoCloseable.close() to avoid declaring a checked exception.close in interface java.lang.AutoCloseableDBException