This topic describes the limits of Message Service (MNS). To prevent exceptions, you cannot exceed the limits when using MNS.

The following table lists the limits of MNS queues.

Item Limit Description
Number of queues The maximum number of queues and topics that a user can create is 1,000. N/A
Message size 64 KB If the size of a message exceeds this limit, the message is discarded.
Batch operations on messages The maximum messages that you can manage at a time is 16. batchsize is 16. N/A
Long polling The maximum time period for which a request waits is 30 seconds. N/A
Message retention period 7 days We recommend that you specify the message retention period based on your needs. After the specified period, messages are automatically deleted.
Queries per second (QPS) for a single queue 3000 (recommended) N/A

The following table lists the limits of MNS topics.

Item Limit Description
Number of topics The maximum number of queues and topics that a user can create is 1000. N/A
Number of subscriptions to a single topic 100 N/A
Message retention period 1 day We recommend that you specify the message retention period based on your needs. After the specified period, messages are automatically deleted.
QPS for a single topic 500 (recommended) N/A