You can call the DescribeTable operation to query the description such as the schema information, reserved read throughput, and reserved write throughput of a table.1111

Note For more information about the DescribeTable operation, see DescribeTable.


  • OTSClient is initialized. For more information, see Initialization.
  • A table is created.


Parameter Description
tableName The name of the table.


private static void describeTable(SyncClient client) {
    DescribeTableRequest request = new DescribeTableRequest(TABLE_NAME);
    DescribeTableResponse response = client.describeTable(request);
    TableMeta tableMeta = response.getTableMeta();
    System.out.println("The name of the table:" + tableMeta.getTableName());
    System.out.println("The primary key of the table:");
    for (PrimaryKeySchema primaryKeySchema : tableMeta.getPrimaryKeyList()) {
    TableOptions tableOptions = response.getTableOptions();
    System.out.println("TTL of the table:" + tableOptions.getTimeToLive());
    System.out.println("MaxVersions of the table:" + tableOptions.getMaxVersions());
    ReservedThroughputDetails reservedThroughputDetails = response.getReservedThroughputDetails();
    System.out.println("Reserved read throughput of the table:"
            + reservedThroughputDetails.getCapacityUnit().getReadCapacityUnit());
    System.out.println("Reserved write throughput of the table:"
            + reservedThroughputDetails.getCapacityUnit().getWriteCapacityUnit());