This topic describes the billing items and pricing of Message Queue for MQTT subscription instances.

Subscription

The following table lists the billing items of Message Queue for MQTT subscription instances.

Item Definition Description Example
Maximum number of concurrent connections The number of client connections over TCP on a single instance at any time. The number of concurrent connections is a transient value and is updated every minute. The maximum number of connections must be at least the actual number of connections for the service. Otherwise, throttling will be triggered in Message Queue for MQTT during peak hours, and some clients may fail to be connected. Assume that the number of concurrent connections of instance_a was 1,000 at 10:00 and was 2,000 at 10:01. To make sure that the service properly runs, you must set the maximum number of concurrent connections for instance_a to a value greater than 2,000. For example, you can set the value to 5,000.
Maximum transactions per second (TPS) for messaging The maximum number of messages that are sent and received per second by using protocols supported by Message Queue for MQTT.
  • To avoid service exceptions, make sure that the maximum messaging TPS is at least the actual messaging TPS.
  • These messages include only the messages that are sent and received by using Message Queue for MQTT, but do not include the messages that are sent and received by using Message Queue for Apache RocketMQ.
  • The TPS for sending messages and TPS for receiving messages are counted in the messaging TPS.
  • If the system fails to push messages with QoS set to 1 and cleanSession set to false, the system stores these messages as offline messages for retrying. Storing offline messages is also considered as one push call.
  • The system charges you by multiplying the total number of received and sent messages (including calls of the client API and the cloud API) by the ratio that corresponds to the transmission quality level in the specified protocol. For more information, see Calculation ratios.
Assume that instance_a has 100 clients, and cleanSession is set to true for each client. Each client sends one QoS0 message, two QoS1 messages, and three QoS2 messages per second, and receives one QoS0 message, one QoS1 message, and one QoS2 message per second. The messaging TPS of instance_a is calculated in the following formula: 100 × (1 + 2 × 2 + 3 × 5) + 100 × (1 + 1 × 2 + 1 × 5) = 2,800/s. To make sure that the service properly runs, you must set the maximum messaging TPS for instance_a to a value greater than 2,800/s. For example, you can set the value to 3,000/s.
Maximum number of subscriptions The maximum number of subscriptions that a user has registered with the Message Queue for MQTT broker.
  • To avoid service exceptions, make sure that the maximum number of subscriptions must be at least the actual number of subscriptions.
  • Each subscription to a Message Queue for MQTT topic by a client ID is counted as one subscription.
  • The number of subscriptions is counted every minute. The Message Queue for MQTT broker collects the maximum value obtained in each statistical cycle.
  • Based on the Message Queuing Telemetry Transport (MQTT) protocol, if cleanSession is set to true on a client and the client goes offline, the broker cancels all the topics that the client has subscribed to. If cleanSession is set to false on a client and the client goes offline, the broker retains all the topics that the client has subscribed to.
Assume that client_1 and client_2 are connected to instance_a, client_1 subscribes to TopicA/sub_1, TopicA/sub_2, and TopicB/sub_1, and client_2 subscribes to TopicA/sub_1 and TopicB/sub_2. Then, the number of subscriptions for instance_a is five. To make sure that the service properly runs, the maximum number of subscriptions for instance_a must be greater than five. For example, you can set the value to 1,000.

Pricing

The following table lists the billing rules for the maximum number of concurrent connections of Message Queue for MQTT subscription instances.

Instance type Maximum number of connections Price (USD/month)
Basic Edition 100 3
1,000 29
5,000 142
10,000 284
20,000 567
50,000 1417
100,000 2833
Enterprise Platinum Edition 100,000 3852
300,000 11329
500,000 18805
1,000,000 37836
2,000,000 75446

The following table lists the billing rules for the maximum messaging TPS of Message Queue for MQTT subscription instances.

Instance type Maximum messaging TPS Price (USD/month)
Basic Edition 100 29
1,000 284
5,000 1417
10,000 2833
20,000 5665
Enterprise Platinum Edition 20,000 5211
50,000 7930
100,000 12009
200,000 18125
500,000 42368

The following table lists the billing rules for the maximum number of subscriptions of Message Queue for MQTT subscription instances.

Instance type Maximum number of subscriptions Price (USD/month)
Basic Edition 1,000 12
10,000 114
50,000 567
100,000 1133
200,000 2266
500,000 5665
1,000,000 11329
Enterprise Platinum Edition 100,000 1586
500,000 7477
1,000,000 15180
2,000,000 30133
5,000,000 75446
Note You can change the billing method of a Message Queue for MQTT instance from subscription to pay-as-you-go. For more information, see Change the billing method of an instance from subscription to pay-as-you-go.