Use Tablestore SDK for Java to list all time series tables in an instance and retrieve their names, configurations, and status information.
Prerequisites
Install the Tablestore SDK for Java and initialize a time series client.
Description
Call listTimeseriesTable to list all time series tables in the current instance.
public ListTimeseriesTableResponse listTimeseriesTable()
The following example lists time series tables and prints the name, status, and time series data TTL of each table.
TimeseriesClient timeseriesClient = client.asTimeseriesClient();
ListTimeseriesTableResponse response =
timeseriesClient.listTimeseriesTable();
for (TimeseriesTableMeta tableMeta : response.getTimeseriesTableMetas()) {
System.out.println(tableMeta.getTimeseriesTableName());
System.out.println(tableMeta.getStatus());
System.out.println(tableMeta.getTimeseriesTableOptions().getTimeToLive());
}
Parameters
The listTimeseriesTable method does not take request parameters.
Response
ListTimeseriesTableResponse contains the following operation-specific field.
|
Field |
Type |
Description |
|
|
|
Call |
Time series table information
Each element in timeseriesTableMetas[] is of the TimeseriesTableMeta type and contains the following fields.
|
Field |
Type |
Description |
|
|
|
Call |
|
|
|
Call |
|
|
|
Call |
|
|
|
Call |
|
|
|
Call |
|
|
|
Call |
Time series data configurations
timeseriesTableMetas[].timeseriesTableOptions is of the TimeseriesTableOptions type and contains the following field.
|
Field |
Type |
Description |
|
|
|
Call |
Time series metadata configurations
timeseriesTableMetas[].timeseriesMetaOptions is of the TimeseriesMetaOptions type and contains the following fields.
|
Field |
Type |
Description |
|
|
|
Call |
|
|
|
Call |
Data field primary keys
Each element in timeseriesTableMetas[].fieldPrimaryKeys[] is of the PrimaryKeySchema type and contains the following fields.
|
Field |
Type |
Description |
|
|
|
Call |
|
|
|
Call |