Queue model noun explanation

Queues are the destination of message storage and can be divided into ordinary queues and delayed queues. Messages contain data and attributes and can be classified into ordinary messages and delayed messages. MessageId and ReceiptHandle uniquely identify a message in a queue.

Account

Namely, the user’s Aliyun account ID.

Queue owner

The Account that initiates the MNS service creates a message queue through the CreateQueue interface. The Account is the owner of the message queue, and the owner has all operation rights on the queue. The Account ID corresponding to the queue owner can be viewed on the official website of Aliyun.

Producer, consumer

Producer, the role that sends messages to message queues in MNS. Consumer, the role that gets messages from the MESSAGE queue in MNS.

The average queue

If the message delay parameter is not specified, the message can be consumed immediately after being sent to the common queue.

Delay queue

If the message delay parameter is not specified, the message sent to the delay queue can be retrieved after a certain period of time. You can specify the queue delay using CreateQueue and SetQueueAttribute.

Endpoint

The MNS access domain name is in the following format: http://$AccountId.mns.$Region.aliyuncs.com/

mns.. Aliyuncs.com: Region is a Region where the MNS service is deployed. Users can select different regions based on application requirements.

AccountId: indicates the AccountId of the queue owner. Replace it with the actual AccountId when invoking API requests.

Ordinary messages and delayed messages

A normal message is a message that is sent to a queue and can be retrieved immediately.

A delayed message is a message that takes a certain amount of time to be retrieved after being sent to the queue. The delay duration is determined by the DelaySeconds attribute (refer to the related attribute of SendMessage).

MessageID (MessageID)

MessageId identifies a message in a queue. Each message has a unique MessageId in a queue, but not in different queues. When a message is sent to the MNS queue, MNS generates a MessageId. This ID is not changed once generated and is returned in the request response. Users can mainly use this MessageId for data verification, but must use ReceiptHandle to delete messages.

Temporary Handle (ReceiptHandle)

ReceiptHandle is a temporary message identifier generated by the MNS based on the behavior of retrieving the message at the time, unlike MessageId. When deleting a consumed message or changing its VisiblityTimeout property value, you need to specify the consumed message with ReceiptHandle. ReceiptHandle can be used only once. If the message status marked by ReceiptHandle changes, it will be invalid. Consumers can perform the operations only by obtaining the Message and then obtaining ReceiptHandle again.

Message Status

When a normal message is sent to a normal message queue, its initial state is Active. After it is removed, its state is Inactive within VisibilityTimeout. If the message is not deleted after VisibilityTimeout, The message becomes Active again; If it is Deleted within VisibilityTimeout, the message status is Deleted.

When a common message is sent to the delay queue, the initial status of the message is Delayed, and after the time set by the DelaySeconds attribute of the delay queue, the status of the message becomes Active.

Delayed messages are sent to the queue (normal queue or Delayed queue) with the initial status of Delayed messages and the status of Delayed messages becomes Active after the time specified by the DelaySeconds attribute of the message.

The maximum lifetime of a message is determined by the value of the MessageRetentionPeriod attribute specified when the queue is created. After this period, the message status becomes Expired and is reclaimed by the garbage collector.

Consumers can only fetch messages that are in the Active state.

Subject subscription noun explanation

Topics in the publish/subscribe model are the target and storage address for published messages.

Account

Namely, the user’s Aliyun account ID.

Publisher

A message publisher, a user who sends a message to a topic, can also be considered a message producer.

Subscriber (Subsciber)

Message subscriber, a user who receives messages from a topic. By default, the topic owner has subscription rights to his or her topic.

Subscription

Subscription, a message subscriber can only receive messages published to a topic by a publisher if it has a subscription to that topic.

Push Address (Endpoint)

Message receiver address of a subscriber for receiving subject messages, for example, HTTP address, email address, and SMS mobile phone number.

TopicURL

Logo http://$AccountId.mns.$Region.aliyuncs.com/topics/$TopicName$AccountId is the user’s account ID $Region is to provide service of regional MNS, such as: Beijing, Hangzhou, Qingdao etc. $TopicName is the name of the subject

Message

MessageId identifies a message within a topic. Each message has a unique MessageId within a topic, but not across topics. After a message is published to a Topic, the maximum lifetime is 1 day. After the message expires, it becomes Expired and will be collected by the garbage collector.

Explanation of terms related to SMS

Message template

An SMS template is the content of a specific SMS message.

Note: The SMS template supports three modes: verification code, SMS notification, and promotion SMS. Verification code and SMS notification, through variable replacement to achieve personalized SMS customization. Promotion SMS does not support adding variables to templates. The SMS template can be used only after being approved. Example: SMS example: [Ali cloud] verification code ${number}, you are carrying out alipay authentication, killing do not tell others! SMS signature: Ali cloud SMS template: verification code ${number}, you are carrying out alipay authentication, kill don’t tell others!

Message signatures

Create signature information based on user identity.

Enterprise users need to upload the relevant enterprise qualification certificate, and individual users need to upload the proof of personal identity. The SMS signature can be used only after being approved. Example: SMS example: [Ali cloud] verification code ${number}, you are carrying out alipay authentication, killing do not tell others! SMS signature: Ali cloud SMS template: verification code ${number}, you are carrying out alipay authentication, kill don’t tell others!

state

After the SMS signature and SMS template are submitted for review, the specific status is displayed.

The status of SMS signature includes: In review, failed review, and passed review.

Under review: The SMS signature has been submitted and is waiting for review. It will be reviewed in 1-2 working days.

Audit failed: For some reason, the signature audit failed. You can view the reason for a specific audit failure through the Signature Management console.

Approved: If the SMS signature and SMS template are approved, the SMS can be sent through the interface.

The STATUS of an SMS template can be in the review, failed, or passed.

Under review: An SMS template has been submitted and is waiting for approval. It will be reviewed in 1-2 working days.

Audit failed: For some reason, the template audit failed. You can view the reason for a specific audit failure through the Template Management console.

Approved: If the SMS signature and SMS template are approved, the SMS can be sent through the interface.

More on Aliyun messaging service:

Ali cloud message service use tutorial

Ali Cloud Message Service (MQS) is the commercial Message middleware Service of Ali Cloud. Different from the traditional message middleware, the message service is designed and implemented based on the Feitian distributed system independently developed by Ali Cloud at the very beginning, which has the characteristics of large-scale, high reliability, high concurrent access and super message accumulation capacity. The API of message service adopts HTTP RESTful standard, which is easy to access and has strong cross-network capability. Access to resource Access control services (RAM) and private networks (VPC) to support secure access control. Access to cloud monitoring to provide a sound monitoring and alarm mechanism. Messaging services provide rich SDKS, solutions, best practices, and 7×24 technical support to help application developers freely transfer data between application components and build loosely-coupled, distributed, and highly available systems. The message service can also send SMS messages, including verification codes, SMS notifications, and promotion SMS messages. 200 million users sent 600 million text messages during singles’ Day. Exclusive channel with three networks in one, real-time connection with the platform of the Ministry of Industry and Information Technology. Carrier-grade operation and maintenance guarantee, real-time monitoring automatic switching, arrival rate up to 99%.)

Official website of Ali Yun University (Official website of Ali Yun University, Innovative Talent Workshop under cloud Ecology)