Limits

更新时间:
复制 MD 格式

IoT Platform enforces specific limits and performance metrics on device access, messaging, data forwarding, and other features.

Device access

  • Number of products

    Region

    Description

    Limit

    China (Shanghai), China (Beijing), China (Shenzhen), Singapore, Japan (Tokyo), Germany (Frankfurt), US (Silicon Valley), and US (Virginia)

    Standard, Premium, and public instances: The maximum number of products that can be created in an instance.

    1,000

    MQTT-based instance: The maximum number of products that can be created in an instance.

    1

  • Number of devices

    • Maximum number of devices that can be added to a product:

      Region

      Limit

      China (Shanghai)

      3,000,000

      China (Beijing), China (Shenzhen), Singapore, Germany (Frankfurt), US (Silicon Valley), US (Virginia), and Japan (Tokyo)

      1,000,000

      Note
      • To monitor the number of devices in a product and prevent access failures, you can configure a threshold-based alert rule for the number of created devices. For more information, see Create a threshold-based alert rule.

      • If the number of devices exceeds the limit, you must create a new product.

    • Maximum number of devices that can be added to an instance:

      Region

      Instance type

      Limit

      China (Shanghai), Japan (Tokyo), Singapore, US (Virginia), Germany (Frankfurt), and US (Silicon Valley)

      Enterprise instance

      View available resources of the instance: Determined by the purchased specifications for Concurrent Connections.

      Legacy public instance

      10,000,000.

      Due to resource limits of public units, the specification limits for existing legacy public instances are subject to change and these instances no longer support capacity expansion. For more information, see Changes to specification limits for legacy public instances.

      China (Shanghai)

      New public instance

      500

      China (Beijing) and China (Shenzhen)

      Enterprise instance

      View available resources of the instance: Determined by the purchased specifications for Concurrent Connections.

      Note
    • Maximum number of devices that can be added under an Alibaba Cloud account:

      None. For this limit, refer to the maximum number of devices that can be added to an instance.

  • Gateway sub-devices

    • A gateway device can have a maximum of 2,000 sub-devices.

    • A gateway device can dynamically register a maximum of 30 sub-devices at a time.

    • A single batch request from a gateway device to bring sub-devices online or take them offline can include a maximum of 50 sub-devices.

    • The Queries Per Second (QPS) limit for a gateway device acting as an agent to bring sub-devices online is 200.

    For information about message throttling for gateway devices and their sub-devices, see Message throttling in Connections and communication.

Device management

Limits

Description

Limit

TSL model feature definitions

The maximum total number of TSL model modules (default and custom) that a product can contain.

200

The maximum total number of features that can be added to a TSL model module.

300

The maximum number of parameters that can be added to a property of the `struct` type.

50

When the data type of a feature is `enum`, the maximum number of enum values.

100

When the data type of a feature is `text`, the maximum data length.

10,240 characters

When the data type of a feature is `array`, the maximum number of elements in the array.

512

The maximum total number of input and output parameters that can be added to all services and events.

300

The maximum number of input parameters that can be added to a service.

100

The maximum number of output parameters that can be added to a service.

100

The maximum number of output parameters that can be added to an event.

100

The maximum total number of TSL model module files that can be imported at the same time.

20

The maximum number of recent versions that can be saved for a TSL model.

10

When you import a TSL model, the maximum size of a single JSON file of a TSL model module.

512 KB

When you import a TSL model, the maximum number of valid characters in a single JSON file of a TSL model module.

Valid characters are characters in the JSON content, excluding line break and alignment characters.

256 KB

When you import a TSL model, the maximum size of a ZIP file that contains multiple compressed JSON files.

2.5 MB

When you call a TSL model-related API, if the ARRAY and STRUCT data types are nested in the ThingModelJson request parameter, the maximum number of recursive nesting levels that is supported.

For example, an ARRAY can contain only a STRUCT. In this case, the STRUCT cannot contain another ARRAY or STRUCT data type.

2 levels (parent and child)

