You can configure data forwarding rules to forward processed data to Lindorm Time Series Database (TSDB) for storage.
Prerequisites
- A TSDB instance that is deployed in a virtual private cloud (VPC) is created in the Japan (Tokyo) region. For more information, see TSDB documentation.
- A data forwarding rule is created and an SQL statement that is used to process data is written. For more information, see Configure a data forwarding rule.
Limits
- Data can be forwarded only within a region. For example, you can only forward data from an IoT Platform instance that is deployed in the Japan (Tokyo) region to a TSDB instance that is deployed in the Japan (Tokyo) region.
- You can forward data only to a TSDB instance that is deployed in a VPC.
- You can forward data only in the JSON format.
- Only TSDB is supported. Time Series Database for InfluxDB® and Ganos are not supported.
- In the forwarded messages, all fields are written to TSDB as the metric, except for the fields that are configured as the timestamp and tag value. The data types of the metric parameter support numeric and string. If you use other data types, data may fail to be written to the database.
Procedure
Data forwarding examples
The following code block provides a sample SQL statement in the data forwarding rule:
SELECT time,city,power,distance FROM "/alprodu****/myDevice/user/update";
The following section shows how the rules engine processes data and writes data to TSDB based on the SQL statement.