Data Forwarding Overview

更新时间:
复制 MD 格式

IoT Platform lets you use SQL scripts to process data from device topics and forward the processed data to other topics or Alibaba Cloud products for storage or processing.

What is data forwarding

When devices communicate with IoT Platform using topics, you can write SQL statements to process topic data and configure rules to forward the results to other device topics or Alibaba Cloud services.

Data destination

Description

References

Topic

Forwards data to another device's topic to enable M2M communication.

Forward data to another topic

AMQP consumer group

Subscribes to a consumer group through an AMQP server-side subscription to forward device messages to your business server.

RDS

Forwards device data to Alibaba Cloud products for storage.

Forward data to ApsaraDB RDS

Tablestore

Forward data to Tablestore

TSDB

Forward data to Time Series Database (TSDB)

DataHub

Forwards device data to DataHub. You can then use Realtime Compute for stream computing or MaxCompute for large-scale offline computing.

Forward data to DataHub

RocketMQ

Forwards device data to Message Queue for Apache RocketMQ or Simple Message Queue (formerly MNS) (SMQ) for highly reliable data consumption.

Forward data to Message Queue for Apache RocketMQ

MNS

Forward data to Message Service (MNS)

Function Compute

Forwards device data to Function Compute for event-driven computing.

Forward data to Function Compute (FC)

Data forwarding flow

With data forwarding, you can build a full-stack service for data collection, processing, and storage without purchasing servers to deploy a distributed architecture.

image

Usage notes

  • You can forward device data using either server-side subscription or data forwarding. Select a method based on your business scenario. For more information, see Comparison of data forwarding methods.

  • When you forward device data to other Alibaba Cloud products, make sure that the destination product is available in the target region and supports data forwarding in the required format. For more information, see Features by region.

Limits

Limitations

Description

Limit

Number of rules

A maximum of 1,000 rules can be set for an instance.

1,000

Number of destinations

A rule can contain a maximum of 10 data forwarding operations.

10

Message forwarding TPS

  • New and legacy public instances: The message forwarding TPS for an Alibaba Cloud account is a fixed value.

  • Enterprise instance: The message forwarding TPS for an instance is determined by the purchased specifications for Message Forwarding TPS.

    For more information about how to purchase an Enterprise instance, see Purchase an Enterprise instance.

RAM users share the quota of the Alibaba Cloud account.

Message forwarding TPS is calculated as follows:

Message forwarding TPS = (Number of messages sent to your business server per second using server-side subscriptions) + (Number of messages sent using data forwarding).

Within the same second, n messages may be forwarded to the data forwarding service and then to m destinations. The message forwarding TPS is calculated based on the following rules:

  • If n >= m, the message forwarding TPS is n.

  • If n < m, the message forwarding TPS is m.

Note
  • For messages forwarded to other Alibaba Cloud services, if the number of requests exceeds the limit, or if the number of concurrent write requests exceeds 40 due to high write latency of the destination service, data forwarding is throttled.

    When data is forwarded to Alibaba Cloud services such as RocketMQ, RDS, and TSDB, if the destination service becomes inaccessible due to resource changes, the system stops forwarding data and displays a rule error. For other exceptions, the system retries three times at intervals of 1, 3, and 10 seconds. If all three retries fail, the message is discarded, and an error record is sent to the destination service that you specified for error data.

  • For throttled messages, the system automatically retries processing. Data that fails to be processed after multiple retries is discarded.

Destination requirements

Data forwarding depends on the destination Alibaba Cloud service. Make sure the instance of the destination service is running as expected. Message forwarding may fail due to exceptions such as instance downtime, overdue payments, parameter errors (such as authorization changes or invalid values), or configuration errors of the destination service.

None

Message deduplication

During data forwarding, the same message may be sent multiple times to ensure delivery, until the client returns an ACK or the message expires. The same message has the same message ID. You can deduplicate messages based on their message IDs.

None

Guides

  • Configure a data forwarding rule: How to configure a data forwarding rule.

  • SQL expressions: Syntax of SQL expressions in rules.

  • Functions: Functions supported in SQL expressions.

  • Data forwarding process: The data forwarding process and the data format at each stage.

  • Data formats: Data formats of messages from basic communication topics and Thing Specification Language (TSL) model communication topics after TSL parsing. SQL fields in data forwarding rules must follow these parsed formats.

References

Data forwarding (new)