use of alluxio.grpc.table.Partition in project alluxio by Alluxio.
the class ListDatabasesCommand method listTable.
/**
* Print table information to stdout.
*
* @param db the database the table exists in
* @param tableName the name of the table to dump information for
* @return 0 on success, any non-zero value otherwise
*/
public int listTable(String db, String tableName) throws AlluxioStatusException {
TableInfo table = mClient.getTable(db, tableName);
System.out.println(table);
List<Partition> partitionList = mClient.readTable(db, tableName, Constraint.getDefaultInstance());
partitionList.forEach(System.out::println);
return 0;
}