Number of tags

The maximum number of tags that can be added to a product, device, or group.

100

Device static groups

The maximum total number of parent groups and sub-groups under an Alibaba Cloud account.

1,000

The maximum number of devices that can be added to a group.

100,000

The maximum number of groups to which a device can be added.

10

Dynamic device groups

The maximum total number of dynamic groups under an Alibaba Cloud account.

10

Data parsing

The maximum size of a data parsing script file.

128 KB

Remote Configuration

Remote configuration files must be in JSON format. The maximum file size.

64 KB

File management

The maximum total size of files that can be stored in an instance.

1 GB

The maximum size of a single file that a device can upload over MQTT.

16 MB

The maximum number of files that can be stored for a device.

1,000

OTA update

The maximum number of update packages that can be contained in an instance under an Alibaba Cloud account.

500

The maximum size of an update package that is downloaded over HTTPS.

1,000 MB

The maximum size of an update package that is downloaded over MQTT.

An update package can contain only one file.

16 MB

The maximum number of devices that can be updated in a single batch update.

Important
  • For targeted updates that use device file uploads, a single batch update supports a maximum of 1,000,000 devices.

  • For regional updates in a specified region, a single batch update supports a maximum of 10,000 devices.

  • Enterprise instance: 300,000

  • Public instance: 100,000

Device jobs

The maximum number of device jobs that can be added in a single region under an Alibaba Cloud account.

10,000

Connection and communication

Limits

Description

Limit

Device access limit

A device certificate (ProductKey and DeviceName) can establish only one connection with the IoT Platform server at a time.

1

Connection attempts

The maximum number of MQTT connection requests per second for an Alibaba Cloud account.

500

The maximum number of connection requests per minute from a device to ensure that the requests are not throttled.

5

Number of device subscriptions

The maximum number of subscriptions for a device.

Requests that exceed the limit are rejected. The device can check the SUBACK message to confirm whether the request is successful.

100

Number of requests

Legacy public instance: The number of requests that are sent from devices to IoT Platform per second for an Alibaba Cloud account.

10,000

Legacy public instance: The number of requests that are sent from IoT Platform to devices per second for an Alibaba Cloud account.

2,000

New public instance: The number of mobile originated and mobile terminated message requests per second for an instance.

5

Enterprise instance: The number of mobile originated and mobile terminated message requests per second for an instance. This is determined by the purchased specifications for Message TPS.

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

View available resources of the instance

Message communication throttling

The maximum number of QoS 0 or QoS 1 messages that a device can report per second.

Note

MQTT does not provide acknowledgements for throttling of published messages. You can find throttling warnings for devices in Simple Log Service.

30 messages/second

A device can receive a maximum of 50 mobile terminated messages per second. This limit also depends on the network environment.

If the TCP write buffer is congested, an error is returned. If you send a command to a device by calling the Pub operation and the device fails to process the command in time, a throttling error is returned.

50 messages/second

Bandwidth

The maximum throughput (bandwidth) per second for a connection.

8 Mbps

Number of cached requests

IoT Platform limits the maximum number of unconfirmed inbound publish requests for each client.

After this limit is reached, the server does not accept new publish requests from the client until a PUBACK message is returned.

100

Message storage duration

The maximum storage duration for QoS 1 messages.

If no PUBACK message is received from the client after the maximum storage duration, the publish requests are discarded.

7 days

MQTT message length

The maximum length of a single MQTT publish message. Publish requests that exceed this limit are rejected.

256 KB

CoAP message length

The maximum length of a single CoAP publish message. Publish requests that exceed this limit are rejected.

1 KB

MQTT keepalive

The heartbeat interval for an MQTT connection is 30 to 1,200 seconds. If the heartbeat interval is not in this range, the server rejects the connection.

We recommend that you set the value to 300 seconds or more. The default value is 1,200 seconds. For information about how to configure the keepalive interval on a device, see MQTT connection example.

