Time-series model

Updated at:

The time-series model lets you store, query, and analyze time series data. It offers features such as data lifecycle, timeline indexing, hot and cold storage, and data compression for low-cost storage and high-performance querying and analysis of time series data. In connected vehicle scenarios, the time-series model is primarily for storing, querying, and analyzing vehicle trajectory data.

Note

For more information about the time-series model, see Time-series model.

How it works

In the TimeSeries model of Tablestore, a two-dimensional time series table is used to store time series data. Each row represents the data at a point in time in a time series. The time series identifiers and timestamp are the primary key columns of the row, and the data points of the time series under the timestamp are the data columns of the row. A row can contain multiple data columns. You do not need to predefine the schemas of the primary key columns and data columns. You need to only specify the names of the specific data columns when you write data to the time series table.

The TimeSeries model of Tablestore uses the multi-value model. You can specify multiple data values at one point in time. Each value corresponds to a column in the time series table, including the column name and column value. Column values support the following data types: Boolean, integer, floating-point, string, and binary.

A time series table can store time series data of different metric types. In the following figure, the time series table stores data of the following two metric types: temperature and humidity.

fig_timestreamsample

In the figure, time series identifiers consist of measurement, data source, and tags. You can call an API operation to update the properties in the metadata of a time series. The properties can be used to retrieve the time series.

After data is written to a time series table, the system automatically extracts the metadata of the time series and automatically creates a metadata index. You can retrieve a time series based on the combination of the metric name, data source, and tags.

Features

Designed for time series data, the Tablestore time-series model is ideal for scenarios such as monitoring IoT devices, collecting equipment data, and processing machine monitoring data.

  • Provides a unified-common modeling method for time series data, which eliminates the need to predefine table schemas.

  • Allows metadata indexes to be automatically created for time series and supports time series retrieval based on composite conditions.

  • Supports queries and aggregation by using SQL.

  • Supports automatic scale-out of service capabilities, high-concurrency writes and queries, and low-cost storage of petabytes of data.

Using the time-series model

You can have a quick try of the TimeSeries model by using the Tablestore console, SDKs, or CLI.