The heartbeat timer starts when IoT Platform sends a CONNACK message in response to a CONNECT message. The timer is reset when a PUBLISH, SUBSCRIBE, PING, or PUBACK message is received. IoT Platform checks the keepalive heartbeat of the device every 30 seconds. The waiting time for scheduled detection is the period of time from when the device goes online to the latest scheduled detection. The maximum timeout period is calculated using the following formula: (keepalive interval × 1.5) + (waiting time for scheduled detection). If no message is received from the device after the maximum timeout period, the server automatically disconnects the device.

30 to 1,200 seconds

RRPC timeout period

The timeout period for a device to respond to an RRPC request.

8 seconds

TSL model property reporting

The maximum number of TSL model properties that a device can report at a time.

500

Reporting of historical TSL model properties and events

The maximum number of devices that can report historical TSL model data at the same time in an instance.

50

The maximum number of TSL model properties that a device can report at a time.

30

The maximum number of TSL model events that a device can report at a time.

20

Batch reporting of TSL model properties and events

The maximum number of property and event data records that a device can report at a time.

Multiple values of a property or an event are counted as multiple data records.

1,000

MQTT 5.0 protocol

The maximum total number of user-defined properties that can be added.

20

The maximum total length of the key and value of a user-defined property.

128 characters

In request-response mode, the maximum length of the response topic and correlation data is the same.

128 characters

About Topics

Limits

Description

Limit

Number of custom topic categories

The maximum number of topic categories that can be defined for a product.

200

Permissions

A device can only publish and subscribe to its own topics.

None

Topic length

A topic can be up to 160 bytes in length and must be encoded in UTF-8.

160

Topic Category

The maximum number of levels that a topic can contain. This is the maximum number of forward slashes (/) in the topic.

7

Number of subscriptions

The maximum number of subscriptions per subscription request.

8

Effective period of operations

Subscriptions and unsubscriptions take effect 10 seconds after the operation. A subscription remains effective until it is canceled. We recommend that you subscribe to topics in advance to avoid message loss.

Example: A device sends a SUB request to Topic A. After 10 seconds, the subscription takes effect and the device starts to receive real-time messages. The device continues to receive messages from Topic A unless it unsubscribes.

10 seconds

Broadcast topic

The body of a message to be broadcast cannot exceed 64 KB.

The original message must be converted to binary data and then Base64-encoded to generate the message body.

64 KB

The server-side SDK can send only one full broadcast message per minute.

1 message/minute

Device shadow

Limits

Description

Limit

JSON levels

The maximum nesting depth of a device shadow JSON document.

5

File size

The maximum size of a device shadow JSON document.

16 KB

Number of properties

The maximum number of properties in a device shadow JSON document.

128

Requests per second

The maximum number of requests per second for each device.

20

Data forwarding (legacy)

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

Data forwarding (new)

The message-related limits for data forwarding (new) are the same as those for data forwarding (legacy).

Limitations

Description

Limit

Resolver

The maximum total number of resolvers that an instance can contain.

1,000

Data source

The maximum total number of data sources that can be associated with a resolver.

1

The maximum total number of topics that a data source can contain.

1,000

Data destination

The maximum total number of data destinations that can be associated with a resolver.

10

The maximum total number of operations that a data destination can contain.

1

The maximum total number of error data destinations that can be associated with a resolver.

1

Parsing script

The maximum size of the script content for a resolver.

120 KB

The maximum number of times that a data forwarding function can be executed in a loop within a resolver script.

For more information about data forwarding functions, see Functions for forwarding data to a data destination.

100

Server-side subscription

Limits on AMQP-based server-side subscriptions:

Limitations

Description

Authentication timeout

After a connection is established, you must immediately send an authentication request. If authentication is not successful within 15 seconds, the server closes the connection.

Data timeout

When a server establishes a connection with IoT Platform, you must specify a heartbeat interval (the idle-timeout parameter of the AMQP protocol). The value must be in the range of 30 to 300 seconds. If no frame communication occurs for the duration of the heartbeat interval, IoT Platform closes the connection.

After a connection is established, your server must send PING packets within the heartbeat interval to maintain the connection. If no PING packet is sent within the heartbeat interval, IoT Platform closes the connection.

Note

If you use an SDK provided by Alibaba Cloud, you do not need to send PING packets to maintain the connection after it is established. The SDK has a keepalive mechanism. You only need to ensure that the main process does not exit.

ACK timeout

After an AMQP server forwards a message to a client, an ACK timeout occurs if no acknowledgement is received from the client within 30 seconds.

Retry policy for failed pushes

Messages cannot be consumed in real time and are added to the accumulation queue because the consumer client is offline or consumes messages slowly.

  • After the consumer client goes online again and its consumption rate becomes stable, IoT Platform retries pushing the accumulated messages.

  • If the client fails to consume the retried messages, the accumulation queue may be blocked. IoT Platform retries pushing the messages to the client at an interval of about one minute.

Message storage limit

A consumer group can accumulate a maximum of 100 million messages.

Message storage duration

1 day.

Throttling for real-time message pushes

A connection is limited to 1,000 TPS. You can increase the number of connections to scale out. The maximum number of connections is 128.

Throttling for accumulated message pushes

A consumer group is limited to 200 TPS.

Note

To prevent message accumulation, ensure that the consumer client is online and promptly acknowledges messages pushed by the platform.

Number of consumer groups that can be associated with a product

A maximum of 10.

Number of products that can be associated with a consumer group

A maximum of 1,000.

Number of topics that a consumer group can subscribe to

A maximum of 200.

Note

Subscribing to a topic that uses a wildcard character is counted as one topic. For example, if you subscribe to a topic for a product, such as /asde****/+/user/get, it is counted as one topic regardless of the number of devices in the product.

Limit on the number of consumer groups

An Alibaba Cloud account can create a maximum of 1,000 consumer groups.

Limit on the number of clients

A consumer group supports a maximum of 128 clients.

Limit on the number of connections

For a consumer group, a client can request no more than 100 connections per minute.

Note

A client is an AMQP client that receives messages from IoT Platform, not a device.

For information about the limits on MNS-based server-side subscriptions, see the queue-related limits in MNS limits.

DataService Studio

  • All features of DataService Studio are supported only by Standard and Premium instances in the China (Shanghai), China (Beijing), China (Shenzhen), Singapore, and US (Virginia) regions.

  • Only the time series storage feature of DataService Studio is supported in the Japan (Tokyo), Germany (Frankfurt), and US (Silicon Valley) regions.

DataService Studio features are limited by the resource specifications of your purchased instance.

For information about how to purchase an Enterprise instance and enable DataService Studio, see Purchase an Enterprise instance. For information about the billing rules for each feature of DataService Studio, see DataService Studio.

Secure Tunnel

Limitations

Description

Limit

Secure tunnel

The maximum total number of secure tunnels that an instance can contain.

1,000

The maximum total number of secure tunnels that a device can contain.

10

The maximum duration for which a secure tunnel can remain open after it is created.

Note

After this period, the secure tunnel is forcibly closed. A closed secure tunnel cannot be reopened.

24 hours

The maximum duration for which a secure tunnel can be retained after it is created.

Note

After this period, the secure tunnel is automatically deleted by the system.

30 days

Secure tunnel session

The maximum total number of sessions that a secure tunnel can contain.

10

Data transfer rate

The maximum data transfer rate supported by a secure tunnel.

Note

Secure tunnels use a traffic shaping mechanism to throttle data transfer. When the data transfer rate reaches the upper limit, tunnel frames are delayed. Control the rate at which you send data.

For more information about tunnel frames, see Communication data format.

100 Kbps

IoT Twin Engine

For more information, see Limits of IoT Twin Engine.

Cloud API limits

For information about the QPS limits for calling cloud APIs, see the documentation for the specific API.

If a throttling error is returned when you call an API, such as errors of Type 28 to Type 30 in Common errors, you can call the API again.

References

FAQ about communication messages